ampsci
High-precision calculations for one- and two-valence atomic systems
Coulomb::YkTable

Calculates + stores Hartree Y functions + Angular (w/ look-up), taking advantage of symmetry. More...

#include <YkTable.hpp>

Public Member Functions

 YkTable (const std::vector< DiracSpinor > &a_orbs, const std::vector< DiracSpinor > &b_orbs)
 
 YkTable (const std::vector< DiracSpinor > &a_orbs)
 
void calculate (const std::vector< DiracSpinor > &as, const std::vector< DiracSpinor > &bs)
 Re-calculates all y_ab functions (will over-ride existing ones); NOTE: only calculates for a in as, b in bs.
 
void calculate (const std::vector< DiracSpinor > &as)
 Re-calculates all y_ij functions (will over-ride existing ones) [i and j in as].
 
void extend_angular (int new_max_2j)
 Extends the Ck and 6J tables up to new maximum 2*j.
 
const Angular::CkTableCk () const
 Returns a (const ref) to Ck table [see Angular::CkTable].
 
const Angular::SixJTableSixJ () const
 Returns a (const ref) to SixJ table [see Angular::SixJTable].
 
const std::vector< double > * get (const int k, const DiracSpinor &Fa, const DiracSpinor &Fb) const
 Returns a pointer to constant vector y^k_ab. If that integral is not stored, returns nullptr.
 
double R (const int k, const DiracSpinor &Fa, const DiracSpinor &Fb, const DiracSpinor &Fc, const DiracSpinor &Fd) const
 Calculates Rk using the existing yk integrals. Note: Yk and Ck tables must include all required values, or behaviour not defined.
 
double Q (const int k, const DiracSpinor &Fa, const DiracSpinor &Fb, const DiracSpinor &Fc, const DiracSpinor &Fd) const
 Calculates Qk using the existing yk integrals. Note: Yk and Ck tables must include all required values, or behaviour not defined.
 
double P (const int k, const DiracSpinor &Fa, const DiracSpinor &Fb, const DiracSpinor &Fc, const DiracSpinor &Fd) const
 Calculates Pk using the existing yk integrals. Note: Yk and Ck tables must include all required values, or behaviour not defined.
 
double P2 (const int k, const DiracSpinor &Fa, const DiracSpinor &Fb, const DiracSpinor &Fc, const DiracSpinor &Fd, const std::vector< double > &fk={}) const
 
double W (const int k, const DiracSpinor &Fa, const DiracSpinor &Fb, const DiracSpinor &Fc, const DiracSpinor &Fd) const
 Calculates Wk=Qk+Pk using the existing yk integrals. Note: Yk and Ck tables must include all required values, or behaviour not defined.
 
DiracSpinor Qkv_bcd (const int k, int kappa, const DiracSpinor &Fb, const DiracSpinor &Fc, const DiracSpinor &Fd) const
 Calculates Q^K(v)_bcd using existing yk integrals. Note: Yk and Ck tables must include all required values, or behaviour not defined.
 
DiracSpinor Pkv_bcd (const int k, int kappa, const DiracSpinor &Fb, const DiracSpinor &Fc, const DiracSpinor &Fd, const std::vector< double > &f2k={}) const
 Calculates P^K(v)_bcd using existing yk integrals, including (optional) screening factors. Note: Yk and Ck tables must include all required values, or behaviour not defined.
 
bool empty () const
 Checks if table is empty.
 

Detailed Description

Calculates + stores Hartree Y functions + Angular (w/ look-up), taking advantage of symmetry.

Also stores a Ck and 6J table

Definitions:

\[ y^k_{ij}(r) = \int_0^\infty \frac{r_<^k}{r_>^{k+1}}\rho_{ij}(r')\,{\rm d}r' \]

\[\rho(r) = f_i(r)f_j(r) + g_i(r)g_j(r)\]

with \(r_< = min(r,r')\)

Member Function Documentation

◆ calculate() [1/2]

void Coulomb::YkTable::calculate ( const std::vector< DiracSpinor > &  as,
const std::vector< DiracSpinor > &  bs 
)

Re-calculates all y_ab functions (will over-ride existing ones); NOTE: only calculates for a in as, b in bs.

Note: will re-calculate all, so don't use this to 'extend' the table.

◆ calculate() [2/2]

void Coulomb::YkTable::calculate ( const std::vector< DiracSpinor > &  as)
inline

Re-calculates all y_ij functions (will over-ride existing ones) [i and j in as].

◆ extend_angular()

void Coulomb::YkTable::extend_angular ( int  new_max_2j)

Extends the Ck and 6J tables up to new maximum 2*j.

◆ Ck()

const Angular::CkTable & Coulomb::YkTable::Ck ( ) const
inline

Returns a (const ref) to Ck table [see Angular::CkTable].

◆ SixJ()

const Angular::SixJTable & Coulomb::YkTable::SixJ ( ) const
inline

Returns a (const ref) to SixJ table [see Angular::SixJTable].

◆ get()

const std::vector< double > * Coulomb::YkTable::get ( const int  k,
const DiracSpinor Fa,
const DiracSpinor Fb 
) const

Returns a pointer to constant vector y^k_ab. If that integral is not stored, returns nullptr.

◆ R()

double Coulomb::YkTable::R ( const int  k,
const DiracSpinor Fa,
const DiracSpinor Fb,
const DiracSpinor Fc,
const DiracSpinor Fd 
) const

Calculates Rk using the existing yk integrals. Note: Yk and Ck tables must include all required values, or behaviour not defined.

◆ Q()

double Coulomb::YkTable::Q ( const int  k,
const DiracSpinor Fa,
const DiracSpinor Fb,
const DiracSpinor Fc,
const DiracSpinor Fd 
) const

Calculates Qk using the existing yk integrals. Note: Yk and Ck tables must include all required values, or behaviour not defined.

◆ P()

double Coulomb::YkTable::P ( const int  k,
const DiracSpinor Fa,
const DiracSpinor Fb,
const DiracSpinor Fc,
const DiracSpinor Fd 
) const

Calculates Pk using the existing yk integrals. Note: Yk and Ck tables must include all required values, or behaviour not defined.

◆ W()

double Coulomb::YkTable::W ( const int  k,
const DiracSpinor Fa,
const DiracSpinor Fb,
const DiracSpinor Fc,
const DiracSpinor Fd 
) const

Calculates Wk=Qk+Pk using the existing yk integrals. Note: Yk and Ck tables must include all required values, or behaviour not defined.

◆ Qkv_bcd()

DiracSpinor Coulomb::YkTable::Qkv_bcd ( const int  k,
int  kappa,
const DiracSpinor Fb,
const DiracSpinor Fc,
const DiracSpinor Fd 
) const

Calculates Q^K(v)_bcd using existing yk integrals. Note: Yk and Ck tables must include all required values, or behaviour not defined.

◆ Pkv_bcd()

DiracSpinor Coulomb::YkTable::Pkv_bcd ( const int  k,
int  kappa,
const DiracSpinor Fb,
const DiracSpinor Fc,
const DiracSpinor Fd,
const std::vector< double > &  f2k = {} 
) const

Calculates P^K(v)_bcd using existing yk integrals, including (optional) screening factors. Note: Yk and Ck tables must include all required values, or behaviour not defined.

◆ empty()

bool Coulomb::YkTable::empty ( ) const
inline

Checks if table is empty.


The documentation for this class was generated from the following files: