ampsci
High-precision calculations for one- and two-valence atomic systems
SphericalBessel Namespace Reference

Detailed Description

Wrappers for returning Spherical Bessel functions.

Has an "exact" version, and a faster approx version (good to ~ 1.e-9)

Classes

class  JL_table
 Spherical Bessel Lookup table; in the form j_L(qr) = J[L][q][r]. More...
 

Functions

double jL (int L, double x)
 Spherical Bessel function; uses low-x approximation where appropriate.
 
double exactGSL_JL (int L, double x)
 Spherical Bessel function of first kind via GSL.
 
double exactGSL_YL (int L, double x)
 Spherical Bessel functions of second kind.
 
double yL (int L, double x)
 Used for frequency-dependent Breit - more generic formula that can be used to evaluate spherical Bessel function of second kind for negative orders.
 
double PhiL (int L, double x, bool tilde=false)
 Phi_L(x) = [(2L+1)!! / x^L] * j_L(x). If tilde=true, returns 1 - Phi_L(x)
 
double PsiL (int L, double x, bool tilde=false)
 Psi_L(x) = [x^{L+1} / (2L-1)!!] * y_L(x). If tilde=true, returns 1 - Psi_L(x)
 
std::vector< double > fillBesselVec (int l, const std::vector< double > &xvec)
 Spherical Bessel functions of second kind.
 
std::vector< double > fillBesselVec_kr (int l, double k, const std::vector< double > &rvec)
 
void fillBesselVec_kr (int l, double k, const std::vector< double > &r, std::vector< double > *jl)
 

Function Documentation

◆ jL()

double SphericalBessel::jL ( int  L,
double  x 
)

Spherical Bessel function; uses low-x approximation where appropriate.

◆ exactGSL_JL()

double SphericalBessel::exactGSL_JL ( int  L,
double  x 
)

Spherical Bessel function of first kind via GSL.

◆ exactGSL_YL()

double SphericalBessel::exactGSL_YL ( int  L,
double  x 
)

Spherical Bessel functions of second kind.

◆ yL()

double SphericalBessel::yL ( int  L,
double  x 
)

Used for frequency-dependent Breit - more generic formula that can be used to evaluate spherical Bessel function of second kind for negative orders.

Spherical Bessel function of second kind, y_L(x)

◆ PhiL()

double SphericalBessel::PhiL ( int  L,
double  x,
bool  tilde 
)

Phi_L(x) = [(2L+1)!! / x^L] * j_L(x). If tilde=true, returns 1 - Phi_L(x)

◆ PsiL()

double SphericalBessel::PsiL ( int  L,
double  x,
bool  tilde 
)

Psi_L(x) = [x^{L+1} / (2L-1)!!] * y_L(x). If tilde=true, returns 1 - Psi_L(x)

◆ fillBesselVec()

std::vector< double > SphericalBessel::fillBesselVec ( int  l,
const std::vector< double > &  xvec 
)

Spherical Bessel functions of second kind.

Creates a vector of Jl(r) for given r