![]() |
(git:3d5d2e5)
|
Direct reciprocal-space reference for scalar UPF augmentation. Uses the complete tabulated radial mesh and CP2K real spherical harmonics. The overlap correction is the zero-frequency limit of this same transform. More...
Data Types | |
| type | uspp_augmentation_type |
Functions/Subroutines | |
| subroutine, public | uspp_augmentation_init (pot, projectors, augmentation) |
| Prepare radial quadrature and Gaunt coefficients in the native beta convention. | |
| subroutine, public | uspp_augmentation_prepare_realspace (pot, augmentation) |
| Prepare regular radial splines for atom-grid augmentation quadrature. UPF stores r**2 Q_ij^L(r). Interpolate Q_ij^L(r)/r**L in r**2 and multiply by solid harmonics, so values and Cartesian derivatives remain regular at the origin. The existing reciprocal-space quadrature and its overlap correction are unchanged. | |
| subroutine, public | uspp_augmentation_realspace (augmentation, displacement, qr, gradient, hessian) |
| Evaluate the augmentation matrix and derivatives at a Cartesian displacement. Uses cubic splines with a C2 quintic closure into an exact tabulated zero suffix. Values, gradients and Hessians share the same polynomial. No angular division by radius is needed, including at the center and on coordinate axes. | |
| subroutine, public | uspp_augmentation_collocate_atom (augmentation, displacements, density, rho, gradient) |
| Add one center's augmentation density and gradient to arbitrary atom-grid points. | |
| subroutine, public | uspp_augmentation_integrate_atom (augmentation, displacements, weights, v_rho, v_gradient, matrix, density, center_gradient, point_gradient) |
| Adjoint of the atom-grid density map, including the GGA gradient term. | |
| subroutine, public | uspp_augmentation_prepare_fourier (augmentation, gvecs, max_bytes) |
| Cache exact radial transforms for repeated reciprocal-vector lengths. The retained arrays are bounded; uncached lengths use direct quadrature. Initialization of a new augmentation object also releases this cache. | |
| subroutine, public | uspp_augmentation_fourier (augmentation, g, position, volume, qg, strain, grid_index) |
| Evaluate Q_ij(G) = integral Q_ij(r-R) exp(-i G.r) dr / volume. Direct radial quadrature is a reference without reciprocal interpolation. | |
| subroutine, public | uspp_augmentation_collocate (augmentation, gvecs, position, volume, density_matrix, rho) |
| Add the augmentation density on a list of reciprocal vectors. | |
| subroutine, public | uspp_augmentation_integrate (augmentation, gvecs, position, volume, vg, multiplicity, matrix, derivative, strain) |
| Adjoint of augmentation collocation: integrate a real local potential against Q. | |
Direct reciprocal-space reference for scalar UPF augmentation. Uses the complete tabulated radial mesh and CP2K real spherical harmonics. The overlap correction is the zero-frequency limit of this same transform.
| subroutine, public uspp_augmentation::uspp_augmentation_init | ( | type(atom_upfpot_type), intent(in) | pot, |
| type(upf_projector_type), intent(in) | projectors, | ||
| type(uspp_augmentation_type), intent(out) | augmentation ) |
Prepare radial quadrature and Gaunt coefficients in the native beta convention.
| pot | Original scalar USPP with angular-resolved augmentation. |
| projectors | Prepared native projectors, with Cartesian degree at least max(lbeta). |
| augmentation | Immutable augmentation data, in the same magnetic-projector ordering. |
Definition at line 62 of file uspp_augmentation.F.
| subroutine, public uspp_augmentation::uspp_augmentation_prepare_realspace | ( | type(atom_upfpot_type), intent(in) | pot, |
| type(uspp_augmentation_type), intent(inout) | augmentation ) |
Prepare regular radial splines for atom-grid augmentation quadrature. UPF stores r**2 Q_ij^L(r). Interpolate Q_ij^L(r)/r**L in r**2 and multiply by solid harmonics, so values and Cartesian derivatives remain regular at the origin. The existing reciprocal-space quadrature and its overlap correction are unchanged.
| pot | Original scalar USPP used to initialize augmentation. |
| augmentation | Prepared angular data; owns the optional real-space cache on return. |
Definition at line 138 of file uspp_augmentation.F.
| subroutine, public uspp_augmentation::uspp_augmentation_realspace | ( | type(uspp_augmentation_type), intent(in) | augmentation, |
| real(kind=dp), dimension(3), intent(in) | displacement, | ||
| real(kind=dp), dimension(:, :), intent(out) | qr, | ||
| real(kind=dp), dimension(:, :, :), intent(out), optional | gradient, | ||
| real(kind=dp), dimension(:, :, :, :), intent(out), optional | hessian ) |
Evaluate the augmentation matrix and derivatives at a Cartesian displacement. Uses cubic splines with a C2 quintic closure into an exact tabulated zero suffix. Values, gradients and Hessians share the same polynomial. No angular division by radius is needed, including at the center and on coordinate axes.
| augmentation | Data with an initialized real-space cache. |
| displacement | Evaluation point minus augmentation center, in bohr. |
| qr | Symmetric Q_ij(r), without radial Jacobian or quadrature weights. |
| gradient | Optional Cartesian gradient of qr with respect to the evaluation point. |
| hessian | Optional Cartesian Hessian of qr, also needed for GGA geometry derivatives. |
Definition at line 198 of file uspp_augmentation.F.
| subroutine, public uspp_augmentation::uspp_augmentation_collocate_atom | ( | type(uspp_augmentation_type), intent(in) | augmentation, |
| real(kind=dp), dimension(:, :), intent(in) | displacements, | ||
| real(kind=dp), dimension(:, :), intent(in) | density, | ||
| real(kind=dp), dimension(:), intent(inout) | rho, | ||
| real(kind=dp), dimension(:, :), intent(inout) | gradient ) |
Add one center's augmentation density and gradient to arbitrary atom-grid points.
| augmentation | Data with an initialized real-space cache. |
| displacements | Cartesian quadrature points relative to this center, in bohr. |
| density | Real symmetric on-site density matrix, including off-diagonal entries. |
| rho | Accumulated density values; no quadrature weights included. |
| gradient | Accumulated Cartesian density gradients. |
Definition at line 368 of file uspp_augmentation.F.
| subroutine, public uspp_augmentation::uspp_augmentation_integrate_atom | ( | type(uspp_augmentation_type), intent(in) | augmentation, |
| real(kind=dp), dimension(:, :), intent(in) | displacements, | ||
| real(kind=dp), dimension(:), intent(in) | weights, | ||
| real(kind=dp), dimension(:), intent(in) | v_rho, | ||
| real(kind=dp), dimension(:, :), intent(in) | v_gradient, | ||
| real(kind=dp), dimension(:, :), intent(out) | matrix, | ||
| real(kind=dp), dimension(:, :), intent(in), optional | density, | ||
| real(kind=dp), dimension(3), intent(out), optional | center_gradient, | ||
| real(kind=dp), dimension(:, :), intent(out), optional | point_gradient ) |
Adjoint of the atom-grid density map, including the GGA gradient term.
| augmentation | Data with an initialized real-space cache. |
| displacements | Cartesian quadrature points relative to this center, in bohr. |
| weights | Quadrature weights, optionally signed for a hard/soft energy difference. |
| v_rho | Derivative of the energy density with respect to density, without weights. |
| v_gradient | Derivative with respect to the Cartesian density gradient, without weights. |
| matrix | Resulting symmetric on-site operator. |
| density | Optional on-site density, required for center_gradient. |
| center_gradient | Optional energy gradient from translating this center at fixed grid points. Projector, moving-grid and partition-weight derivatives are separate contributions. |
| point_gradient | Optional energy gradient of each quadrature point at fixed center and weights. |
Definition at line 414 of file uspp_augmentation.F.
| subroutine, public uspp_augmentation::uspp_augmentation_prepare_fourier | ( | type(uspp_augmentation_type), intent(inout) | augmentation, |
| real(dp), dimension(:, :), intent(in) | gvecs, | ||
| integer(int_8), intent(in), optional | max_bytes ) |
Cache exact radial transforms for repeated reciprocal-vector lengths. The retained arrays are bounded; uncached lengths use direct quadrature. Initialization of a new augmentation object also releases this cache.
| augmentation | Prepared radial data, with the cache updated in place. |
| gvecs | Local Cartesian reciprocal vectors, in their current ordering. |
| max_bytes | Optional retained-memory limit per kind and rank (default 64 MiB). |
Definition at line 486 of file uspp_augmentation.F.
| subroutine, public uspp_augmentation::uspp_augmentation_fourier | ( | type(uspp_augmentation_type), intent(in) | augmentation, |
| real(kind=dp), dimension(3), intent(in) | g, | ||
| real(kind=dp), dimension(3), intent(in) | position, | ||
| real(kind=dp), intent(in) | volume, | ||
| complex(kind=dp), dimension(:, :), intent(out) | qg, | ||
| complex(kind=dp), dimension(:, :, :, :), intent(out), optional | strain, | ||
| integer, intent(in), optional | grid_index ) |
Evaluate Q_ij(G) = integral Q_ij(r-R) exp(-i G.r) dr / volume. Direct radial quadrature is a reference without reciprocal interpolation.
| augmentation | Prepared data. |
| g | Cartesian reciprocal vector in inverse bohr. |
| position | Augmentation center in bohr. |
| volume | Cell volume in bohr cubed. |
| qg | Complex symmetric form-factor matrix. Q(-G) = conjugate(Q(G)). |
| strain | Optional dQ/d epsilon_ab at fixed fractional center and reciprocal index. Includes the inverse-volume derivative; the center phase is strain invariant. |
| grid_index | Optional index in the prepared Fourier cache; absent entries use direct quadrature. |
Definition at line 595 of file uspp_augmentation.F.
| subroutine, public uspp_augmentation::uspp_augmentation_collocate | ( | type(uspp_augmentation_type), intent(in) | augmentation, |
| real(kind=dp), dimension(:, :), intent(in) | gvecs, | ||
| real(kind=dp), dimension(3), intent(in) | position, | ||
| real(kind=dp), intent(in) | volume, | ||
| real(kind=dp), dimension(:, :), intent(in) | density_matrix, | ||
| complex(kind=dp), dimension(:), intent(inout) | rho ) |
Add the augmentation density on a list of reciprocal vectors.
| augmentation | Prepared data. |
| gvecs | Cartesian reciprocal vectors (3,ng). |
| position | Center in bohr. |
| volume | Cell volume. |
| density_matrix | Real symmetric projector density matrix, with occupations included. |
| rho | Fourier density coefficients (integral divided by volume), accumulated in place. |
Definition at line 716 of file uspp_augmentation.F.
| subroutine, public uspp_augmentation::uspp_augmentation_integrate | ( | type(uspp_augmentation_type), intent(in) | augmentation, |
| real(kind=dp), dimension(:, :), intent(in) | gvecs, | ||
| real(kind=dp), dimension(3), intent(in) | position, | ||
| real(kind=dp), intent(in) | volume, | ||
| complex(kind=dp), dimension(:), intent(in) | vg, | ||
| real(kind=dp), dimension(:), intent(in) | multiplicity, | ||
| real(kind=dp), dimension(:, :), intent(out) | matrix, | ||
| real(kind=dp), dimension(:, :, :), intent(out), optional | derivative, | ||
| real(kind=dp), dimension(:, :, :, :), intent(out), optional | strain ) |
Adjoint of augmentation collocation: integrate a real local potential against Q.
| augmentation | Prepared data. |
| gvecs | Cartesian reciprocal vectors (3,ng). |
| position | Center in bohr. |
| volume | Cell volume. |
| vg | Fourier potential coefficients (integral divided by volume). |
| multiplicity | One for a complete reciprocal list; two for a retained +/-G pair. |
| matrix | Real symmetric screened projector contribution, overwritten. |
| derivative | Optional derivatives of matrix with respect to the augmentation center. |
| strain | Optional density strain contribution at fixed Fourier potential and volume weight. |
Definition at line 746 of file uspp_augmentation.F.