ampsci
c++ program for high-precision atomic structure calculations of single-valence systems
|
Stores Wavefunction (set of valence orbitals, grid, HF etc.) More...
#include <Wavefunction.hpp>
Public Member Functions | |
Wavefunction (std::shared_ptr< const Grid > grid, const Nuclear::Nucleus &nucleus, double var_alpha=1.0, const std::string &run_label="") | |
Construct with a Grid [shared resource], a nucleus (isotope data etc.), and (optional) fractional variation in alpha [alpha = var_alpha * alpha_0, alpha_0=~1/137]. | |
Wavefunction (const GridParameters &gridparams, const Nuclear::Nucleus &nucleus, double var_alpha=1.0, const std::string &run_label="") | |
As above, but Grid is constructed here using given parameters. | |
const Grid & | grid () const |
Returns a const reference to the radial grid. | |
std::shared_ptr< const Grid > | grid_sptr () const |
Copy of shared_ptr to grid [shared resource] - used when we want to construct a new object that shares this grid. | |
double | alpha () const |
Local value of fine-structure constant. | |
double | dalpha2 () const |
Variation in alpha^2 : x = (alpha/alpha_0)^2 - 1. | |
const Nuclear::Nucleus & | nucleus () const |
Returns Nuclear::nucleus object (contains nuc. parameters) | |
int | Znuc () const |
Nuclear charge, Z. | |
int | Anuc () const |
Nuclear mass number, A. | |
double | get_rrms () const |
Nuclear rms charge radii, in fm (femptometres) | |
const std::vector< DiracSpinor > & | core () const |
Core orbitals (frozen HF core) | |
const std::vector< DiracSpinor > & | valence () const |
Valence orbitals (HF or Brueckner orbitals) | |
std::vector< DiracSpinor > & | valence () |
const std::vector< DiracSpinor > & | hf_valence () const |
const std::vector< DiracSpinor > & | basis () const |
Basis, eigenstates of HF potential. Used for MBPT. Includes Breit and QED (if they are included), but not correlations. | |
std::vector< DiracSpinor > & | basis () |
const std::vector< DiracSpinor > & | spectrum () const |
Sprectrum: like basis, but includes correlations. | |
std::vector< DiracSpinor > & | spectrum () |
const std::vector< CI::PsiJPi > & | CIwfs () const |
const CI::PsiJPi * | CIwf (int J, int parity) const |
const std::vector< double > & | vnuc () const |
Nuclear potential. Only provide const version, since HF and WF version of vnuc must be kept in sync. | |
const HF::HartreeFock * | vHF () const |
Returns ptr to Hartree Fock (class) | |
HF::HartreeFock * | vHF () |
std::vector< double > | vlocal (int l=0) const |
Local part of potential, e.g., Vl = Vnuc + Vdir + Vrad_el(l) - can be l-dependent. Returns a copy. | |
std::vector< double > | Hmag (int l=0) const |
QED Magnetic form factor. May return empty vector. Not typically l-dependent, but may be in future. Returns a copy. | |
const QED::RadPot * | vrad () const |
Pointer to QED radiative potnential. May be nullptr. | |
QED::RadPot * | vrad () |
const MBPT::CorrelationPotential * | Sigma () const |
Returns ptr to (const) Correlation Potential, Sigma. | |
MBPT::CorrelationPotential * | Sigma () |
int | Ncore () const |
Number of electrons in the core. | |
const DiracSpinor * | getState (int n, int k) const |
Finds requested state; returns nullptr if not found. More... | |
const DiracSpinor * | getState (std::string_view state) const |
As above, but takes 'short symbol' (e.g., 6s+, 6p-) | |
double | FermiLevel () const |
Returns energy location of the "Fermi Level", - energy half way between core/valence. Defined: 0.5*( max(e_core) + min(e_valence)). Should be -ve. | |
double | energy_gap () const |
Energy gap between lowest valence + highest core state: e(v) - e(c) [should be positive]. | |
std::string | coreConfiguration () const |
Returns full core configuration. | |
std::string | coreConfiguration_nice () const |
Returns core configuration, in nice output notation. | |
std::string | atom () const |
String of atom info (e.g., "Cs, Z=55, A=133") | |
std::string | atomicSymbol () const |
e.g., "Cs" | |
std::string | identity () const |
Atomic symbol, including core ionisation degree and run_label. | |
int | ion_degree (int num_val) const |
0 for neutral, 1 for singly-ionised etc. | |
std::string | ion_symbol (int num_val) const |
I for neutral, II for singly-ionised etc. | |
int | Zion () const |
Effective charge (for core) = Z-N_core. | |
void | printCore () const |
Prints table of core orbitals + energies etc. | |
void | printValence (const std::vector< DiracSpinor > &tmp_orbitals={}) const |
Prints table of valence orbitals + energies etc. More... | |
void | printBasis (const std::vector< DiracSpinor > &the_basis) const |
Prints table of Basis/Spectrum orbitals, compares to HF orbitals. | |
bool | isInCore (int n, int k) const |
Check if a state is in the core (or valence) list. | |
bool | isInValence (int n, int k) const |
std::vector< double > | coreDensity () const |
Calculates rho(r) = sum_c psi^2(r) for core states, c={n,k,m}. | |
double | coreEnergyHF () const |
Calculates HF core energy (doesn't include magnetic QED?) | |
void | set_HF (const std::string &method="HartreeFock", const double x_Breit=0.0, const std::string &in_core="", double eps_HF=1.0e-13, bool print=true) |
Initialises HF object and populates core orbitals (does not solve HF equations) | |
void | solve_core (bool print=true) |
Performs hartree-Fock procedure for core. | |
void | solve_core (const std::string &method, const double x_Breit=0.0, const std::string &in_core="", double eps_HF=1.0e-13, bool print=true) |
This version will first set_HF(), then solve_core() | |
void | solve_valence (const std::string &in_valence_str="", const bool print=true) |
Performs hartree-Fock procedure for valence: note: poplulates valnece. | |
void | hartreeFockBrueckner (const bool print=true) |
Forms Bruckner valence orbitals: (H_hf + Sigma)|nk> = e|nk>. Replaces existing valence states. | |
void | fitSigma_hfBrueckner (const std::string &valence_list, const std::vector< double > &fit_energies) |
First, fits Sigma to energies, then forms fitted Brueckner orbitals. | |
void | radiativePotential (QED::RadPot::Scale s, double rcut, double scale_rN, const std::vector< double > &x_spd, bool do_readwrite=true, bool print=true) |
OLD: deprecated. | |
void | radiativePotential (const IO::InputBlock &qed_input, bool do_readwrite, bool print) |
Calculates radiative potential, adds to HF potential. | |
void | formBasis (const SplineBasis::Parameters ¶ms) |
Calculates + populates basis [see BSplineBasis]. | |
void | formSpectrum (const SplineBasis::Parameters ¶ms) |
Calculates + populates Spectrum [see BSplineBasis]. | |
void | formSigma (int nmin_core=1, int nmin_core_F=1, double r0=1.0e-4, double rmax=30.0, int stride=4, bool each_valence=false, bool include_G=false, bool include_Breit=false, int n_max_breit=0, const std::vector< double > &lambdas={}, const std::vector< double > &fk={}, const std::vector< double > &etak={}, const std::string &in_fname="", const std::string &out_fname="", bool FeynmanQ=false, bool ScreeningQ=false, bool holeParticleQ=false, int lmax=6, double omre=-0.2, double w0=0.01, double wratio=1.5, const std::optional< IO::InputBlock > &ek=std::nullopt) |
Forms + stores correlation potential Sigma. | |
void | copySigma (const MBPT::CorrelationPotential *const Sigma) |
void | update_Vnuc (const std::vector< double > &v_new) |
Allows extra potential to be added to Vnuc (updates both in Wavefunction. More... | |
std::tuple< double, double > | lminmax_core_range (int l, double eps=0.0) const |
Returns [min,max] r values for which the core density (given l) is larger than cutoff (= eps*max_value) More... | |
double | H0ab (const DiracSpinor &Fa, const DiracSpinor &Fb) const |
Returns <a|H|b> for Hamiltonian H (inludes Rad.pot, NOT sigma, Breit, or exchange!) | |
double | H0ab (const DiracSpinor &Fa, const DiracSpinor &dFa, const DiracSpinor &Fb, const DiracSpinor &dFb) const |
Returns <a|H|b> for Hamiltonian H (inludes Rad.pot, NOT sigma, Breit, or exchange!) | |
double | Hab (const DiracSpinor &Fa, const DiracSpinor &Fb) const |
void | ConfigurationInteraction (const IO::InputBlock &input) |
Stores Wavefunction (set of valence orbitals, grid, HF etc.)
const DiracSpinor * Wavefunction::getState | ( | int | n, |
int | k | ||
) | const |
Finds requested state; returns nullptr if not found.
is_valence is optional out-parameter; tells you where orb was found
std::tuple< double, double > Wavefunction::lminmax_core_range | ( | int | l, |
double | eps = 0.0 |
||
) | const |
Returns [min,max] r values for which the core density (given l) is larger than cutoff (= eps*max_value)
Returns the r values (au) for which the value of rho = \sum|psi^2|(r) drops below cutoff. Sum goes over all m for given l. Cut-off defined as eps*max, where max is maximum value for rho(r). Set l<0 to get for all l (entire core)
void Wavefunction::printValence | ( | const std::vector< DiracSpinor > & | tmp_orbitals = {} | ) | const |
Prints table of valence orbitals + energies etc.
Can optionally give it any list of orbitals to print
|
inline |
Allows extra potential to be added to Vnuc (updates both in Wavefunction.
nb: two versions of Vnuc...