(git:7fc1fe1)
Loading...
Searching...
No Matches
nlo_derivatives Module Reference

Matrix algebra for analytic k derivatives through fifth order. More...

Functions/Subroutines

integer function, public nlo_derivative_count (grade)
 Number of Cartesian Taylor coefficients through the given total grade.
subroutine, public nlo_derivative_indices (alpha)
 Enumerate the 56 three-dimensional multi-indices through total order five.
subroutine, public nlo_derivative_product (alpha, left, right, product, active_grade)
 Apply the product rule to two arrays of normalized matrix k derivatives.
subroutine, public nlo_lowdin_derivatives (overlap, inverse_root, active_grade)
 Solve X(k) S(k) X(k)=I analytically through fifth Cartesian order.
subroutine, public nlo_orthonormal_operator_derivatives (overlap, hamiltonian, moment, orth_h, connection, active_grade)
 Express H and the AO position matrix in an orthonormal AO basis.
subroutine, public nlo_equilibrium_density_derivatives (energies, occupied, hamiltonian, rho0, active_grade)
 Derivatives of the equilibrium density matrix for filled Kohn-Sham bands.
integer function, public derivatives_index (alpha, sought)
 Find the Taylor coefficient for the requested (x,y,z) derivative counts.

Variables

integer, parameter, public nlo_max_derivatives_order = 5
integer, parameter, public nlo_n_derivatives = 56

Detailed Description

Matrix algebra for analytic k derivatives through fifth order.

Note
Each array stores normalized derivatives X_α=(∂_k^α X)/α!, with α=(α_x,α_y,α_z), α!=α_x!α_y!α_z! and |α|<=5. Examples: X_(1,1,0)=∂_kx ∂_ky X and X_(2,0,0)=(∂_kx² X)/2. Products are formed by the multivariable product rule; no finite differences are used. The overlap inverse square root X=S^(-1/2) satisfies X S X=I. Its derivative of each order is obtained from lower orders by a Sylvester solve.

Function/Subroutine Documentation

◆ nlo_derivative_count()

integer function, public nlo_derivatives::nlo_derivative_count ( integer, intent(in) grade)

Number of Cartesian Taylor coefficients through the given total grade.

Parameters
gradeHighest total derivative grade, from zero through five.
Returns
Number of Cartesian coefficients through the requested grade.

Definition at line 43 of file nlo_derivatives.F.

Here is the caller graph for this function:

◆ nlo_derivative_indices()

subroutine, public nlo_derivatives::nlo_derivative_indices ( integer, dimension(3, nlo_n_derivatives), intent(out) alpha)

Enumerate the 56 three-dimensional multi-indices through total order five.

Parameters
alphaCartesian derivative counts (α_x, α_y, α_z) for each Taylor coefficient.

Definition at line 58 of file nlo_derivatives.F.

Here is the caller graph for this function:

◆ nlo_derivative_product()

subroutine, public nlo_derivatives::nlo_derivative_product ( integer, dimension(3, nlo_n_derivatives), intent(in) alpha,
complex(dp), dimension(:, :, :), intent(in) left,
complex(dp), dimension(:, :, :), intent(in) right,
complex(dp), dimension(:, :, :), intent(out) product,
integer, intent(in), optional active_grade )

Apply the product rule to two arrays of normalized matrix k derivatives.

Parameters
alphaCartesian derivative counts (α_x, α_y, α_z) for each Taylor coefficient.
leftNormalized Taylor coefficients of the left matrix factor.
rightNormalized Taylor coefficients of the right matrix factor.
productNormalized Taylor coefficients of the matrix product.
active_gradeHighest total derivative grade to compute; omit for all five grades.

Definition at line 83 of file nlo_derivatives.F.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ nlo_lowdin_derivatives()

subroutine, public nlo_derivatives::nlo_lowdin_derivatives ( complex(dp), dimension(:, :, :), intent(in) overlap,
complex(dp), dimension(:, :, :), intent(out) inverse_root,
integer, intent(in), optional active_grade )

Solve X(k) S(k) X(k)=I analytically through fifth Cartesian order.

Parameters
overlapNormalized Taylor coefficients of S; leading coefficient Hermitian positive
inverse_rootNormalized Taylor coefficients of S**(-1/2)
active_gradeHighest total derivative grade to compute; omit for all five grades.

Definition at line 119 of file nlo_derivatives.F.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ nlo_orthonormal_operator_derivatives()

subroutine, public nlo_derivatives::nlo_orthonormal_operator_derivatives ( complex(dp), dimension(:, :, :), intent(in) overlap,
complex(dp), dimension(:, :, :), intent(in) hamiltonian,
complex(dp), dimension(:, :, :, :), intent(in) moment,
complex(dp), dimension(:, :, :), intent(out) orth_h,
complex(dp), dimension(:, :, :, :), intent(out) connection,
integer, intent(in), optional active_grade )

Express H and the AO position matrix in an orthonormal AO basis.

Parameters
overlapNormalized Taylor coefficients of the AO overlap S(k).
hamiltonianNormalized Taylor coefficients of the AO Hamiltonian H(k).
momentNormalized Taylor coefficients of the AO position matrices d_a(k).
orth_hNormalized Taylor coefficients of the orthogonal Hamiltonian.
connectionNormalized Taylor coefficients of the orthogonal position connection.
active_gradeHighest total derivative grade to compute; omit for all five grades.
Note
AO basis functions overlap, so S(k) is not the identity. The matrix X(k)=S(k)^(-1/2) makes their overlap equal to the identity. This routine differentiates H^orth=X H X and the position matrix A_a^orth=X d_a X-i (dX/dk_a) S X, where d_a is the AO position matrix. It does not select occupied bands or build the equilibrium density rho0. A_a^orth is needed through order four; its order-five slots remain zero.

Definition at line 215 of file nlo_derivatives.F.

Here is the call graph for this function:

◆ nlo_equilibrium_density_derivatives()

subroutine, public nlo_derivatives::nlo_equilibrium_density_derivatives ( real(kind=dp), dimension(:), intent(in) energies,
integer, dimension(:), intent(in) occupied,
complex(dp), dimension(:, :, :), intent(in) hamiltonian,
complex(dp), dimension(:, :, :), intent(out) rho0,
integer, intent(in), optional active_grade )

Derivatives of the equilibrium density matrix for filled Kohn-Sham bands.

Parameters
energiesBand energies ε_m at the central k point.
occupiedUnit occupation flags for the bands at the central k point.
hamiltonianNormalized Taylor coefficients of the AO Hamiltonian H(k).
rho0Normalized Taylor coefficients of the equilibrium density matrix.
active_gradeHighest total derivative grade to compute; omit for all five grades.
Note
At the central k point, rho0_mn = occupied_m delta_mn with occupied_m=0 or 1. At nearby k, rho0(k) = sum_(m occupied) |u_m(k)><u_m(k)|. This is a spectral projector because rho0**2 = rho0; it is also the equilibrium density matrix for unit band occupation. The actual spin occupation factor is applied later during Brillouin-zone integration. The routine obtains analytic k derivatives from H rho0 = rho0 H and rho0**2 = rho0, without differentiating individual eigenvectors. It does not calculate the field-induced rho^(1), rho^(2), etc.

Definition at line 337 of file nlo_derivatives.F.

Here is the call graph for this function:

◆ derivatives_index()

integer function, public nlo_derivatives::derivatives_index ( integer, dimension(3, nlo_n_derivatives), intent(in) alpha,
integer, dimension(3), intent(in) sought )

Find the Taylor coefficient for the requested (x,y,z) derivative counts.

Parameters
alphaCartesian derivative counts (α_x, α_y, α_z) for each Taylor coefficient.
soughtRequested Cartesian derivative counts; negative counts return zero.
Returns
Its index in alpha, or zero when any count is negative or absent.

Definition at line 438 of file nlo_derivatives.F.

Here is the caller graph for this function:

Variable Documentation

◆ nlo_max_derivatives_order

integer, parameter, public nlo_derivatives::nlo_max_derivatives_order = 5

Definition at line 29 of file nlo_derivatives.F.

◆ nlo_n_derivatives

integer, parameter, public nlo_derivatives::nlo_n_derivatives = 56

Definition at line 29 of file nlo_derivatives.F.