2 #include "Angular/CkTable.hpp"
3 #include "Angular/SixJTable.hpp"
4 #include "Wavefunction/DiracSpinor.hpp"
5 #include <unordered_map>
29 std::vector<std::unordered_map<uint32_t, std::vector<double>>> m_Y{};
34 YkTable(
const std::vector<DiracSpinor> &a_orbs,
35 const std::vector<DiracSpinor> &b_orbs) {
46 void calculate(
const std::vector<DiracSpinor> &as,
47 const std::vector<DiracSpinor> &bs);
67 [[nodiscard]]
double R(
const int k,
const DiracSpinor &Fa,
73 [[nodiscard]]
double Q(
const int k,
const DiracSpinor &Fa,
79 [[nodiscard]]
double P(
const int k,
const DiracSpinor &Fa,
83 [[nodiscard]]
double P2(
const int k,
const DiracSpinor &Fa,
86 const std::vector<double> &fk = {})
const;
90 [[nodiscard]]
double W(
const int k,
const DiracSpinor &Fa,
106 const DiracSpinor &Fd,
const std::vector<double> &f2k = {})
const;
112 void allocate_space(
const std::vector<DiracSpinor> &a_orbs,
113 const std::vector<DiracSpinor> &b_orbs);
120 std::vector<double> &get_or_insert(std::size_t k, uint32_t key);
123 std::vector<double> &get_ref(
const int k,
const DiracSpinor &Fa,
Lookup table for C^k and 3j symbols (special m=1/2, q=0 case)
Definition: CkTable.hpp:42
Lookup table for Wigner 6J symbols.
Definition: SixJTable.hpp:24
Calculates + stores Hartree Y functions + Angular (w/ look-up), taking advantage of symmetry.
Definition: YkTable.hpp:26
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....
Definition: YkTable.cpp:221
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 v...
Definition: YkTable.cpp:201
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 value...
Definition: YkTable.cpp:127
const Angular::SixJTable & SixJ() const
Returns a (const ref) to SixJ table [see Angular::SixJTable].
Definition: YkTable.hpp:58
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,...
Definition: YkTable.cpp:14
const Angular::CkTable & Ck() const
Returns a (const ref) to Ck table [see Angular::CkTable].
Definition: YkTable.hpp:56
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.
Definition: YkTable.cpp:70
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...
Definition: YkTable.cpp:195
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 value...
Definition: YkTable.cpp:118
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 value...
Definition: YkTable.cpp:145
void extend_angular(int new_max_2j)
Extends the Ck and 6J tables up to new maximum 2*j.
Definition: YkTable.cpp:46
void calculate(const std::vector< DiracSpinor > &as)
Re-calculates all y_ij functions (will over-ride existing ones) [i and j in as].
Definition: YkTable.hpp:50
Stores radial Dirac spinor: F_nk = (f, g)
Definition: DiracSpinor.hpp:41
Functions (+classes) for computing Coulomb integrals.
Definition: Coulomb.hpp:8