![]() |
|
High-precision calculations for one- and two-valence atomic systems
|
Correlation potential, Sigma, for valence states.
Core-valence correlations, stored as a non-local matrix for each kappa, on a radial sub-grid (every stride-th point of the full grid, between r0 and rmax). Formed at a given energy (see formSigma). Read from file if it exists, so it need only be formed once (see write).
Direct diagrams are formed using either the Goldstone (basis sum) or Feynman (Green's function) technique; the Feynman technique allows all-order inclusion of screening and the hole-particle interaction. Exchange diagrams always use Goldstone, with optional effective screening factors fk.
The action of Sigma on a state (SigmaFv) includes:
Optionally also forms the energy derivative, \( \partial\Sigma/\partial\varepsilon \) (see dSigmaFv).
#include <CorrelationPotential.hpp>
Public Member Functions | |
| CorrelationPotential (const std::string &fname, const HF::HartreeFock *vHF, const std::vector< DiracSpinor > &basis, double r0, double rmax, std::size_t stride, int n_min_core, SigmaMethod method, bool include_g=false, bool include_Breit_b2=false, int n_max_breit=0, const FeynmanOptions &Foptions={}, bool calculate_fk=true, const std::vector< double > &fk={}, const std::vector< double > &etak={}, const std::string &ladder_file="", bool form_derivative=false, bool fk_both_lines=false, bool tail_extrapolation=false) | |
| Reads Sigma from file if it exists; otherwise sets up to form it. | |
| void | formSigma (int kappa, double ev, int n, const DiracSpinor *Fv=nullptr) |
Forms and stores Sigma for given kappa, at energy ev. | |
| bool | empty () const |
| True if no Sigma matrices are stored. | |
| const GMatrix * | getSigma (int kappa, int n=0) const |
| Pointer to the stored Sigma matrix for given kappa (and n). | |
| double | getLambda (int kappa, int n=0) const |
| Scaling factor, lambda, for given kappa (and n); 1 if not present. | |
| void | clear () |
| Removes all stored Sigma matrices (not ladder or dSigma/dE) | |
| DiracSpinor | SigmaFv (const DiracSpinor &Fv) const |
| Returns Sigma|Fv>, including lambda scaling, ladder, and tail. | |
| DiracSpinor | operator() (const DiracSpinor &Fv) const |
| Same as SigmaFv. | |
| void | print_de (const std::vector< DiracSpinor > &valence) |
| Prints MBPT(2) energy correction for each valence state. | |
| void | print_tail (const std::vector< DiracSpinor > &valence) const |
| Prints a_eff for each valence state with a fitted large-r tail. | |
| bool | has_derivative () const |
| True if any dSigma/dE matrices are present (see form_derivative) | |
| const SigmaData * | get_derivative (int kappa, int n=0) const |
| Pointer to dSigma/dE data for given kappa (and n); nullptr if not present. | |
| DiracSpinor | dSigmaFv (const DiracSpinor &Fv) const |
| Returns lambda * dSigma/dE |Fv>. | |
| void | scale_Sigma (const std::vector< double > &lambdas) |
| Stores scaling factors, lambda, for each stored Sigma. | |
| void | scale_Sigma (double lambda, int kappa, int n=0) |
| Stores scaling factor, lambda, for Sigma with given kappa and n. | |
| void | print_scaling () const |
| Prints the scaling factors to screen. | |
| void | print_info () const |
| Prints kappa, energy, lambda, and if dSigma/dE exists, for each Sigma. | |
| std::string | method_string () const |
| Short string identifying the method (main differences only). | |
| std::string | lambda_string () const |
| Fitting (scaling) factors as a string, "kappa=value,". | |
| std::vector< double > | average_fk (int l_max=2) const |
Average of the stored fk screening factors, over l up to l_max. | |
| void | print_subGrid () const |
| Prints the sub-grid parameters to screen. | |
| void | write (const std::string &fname) |
Writes Sigma matrices to file fname. | |
| const SigmaData * | get (int kappa, int n=0) const |
| Pointer to the stored Sigma data for given kappa (and n). | |
| CorrelationPotential & | operator= (const CorrelationPotential &)=default |
| CorrelationPotential (const CorrelationPotential &)=default | |
| MBPT::CorrelationPotential::CorrelationPotential | ( | const std::string & | fname, |
| const HF::HartreeFock * | vHF, | ||
| const std::vector< DiracSpinor > & | basis, | ||
| double | r0, | ||
| double | rmax, | ||
| std::size_t | stride, | ||
| int | n_min_core, | ||
| SigmaMethod | method, | ||
| bool | include_g = false, |
||
| bool | include_Breit_b2 = false, |
||
| int | n_max_breit = 0, |
||
| const FeynmanOptions & | Foptions = {}, |
||
| bool | calculate_fk = true, |
||
| const std::vector< double > & | fk = {}, |
||
| const std::vector< double > & | etak = {}, |
||
| const std::string & | ladder_file = "", |
||
| bool | form_derivative = false, |
||
| bool | fk_both_lines = false, |
||
| bool | tail_extrapolation = false |
||
| ) |
Reads Sigma from file if it exists; otherwise sets up to form it.
If fname exists, Sigma is read from it. Otherwise, sets up the Goldstone/Feynman method; Sigma itself is only formed by formSigma. The ladder file, if given, is read in either case.
| fname | Sigma file (read if it exists; see write) |
| vHF | Hartree-Fock (core, grid, Breit). Pointer is stored: must outlive this object |
| basis | Basis for the Goldstone sums (and print_de) |
| r0 | Sub-grid first point (aB) |
| rmax | Sub-grid last point (aB) |
| stride | Sub-grid stride: every stride-th point of the full grid |
| n_min_core | Minimum n of core states included in polarisation (lower core states are frozen) |
| method | Goldstone or Feynman, for direct diagrams |
| include_g | Include small-component (fg, gf, gg) parts of Sigma |
| include_Breit_b2 | Include two-body Breit (B2) correction (only if vHF includes Breit) |
| n_max_breit | Maximum n of excited states in the B2 correction (0: all) |
| Foptions | Options for the Feynman method (screening, hole-particle, etc.) |
| calculate_fk | Calculate fk screening factors for exchange, for each state (Feynman, with screening); else fk used |
| fk | Effective screening factors, for each multipole k |
| etak | Effective hole-particle factors, for each k (Goldstone only) |
| ladder_file | File with ladder correction, Sigma_L (empty: none) |
| form_derivative | Also form dSigma/dE (see dSigmaFv) |
| fk_both_lines | Apply fk to both Coulomb lines of the exchange diagrams (else outer only) |
| tail_extrapolation | Extrapolate Sigma beyond the sub-grid as a_eff/r^4 (experimental; see fit_tail_coefficient) |
include_g are taken from the file, not the inputs. | void MBPT::CorrelationPotential::formSigma | ( | int | kappa, |
| double | ev, | ||
| int | n, | ||
| const DiracSpinor * | Fv = nullptr |
||
| ) |
Forms and stores Sigma for given kappa, at energy ev.
If Sigma already exists for kappa and n (any n if n <= 0), it is not re-formed; only the tail fit and dSigma/dE are added if required and missing (e.g., Sigma read from file).
| kappa | Dirac quantum number |
| ev | Energy at which Sigma is formed |
| n | Principal quantum number: allows distinct Sigma for each n of the same kappa |
| Fv | State Sigma is formed for (optional): used to calculate fk screening factors, fit the large-r tail, and print the energy shift. Must have kappa = kappa. |
|
inline |
True if no Sigma matrices are stored.
| const GMatrix * MBPT::CorrelationPotential::getSigma | ( | int | kappa, |
| int | n = 0 |
||
| ) | const |
Pointer to the stored Sigma matrix for given kappa (and n).
See get() for the choice of n.
| double MBPT::CorrelationPotential::getLambda | ( | int | kappa, |
| int | n = 0 |
||
| ) | const |
Scaling factor, lambda, for given kappa (and n); 1 if not present.
|
inline |
Removes all stored Sigma matrices (not ladder or dSigma/dE)
| DiracSpinor MBPT::CorrelationPotential::SigmaFv | ( | const DiracSpinor & | Fv | ) | const |
Returns Sigma|Fv>, including lambda scaling, ladder, and tail.
\( \lambda (\Sigma + \Sigma_L) \ket{F_v} \): scaled by lambda, and includes the ladder correction \( \Sigma_L \) if present. Includes the large-r tail if it was fitted (see tail_extrapolation option).
|
inline |
Same as SigmaFv.
| void MBPT::CorrelationPotential::print_de | ( | const std::vector< DiracSpinor > & | valence | ) |
Prints MBPT(2) energy correction for each valence state.
Direct, exchange, and total, and \( \langle v|\Sigma|v \rangle \) using the stored Sigma matrix.
| void MBPT::CorrelationPotential::print_tail | ( | const std::vector< DiracSpinor > & | valence | ) | const |
Prints a_eff for each valence state with a fitted large-r tail.
Also prints \( \langle v|\Sigma|v \rangle \) without (S0) and with (S) the tail. Prints nothing if tail_extrapolation is off.
|
inline |
True if any dSigma/dE matrices are present (see form_derivative)
| const SigmaData * MBPT::CorrelationPotential::get_derivative | ( | int | kappa, |
| int | n = 0 |
||
| ) | const |
Pointer to dSigma/dE data for given kappa (and n); nullptr if not present.
| DiracSpinor MBPT::CorrelationPotential::dSigmaFv | ( | const DiracSpinor & | Fv | ) | const |
Returns lambda * dSigma/dE |Fv>.
\( \lambda \, (\partial\Sigma/\partial\varepsilon) \ket{F_v} \). The energy derivative of Sigma, formed by finite difference alongside Sigma itself (option form_derivative), so it corresponds to the actual method used (Goldstone/Feynman, screening, etc.). Scaled by the same lambda as the base Sigma.
| void MBPT::CorrelationPotential::scale_Sigma | ( | const std::vector< double > & | lambdas | ) |
Stores scaling factors, lambda, for each stored Sigma.
\( \Sigma \to \lambda\Sigma \). One factor for each stored Sigma, in the order they were formed.
| void MBPT::CorrelationPotential::scale_Sigma | ( | double | lambda, |
| int | kappa, | ||
| int | n = 0 |
||
| ) |
Stores scaling factor, lambda, for Sigma with given kappa and n.
\( \Sigma \to \lambda\Sigma \). If n <= 0, for all Sigma with given kappa.
| void MBPT::CorrelationPotential::print_scaling | ( | ) | const |
Prints the scaling factors to screen.
| void MBPT::CorrelationPotential::print_info | ( | ) | const |
Prints kappa, energy, lambda, and if dSigma/dE exists, for each Sigma.
| std::string MBPT::CorrelationPotential::method_string | ( | ) | const |
Short string identifying the method (main differences only).
E.g., "Feynman, all-order" or "Goldstone". Intended for file-cache keys.
| std::string MBPT::CorrelationPotential::lambda_string | ( | ) | const |
Fitting (scaling) factors as a string, "kappa=value,".
Rounded to 4 dp; empty if none scaled. For file-cache keys (e.g., the ci-file hash).
| std::vector< double > MBPT::CorrelationPotential::average_fk | ( | int | l_max = 2 | ) | const |
Average of the stored fk screening factors, over l up to l_max.
Averaged over the lowest Sigma of each l. For re-use of the Sigma_1 screening in Sigma_2 (CI), where there is one effective fk per Coulomb line but no unique state: the low-l factors are the relevant ones for the CI valence space (higher-l factors can differ significantly, e.g., f/g at k = 0, but such states rarely contribute). Weighted by l, not kappa: the fine-structure pair of each l is averaged first, then the mean is taken over the ls (so s counts the same as p, d, ...). Truncated to the shortest stored list.
| l_max | Maximum l included in the average (CI uses 2: s, p, d). |
| void MBPT::CorrelationPotential::print_subGrid | ( | ) | const |
Prints the sub-grid parameters to screen.
|
inline |
Writes Sigma matrices to file fname.
Includes the sub-grid, dSigma/dE, and fk. Not written: lambda, a_eff (re-fitted in formSigma), or the ladder correction.
| const SigmaData * MBPT::CorrelationPotential::get | ( | int | kappa, |
| int | n = 0 |
||
| ) | const |
Pointer to the stored Sigma data for given kappa (and n).
If n <= 0, the first stored Sigma with given kappa. Otherwise, the one with given n; if none, the nearest lower n, else the first with given kappa.