(git:9ccafda)
Loading...
Searching...
No Matches
gaunt_coefficients Module Reference

Expansion of the product of two real spherical harmonics in real spherical harmonics. More...

Functions/Subroutines

subroutine, public real_gaunt_coefficients (my_cg, maxl1, maxl2, llmax, cg_none0_list, ncg_none0)
 Calculate the expansion of the product of two real spherical harmonics in real spherical harmonics, S(l1,m1) S(l2,m2) = sum_lm my_cg(iso1,iso2,iso) S(l,m).

Detailed Description

Expansion of the product of two real spherical harmonics in real spherical harmonics.

Note
The expansion coefficients are the Gaunt coefficients of the real spherical harmonics; they are obtained from libwignernj, which evaluates them in exact integer arithmetic. Historically CP2K called these "Clebsch-Gordon coefficients", which they are not, and built them from a table of factorial ratios that lost about one digit per two units of l.
History
09.2026 created out of the five copies of this loop that lived in qs_rho_atom_methods, qs_tddfpt2_soc, qs_cneo_utils, xas_tdp_atom and generic_shg_integrals_init [Susi Lehtola]
Author
Susi Lehtola

Function/Subroutine Documentation

◆ real_gaunt_coefficients()

subroutine, public gaunt_coefficients::real_gaunt_coefficients ( real(kind=dp), dimension(:, :, :), intent(out), pointer my_cg,
integer, intent(in) maxl1,
integer, intent(in) maxl2,
integer, intent(in) llmax,
integer, dimension(:, :, :), intent(out), optional, pointer cg_none0_list,
integer, dimension(:, :), intent(out), optional, pointer ncg_none0 )

Calculate the expansion of the product of two real spherical harmonics in real spherical harmonics, S(l1,m1) S(l2,m2) = sum_lm my_cg(iso1,iso2,iso) S(l,m).

Parameters
my_cgthe expansion coefficients, allocated here; the pointer is INTENT(OUT), so the caller must not rely on its previous contents
maxl1maximal angular momentum of the first harmonic
maxl2maximal angular momentum of the second harmonic
llmaxmaximal angular momentum retained in the expansion
cg_none0_listlist of the harmonics with a non-zero coefficient, allocated here if present
ncg_none0number of harmonics with a non-zero coefficient, allocated here if present

Definition at line 59 of file gaunt_coefficients.F.

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