qimpy.math.spherical_harmonics

Calculate spherical harmonics and their product expansions.

Module Attributes

L_MAX

Maximum l for calculation of harmonics

L_MAX_HLF

Maximum l of harmonics in products

Functions

get_harmonics

Compute real solid harmonics \(r^l Y_{lm}(r)\) for each l <= l_max.

get_harmonics_and_prime

Compute real solid harmonics \(r^l Y_{lm}(r)\) for each l <= l_max.

get_harmonics_tilde

Same as get_harmonics(), but in reciprocal space.

get_harmonics_tilde_and_prime

Same as get_harmonics_and_prime(), but in reciprocal space.

get_product_coefficients

Expansion coefficients of products of real harmonics (real Gaunt coefficients) for l <= l_max, as a tensor of shape ((l_max+1)^2, (l_max+1)^2, (2 l_max+1)^2), with each (l, m) indexed by l(l+1)+m, as for the harmonics above.