MADNESS 0.10.1
madness::CCPotentials Class Reference

Class which calculates all types of CC2 Potentials. More...

#include <CCPotentials.h>

Public Member Functions

 CCPotentials (World &world_, const std::shared_ptr< const Nemo > nemo, const CCParameters &param)
virtual ~CCPotentials ()
real_function_6d apply_exchange_commutator (const CCFunction< double, 3 > &x, const CCFunction< double, 3 > &y, const real_convolution_6d *Gscreen=NULL) const
vector_real_function_3d apply_projector (const CC_vecfunction &f, const CC_vecfunction &ket_) const
real_function_6d apply_Q12t (const real_function_6d &f, const CC_vecfunction &t) const
 Apply Qt projector on 6D function.
vector_real_function_3d apply_Qt (const CC_vecfunction &f, const CC_vecfunction &ket_, const double c=1.0) const
CCPairFunction< double, 6 > apply_Qt (const CCPairFunction< double, 6 > &f, const CC_vecfunction &t, const size_t particle, const double c=1.0) const
real_function_6d apply_reduced_F1 (const CCFunction< double, 3 > &ti, const CCFunction< double, 3 > &tj, const real_convolution_6d *Gscreen=NULL) const
real_function_6d apply_transformed_Ue (const CCFunction< double, 3 > &x, const CCFunction< double, 3 > &y, const real_convolution_6d *Gscreen=NULL) const
real_function_6d apply_Vreg (const CCFunction< double, 3 > &ti, const CCFunction< double, 3 > &tj, const real_convolution_6d *Gscreen=NULL) const
double compute_cc2_excitation_energy (const CC_vecfunction &stau, const CC_vecfunction &sx, const Pairs< CCPair > dtau, const Pairs< CCPair > dx) const
 Compute the CC2 Excitation Energy.
double compute_cispd_energy (const CC_vecfunction &x, const Pairs< CCPair > mp2, const Pairs< CCPair > cispd) const
 Compute the CIS(D) Energy Correction to CIS.
real_function_6d fock_residue_6d (const CCPair &u) const
 The 6D Fock residue on the cusp free pair function u_{ij}(1,2) is: (2J - Kn - Un)|u_{ij}>.
vector_real_function_3d get_active_mo_bra () const
 returns a vector of all active mos multiplied with the squared nuclear currelation factor: mo_bra = R^2*mo_ket
vector_real_function_3d get_active_mo_ket () const
 returns a vector of all active mos without nuclear correlation factor (nemos)
double get_epsilon (const size_t i, const size_t j) const
 returns epsilon_i + epsilon_j (needed for bsh operator of pairs)
vector_real_function_3d get_mo_bra (const CC_vecfunction &ket) const
 get the corresponding mo bra vectors to a ket vector
std::vector< double > get_orbital_energies () const
 returns a vector of all orbital energies
template<typename T, size_t NDIM>
bool load_function (Function< T, NDIM > &f, const std::string name, bool do_print) const
real_function_6d make_6D_pair (const CCPair &pair) const
 Returns the full 6D function from a CCPair structure (only recommended for debug purposes).
vector_real_function_3d make_bra (const CC_vecfunction &t) const
 make bra element: R^2|t>
vector_real_function_3d make_bra (const vector_real_function_3d &t) const
real_function_6d make_constant_part_cispd (const CCPair &u, const CC_vecfunction &x, const real_convolution_6d *Gscreen=NULL) const
 Function evaluates the consant part of the Excited state for CIS(D) if the Q Ansatz is used.
real_function_6d make_constant_part_cispd_Qt (const CCPair &u, const CC_vecfunction &x, const real_convolution_6d *Gscreen=NULL) const
 Function evaluates the consant part of the Excited state for CIS(D) if the Qt Ansatz is used.
CC_vecfunction make_full_t_intermediate (const CC_vecfunction &tau) const
CCPair make_pair_ex (const real_function_6d &u, const CC_vecfunction &tau, const CC_vecfunction &x, const size_t i, const size_t j, const CalcType ctype) const
CCPair make_pair_gs (const real_function_6d &u, const CC_vecfunction &tau, const size_t i, const size_t j) const
CC_vecfunction make_t_intermediate (const CC_vecfunction &tau, const CCParameters &parameters) const
CCFunction< double, 3 > make_t_intermediate (const CCFunction< double, 3 > &tau) const
double make_xy_ff_ab (const CCFunction< double, 3 > &x, const CCFunction< double, 3 > &y, const CCFunction< double, 3 > &a, const CCFunction< double, 3 > &b) const
double make_xy_gf_ab (const CCFunction< double, 3 > &x, const CCFunction< double, 3 > &y, const CCFunction< double, 3 > &a, const CCFunction< double, 3 > &b) const
double make_xy_op_ab (const CCFunction< double, 3 > &x, const CCFunction< double, 3 > &y, const CCConvolutionOperator< double, 3 > &op, const CCFunction< double, 3 > &a, const CCFunction< double, 3 > &b) const
CC_vecfunction mo_bra () const
CCFunction< double, 3 > mo_bra (const size_t &i) const
 returns a specific mo multiplied with the squared nuclear correlation factor
CC_vecfunction mo_ket () const
CCFunction< double, 3 > mo_ket (const size_t &i) const
 returns a specific mo
double overlap (const CCPair &x) const
double overlap (const CCPairFunction< double, 6 > &f1, const CCPairFunction< double, 6 > &f2) const
void plot (const real_function_3d &f, const std::string &msg, const bool doprint=true) const
 Plotting (convenience).
void plot (const vector_real_function_3d &f, const std::string &msg) const
 Plotting (convenience).
template<size_t NDIM>
void print_size (const Function< double, NDIM > &f, const std::string &msg, const bool print=true) const
 print size of a function
void reset_nemo (const std::shared_ptr< const Nemo > nemo)
real_function_6d swap_particles (const real_function_6d &f) const
 dummy to avoid confusion and for convenience
void test ()
bool test_compare_pairs (const CCPair &pair1, const CCPair &pair2) const
void test_pair_consistency (const CCPairFunction< double, 6 > &u, const size_t i, const size_t j, const CC_vecfunction &x) const
 forms the regularized functions from Q and Qt Ansatz for CIS(D) where tau=0 and t=mo so that Qt=Q
void test_pairs ()
void test_singles_potential (Info &info) const
Info update_info (const CCParameters &parameters, const std::shared_ptr< const Nemo > nemo) const

Static Public Member Functions

static CCPairFunction< double, 6 > apply_commutator_F_dQt_f12 (World &world, const CCFunction< double, 3 > &phi_i, const CCFunction< double, 3 > &phi_j, const CC_vecfunction &gs_singles, const CC_vecfunction &ex_singles, const Info &info, const real_convolution_6d *Gscreen)
 calculate [F,dQt] f12 |rhs>
static CCPairFunction< double, 6 > apply_commutator_F_Qt_f12 (World &world, const CCFunction< double, 3 > &phi_i, const CCFunction< double, 3 > &phi_j, const CC_vecfunction &gs_singles, const CC_vecfunction &ex_singles, const Info &info, const real_convolution_6d *Gscreen)
 calculate [F,Qt] f12 |rhs>
static std::vector< CCPairFunction< double, 6 > > apply_f12_coupling (World &world, const CCFunction< double, 3 > &phi_i, const CCFunction< double, 3 > &phi_j, const Info &info, const real_convolution_6d *Gscreen)
 compute the coupled f12 contributions: f12 (\sum_k f_jk |ik> + f_ik |kj>)
static real_function_3d apply_gf (World &world, const real_function_3d &f, const Info &info)
static std::vector< CCPairFunction< double, 6 > > apply_KffK (World &world, const CCFunction< double, 3 > &phi_i, const CCFunction< double, 3 > &phi_j, const LowRankFunction< double, 6 > &exchange_op, const Info &info, const real_convolution_6d *Gscreen)
static real_function_6d apply_Kfxy (World &world, const CCFunction< double, 3 > &x, const CCFunction< double, 3 > &y, const Info &info, const CCParameters &param)
 return Kf12|xy>
static real_function_6d apply_reduced_F (World &world, const CCFunction< double, 3 > &ti, const CCFunction< double, 3 > &tj, const Info &info, const real_convolution_6d *Gscreen=NULL)
static real_function_3d apply_s2b_operation (World &world, const CCFunction< double, 3 > &bra, const CCPairFunction< double, 6 > &u, const size_t particle, const Info &info)
 returns <a|g12|u>_2
static real_function_6d apply_Ue (World &world, const CCFunction< double, 3 > &phi_i, const CCFunction< double, 3 > &phi_j, const Info &info, const real_convolution_6d *Gscreen)
static std::vector< CCPairFunction< double, 6 > > apply_Vreg (World &world, const CCFunction< double, 3 > &ti, const CCFunction< double, 3 > &tj, const CC_vecfunction &gs_singles, const CC_vecfunction &ex_singles, const Info &info, LowRankFunction< double, 6 > exchange_op, const std::vector< std::string > &argument, const double bsh_eps)
 Apply the Regularization potential.
static double compute_cc2_correlation_energy (World &world, const CC_vecfunction &singles, const Pairs< CCPair > &doubles, const Info &info, const std::string msg="")
static double compute_cis_expectation_value (World &world, const CC_vecfunction &x, const vector_real_function_3d &V, const bool print, const Info &info)
 compute the expectation value excitation energy using the CIS/CCS/CC2 singles
static double compute_excited_pair_energy (World &world, const CCPair &d, const CC_vecfunction &x, const Info &info)
static double compute_kinetic_energy (World &world, const vector_real_function_3d &xbra, const vector_real_function_3d &xket)
static double compute_pair_correlation_energy (World &world, const CCPair &u, const CC_vecfunction &singles, const Info &info)
 Compute pair correlation energies of MP2 or CC2 Ground State.
static madness::real_function_6d fock_residue_6d_macrotask (World &world, const CCPair &u, const CCParameters &parameters, const std::vector< madness::Vector< double, 3 > > &all_coords_vec, const std::vector< real_function_3d > &mo_ket, const std::vector< real_function_3d > &mo_bra, const std::vector< real_function_3d > &U1, const real_function_3d &U2)
 Static function for the 6D Fock residue for use in macrotask.
static double get_epsilon (const size_t i, const size_t j, const Info &info)
 returns epsilon_i + epsilon_j (needed for bsh operator of pairs)
static std::vector< CCPairFunction< double, 6 > > get_pair_function (const Pairs< CCPair > &pairs, const size_t i, const size_t j)
static CCPair iterate_pair_macrotask (World &world, const CCPair &pair, const CC_vecfunction &gs_singles, const CC_vecfunction &ex_singles, const real_function_6d &coupling, const Info &info, const long maxiter)
 iterate a pair for MP2, CC2, LRCC2 on constant singles
static CC_vecfunction make_active_t_intermediate (const CC_vecfunction &tau, const Info &info)
 makes the t intermediates
static madness::real_function_6d make_constant_part_macrotask (World &world, const CCPair &pair, const CC_vecfunction &gs_singles, const CC_vecfunction &ex_singles, const LowRankFunction< double, 6 > &exchange_op, const Info &info)
 the constant part is the contribution to the doubles that are independent of the doubles
static CC_vecfunction make_full_t_intermediate (const CC_vecfunction &tau, const Info &info)
 makes the t intermediates
static CCPair make_pair_cc2 (World &world, const real_function_6d &u, const CC_vecfunction &gs_singles, const size_t i, const size_t j, const Info &info, const bool compute_Q12_f12_ij)
 return the regularized CC2 ansatz: |\tau_ij> = |u_ij> + Q12t f12 |t_i t_j>
static CCPair make_pair_lrcc2 (World &world, const CalcType &ctype, const real_function_6d &u, const CC_vecfunction &gs_singles, const CC_vecfunction &ex_singles, const size_t i, const size_t j, const Info &info, const bool compute_Q12_f12)
 return the regularized CC2 ansatz: |x_ij> = |u_ij> + Q12t f12 |t_i t_j> + ?????
static CCPair make_pair_mp2 (World &world, const real_function_6d &u, const size_t i, const size_t j, const Info &info, bool compute_Q12_f12_ij)
 return the regularized MP2 ansatz: |\tau_ij> = |u_ij> + Q12 f12 |ij>
static double make_xy_op_u (const CCFunction< double, 3 > &x, const CCFunction< double, 3 > &y, const CCConvolutionOperator< double, 3 > &op, const CCPairFunction< double, 6 > &u)
static double make_xy_op_u (const CCFunction< double, 3 > &x, const CCFunction< double, 3 > &y, const CCConvolutionOperator< double, 3 > &op, const std::vector< CCPairFunction< double, 6 > > &u)
static double make_xy_u (const CCFunction< double, 3 > &x, const CCFunction< double, 3 > &y, const std::vector< CCPairFunction< double, 6 > > &u)
static void print_3d_references (World &world, const std::vector< CCPair > &pair_vec, const Info &info)
 quick 3D-only Ue / GUe / GQUe references for all pairs (no 6D work)
static std::vector< CCPairFunction< double, 6 > > swap_particles (const std::vector< CCPairFunction< double, 6 > > &f)
 swap the particles of the CCPairFunction and return a new vector of swapped functions

Private Member Functions

std::vector< double > init_orbital_energies (const Nemo &nemo) const
 Transfers Eigenvalues of HF MOs from Nemo (Tensor Format) to std::vector<double> format.
CC_vecfunction make_mo_bra (const Nemo &nemo) const
 Helper function to initialize the const mo_bra and ket elements adn orbital energies.
CC_vecfunction make_mo_ket (const Nemo &nemo) const
 Helper function to initialize the const mo_bra and ket elements.

Detailed Description

Class which calculates all types of CC2 Potentials.

Constructor & Destructor Documentation

◆ CCPotentials()

madness::CCPotentials::CCPotentials ( World & world_,
const std::shared_ptr< const Nemo > nemo,
const CCParameters & param )

◆ ~CCPotentials()

virtual madness::CCPotentials::~CCPotentials ( )
inlinevirtual

Member Function Documentation

◆ apply_commutator_F_dQt_f12()

madness::CCPairFunction< double, 6 > madness::CCPotentials::apply_commutator_F_dQt_f12 ( World & world,
const CCFunction< double, 3 > & phi_i,
const CCFunction< double, 3 > & phi_j,
const CC_vecfunction & gs_singles,
const CC_vecfunction & ex_singles,
const Info & info,
const real_convolution_6d * Gscreen )
static

calculate [F,dQt] f12 |rhs>

Using eq. (31) of Kottmann et al. JCTC 13, 5956 (2017) note that we leave the omega dQ12t term out, as it cancels with eq. (29)

Returns
[F,Qt] f12 |rhs> - omega dQ12 f12 |phi_i phi_j>

References madness::CCConvolutionOperatorPtr(), madness::CCFunction< T, NDIM >::function, madness::CC_vecfunction::get_vecfunction(), MADNESS_CHECK_THROW, make_active_t_intermediate(), madness::OT_F12, madness::outer(), and madness::POT_singles_.

Referenced by apply_Vreg().

◆ apply_commutator_F_Qt_f12()

madness::CCPairFunction< double, 6 > madness::CCPotentials::apply_commutator_F_Qt_f12 ( World & world,
const CCFunction< double, 3 > & phi_i,
const CCFunction< double, 3 > & phi_j,
const CC_vecfunction & gs_singles,
const CC_vecfunction & ex_singles,
const Info & info,
const real_convolution_6d * Gscreen )
static

calculate [F,Qt] f12 |rhs>

From Eqs. (42) - (44) of Kottmann et al. JCTC 13, 5945 (2017) and eq. (30) of Kottmann et al. JCTC 13, 5956 (2017) [F,Qt] = [F1,Q1t]Q2t + Q1t [F2,Q2t] and [F1,Q1t] = - [F1,O1t] = - (F-e_k) |tk><k| = - (F-e_k) |tauk><k| = |Vk><k| commutator is applied to f12|titj>

Returns
the commutator [F,Qt] f12 |phi_i phi_j>

References madness::CCConvolutionOperatorPtr(), madness::CCFunction< T, NDIM >::function, madness::CC_vecfunction::get_vecfunction(), MADNESS_CHECK_THROW, madness::OT_F12, madness::outer(), and madness::POT_singles_.

Referenced by apply_Vreg().

◆ apply_exchange_commutator()

madness::real_function_6d madness::CCPotentials::apply_exchange_commutator ( const CCFunction< double, 3 > & x,
const CCFunction< double, 3 > & y,
const real_convolution_6d * Gscreen = NULL ) const

Apply Ue on a tensor product of two 3d functions: Ue(1,2) |x(1)y(2)> (will be either |ij> or |\tau_i\tau_j> or mixed forms) The Transformed electronic regularization potential (Kutzelnigg) is R_{12}^{-1} U_e R_{12} with R_{12} = R_1*R_2 It is represented as: R_{12}^{-1} U_e R_{12} = U_e + R^-1[Ue,R] where R^-1[Ue,R] = R^-1 [[T,f],R] (see: Regularizing the molecular potential in electronic structure calculations. II. Many-body methods, F.A.Bischoff) The double commutator can be evaluated as follows: R^-1[[T,f],R] = -Ue_{local}(1,2)*(Un_{local}(1) - Un_{local}(2))

Parameters
[in]xthe 3D function for particle 1
[in]ythe 3D function for particle 2
[in]Gscreenpointer to the BSH operator in order to screen, has to be in modified NS form, Gscreen->modified==true the f12K|xy> part will be screened with the BSH while the Kf12|xy> can not be screened with the BSH operator but maybe with the coulomb
Returns
R^-1U_eR|x,y> the transformed electronic smoothing potential applied on |x,y> :

References madness::CCTimer::info(), madness::CCFunction< T, NDIM >::name(), madness::Function< T, NDIM >::print_size(), madness::Function< T, NDIM >::reduce_rank(), madness::Function< T, NDIM >::set_thresh(), and madness::Function< T, NDIM >::truncate().

Referenced by apply_Vreg().

◆ apply_f12_coupling()

std::vector< CCPairFunction< double, 6 > > madness::CCPotentials::apply_f12_coupling ( World & world,
const CCFunction< double, 3 > & phi_i,
const CCFunction< double, 3 > & phi_j,
const Info & info,
const real_convolution_6d * Gscreen )
static

compute the coupled f12 contributions: f12 (\sum_k f_jk |ik> + f_ik |kj>)

References madness::copy(), madness::CCFunction< T, NDIM >::function, madness::CCFunction< T, NDIM >::i, MADNESS_CHECK_THROW, madness::OT_F12, and madness::transform().

Referenced by apply_Vreg().

◆ apply_gf()

madness::real_function_3d madness::CCPotentials::apply_gf ( World & world,
const real_function_3d & f,
const Info & info )
static

apply the operator gf = 1/(2\gamma)*(Coulomb - 4\pi*BSH_\gamma) works only if f = (1-exp(-\gamma*r12))/(2\gamma)

References madness::f, and madness::OT_FG12.

Referenced by make_xy_gf_ab().

◆ apply_KffK()

◆ apply_Kfxy()

madness::real_function_6d madness::CCPotentials::apply_Kfxy ( World & world,
const CCFunction< double, 3 > & x,
const CCFunction< double, 3 > & y,
const Info & info,
const CCParameters & parameters )
static

◆ apply_projector()

madness::vector_real_function_3d madness::CCPotentials::apply_projector ( const CC_vecfunction & f,
const CC_vecfunction & ket_ ) const

Apply a projector to a CC_vecfunction result: $ P(tau)f[i] = \sum_k tau[k]*<k|f[i]>   $ ket state of the projector can vary bra state are always MOs

References madness::copy(), madness::f, get_mo_bra(), madness::CC_vecfunction::get_vecfunction(), and MADNESS_ASSERT.

Referenced by test_singles_potential().

◆ apply_Q12t()

◆ apply_Qt() [1/2]

madness::vector_real_function_3d madness::CCPotentials::apply_Qt ( const CC_vecfunction & f,
const CC_vecfunction & ket_,
const double c = 1.0 ) const

Apply the Q projector to a CC_vecfunction result: $ 1-c*P(tau)f[i] = 1 - c*\sum_k tau[k]*<k|f[i]> $ ket state of the projector can vary bra state are always MOs the factor c is usually 1 or 1/2

References c, madness::f, get_mo_bra(), madness::CC_vecfunction::get_vecfunction(), and madness::sub().

Referenced by apply_Qt(), make_constant_part_cispd(), make_constant_part_cispd_Qt(), make_pair_ex(), make_pair_gs(), test_pair_consistency(), test_pairs(), and test_singles_potential().

◆ apply_Qt() [2/2]

madness::CCPairFunction< double, 6 > madness::CCPotentials::apply_Qt ( const CCPairFunction< double, 6 > & f,
const CC_vecfunction & t,
const size_t particle,
const double c = 1.0 ) const

Apply the Qt projector on a CCPairFunction works in principle like apply_Ot

References apply_Qt(), c, madness::f, and MADNESS_ASSERT.

◆ apply_reduced_F()

madness::real_function_6d madness::CCPotentials::apply_reduced_F ( World & world,
const CCFunction< double, 3 > & ti,
const CCFunction< double, 3 > & tj,
const Info & info,
const real_convolution_6d * Gscreen = NULL )
static

evaluates: $ (F(1)-ei)|ti> (x) |tj> + |ti> (x) (F(2)-ej)|tj> $ with the help of the singles potential singles equation is: (F-ei)|ti> = - V(ti) response singles equation: (F-ei-omega)|xi> = - V(xi) response: $ (F12-ei-ej-omega)|xitj> = (F1 - ei - omega)|xi> (x) |tj> + |xi> (x) (F2-ej)|tj> $ so in both cases the result will be: |V(ti),tj> + |ti,V(tj)>

Parameters
[in]ti,firstfunction in the ket, for MP2 it is the Orbital, for CC2 the relaxed Orbital t_i=\phi_i + \tau_i
[in]tj,secondfunction in the ket ...
[in]pointerto bsh operator (in order to screen)

compute the reduced Fock term, either with or without the omega term using Eqs (33) and (34) of Kottmann et al., JCTC 13, 5956 (2017) f12 (F12 - e_ij) |ti tj> f12 (F12 - e_ij - omega) |ti xj>

References madness::POT_singles_, and madness::swap_particles().

Referenced by apply_Vreg().

◆ apply_reduced_F1()

madness::real_function_6d madness::CCPotentials::apply_reduced_F1 ( const CCFunction< double, 3 > & ti,
const CCFunction< double, 3 > & tj,
const real_convolution_6d * Gscreen = NULL ) const

evaluates: $ (F(1)-ei)|ti> (x) |tj> + |ti> (x) (F(2)-ej)|tj> $ with the help of the singles potential singles equation is: (F-ei)|ti> = - V(ti) response singles equation: (F-ei-omega)|xi> = - V(xi) response: $ (F12-ei-ej-omega)|xitj> = (F1 - ei - omega)|xi> (x) |tj> + |xi> (x) (F2-ej)|tj> $ so in both cases the result will be: |V(ti),tj> + |ti,V(tj)>

Parameters
[in]ti,firstfunction in the ket, for MP2 it is the Orbital, for CC2 the relaxed Orbital t_i=\phi_i + \tau_i
[in]tj,secondfunction in the ket ...
[in]pointerto bsh operator (in order to screen)

References madness::CCFunction< T, NDIM >::i, madness::POT_singles_, swap_particles(), and madness::CCFunction< T, NDIM >::type.

Referenced by apply_Vreg().

◆ apply_s2b_operation()

madness::real_function_3d madness::CCPotentials::apply_s2b_operation ( World & world,
const CCFunction< double, 3 > & bra,
const CCPairFunction< double, 6 > & u,
const size_t particle,
const Info & info )
static

◆ apply_transformed_Ue()

madness::real_function_6d madness::CCPotentials::apply_transformed_Ue ( const CCFunction< double, 3 > & x,
const CCFunction< double, 3 > & y,
const real_convolution_6d * Gscreen = NULL ) const

Apply Ue on a tensor product of two 3d functions: Ue(1,2) |x(1)y(2)> (will be either |ij> or |\tau_i\tau_j> or mixed forms) The Transformed electronic regularization potential (Kutzelnigg) is R_{12}^{-1} U_e R_{12} with R_{12} = R_1*R_2 It is represented as: R_{12}^{-1} U_e R_{12} = U_e + R^-1[Ue,R] where R^-1[Ue,R] = R^-1 [[T,f],R] (see: Regularizing the molecular potential in electronic structure calculations. II. Many-body methods, F.A.Bischoff) The double commutator can be evaluated as follows: R^-1[[T,f],R] = -Ue_{local}(1,2)*(Un_{local}(1) - Un_{local}(2))

Parameters
[in]xthe 3D function for particle 1
[in]ythe 3D function for particle 2
[in]TheBSH operator to screen: Has to be in NS form, Gscreen->modified == true
Returns
R^-1U_eR|x,y> the transformed electronic smoothing potential applied on |x,y> :

References a, aa, axis, madness::copy(), diff(), madness::error(), madness::Function< T, NDIM >::fill_cuspy_tree(), madness::CCFunction< T, NDIM >::function, madness::CompositeFactory< T, NDIM, MDIM >::g12(), madness::FunctionDefaults< NDIM >::get_thresh(), madness::CCFunction< T, NDIM >::i, madness::CCTimer::info(), madness::inner(), madness::SeparatedConvolution< Q, NDIM >::modified(), madness::CCFunction< T, NDIM >::name(), madness::CompositeFactory< T, NDIM, MDIM >::particle1(), madness::CompositeFactory< T, NDIM, MDIM >::particle2(), print_size(), madness::scale(), madness::Function< T, NDIM >::set_thresh(), swap_particles(), madness::FunctionFactory< T, NDIM >::thresh(), madness::truncate(), and madness::CCFunction< T, NDIM >::type.

Referenced by apply_Vreg().

◆ apply_Ue()

◆ apply_Vreg() [1/2]

madness::real_function_6d madness::CCPotentials::apply_Vreg ( const CCFunction< double, 3 > & ti,
const CCFunction< double, 3 > & tj,
const real_convolution_6d * Gscreen = NULL ) const

Apply the Regularization potential $ V_{reg} = [ U_e - [K,f12] + f12(F12-eij) ]|titj> $

Parameters
[in]ti,firstfunction in the ket, for MP2 it is the Orbital, for CC2 the relaxed Orbital t_i=\phi_i + \tau_i
[in]tj,secondfunction in the ket ...
[in]pointerto bsh operator (in order to screen)
[out]theregularization potential (unprojected), see equation above

References apply_exchange_commutator(), apply_reduced_F1(), apply_transformed_Ue(), madness::CCTimer::info(), madness::CCFunction< T, NDIM >::name(), madness::Function< T, NDIM >::norm2(), madness::Function< T, NDIM >::print_size(), and madness::CCTimer::stop().

Referenced by make_constant_part_cispd(), make_constant_part_cispd_Qt(), and make_constant_part_macrotask().

◆ apply_Vreg() [2/2]

std::vector< CCPairFunction< double, 6 > > madness::CCPotentials::apply_Vreg ( World & world,
const CCFunction< double, 3 > & ti,
const CCFunction< double, 3 > & tj,
const CC_vecfunction & gs_singles,
const CC_vecfunction & ex_singles,
const Info & info,
LowRankFunction< double, 6 > exchange_op,
const std::vector< std::string > & argument,
const double bsh_eps )
static

Apply the Regularization potential.

Apply the Regularization potential $ V_{reg} = [ U_e - [K,f12] + f12(F12-eij) + [F,Qt] ]|titj> $

Parameters
[in]ti,firstfunction in the ket, for MP2 it is the Orbital, for CC2 the relaxed Orbital t_i=\phi_i + \tau_i
[in]tj,secondfunction in the ket ...
exchange_op
[in]pointerto bsh operator (in order to screen)
[out]theregularization potential (unprojected), see equation above

four terms can be calculated $ V_{reg} = [ U_e - [K,f12] + f12(F12-eij) + [F,Qt] ]|titj> $

  • Ue = [T,f12]
  • [K,f12]
  • [F12,Q12t] f12 or [F12,dQ12t] f12
  • f12 (F - e_ij - omega) or f12 (F - e_ij) the last terms are computed using the converged singles potential, i.e. we assume that the following equation holds (see Kottmann et al., JCTC 13, 5945 (2017) eqs (30), (31), (44) (see Kottmann et al., JCTC 13, 5956 (2017) eqs (17), (19), (32) CC2: (F - e_i ) |t_i t_j> = | Vtau > LRCC2: (F - e_i - omega) |x_i> = | Vx >
    Parameters
    [in]tifirst function in the ket, for MP2 it is the Orbital, for CC2 the relaxed Orbital t_i=\phi_i + \tau_i
    [in]tjsecond function in the ket ...
    [in]gs_singlesthe converged ground state singles: with (F - e_i ) |t_i t_j> = | Vtau >
    [in]ex_singlesthe converged excited state singles: with (F - e_i - omega) |x_i> = | Vx >
    [in]infoInfo structure holding the applied singles potentials Vtau and Vx and reference orbitals
    exchange_op
    [out]theregularization potential (unprojected), see equation above

References a, apply_commutator_F_dQt_f12(), apply_commutator_F_Qt_f12(), apply_f12_coupling(), apply_KffK(), apply_reduced_F(), apply_Ue(), bsh_eps, madness::BSHOperator(), madness::SeparatedConvolution< Q, NDIM >::modified(), madness::CCFunction< T, NDIM >::name(), madness::print(), madness::World::rank(), madness::timer::tag(), and V().

◆ compute_cc2_correlation_energy()

double madness::CCPotentials::compute_cc2_correlation_energy ( World & world,
const CC_vecfunction & singles,
const Pairs< CCPair > & doubles,
const Info & info,
const std::string msg = "" )
static

Compute CC2 correlation energy

Parameters
[in]ThePair_function
[out]

sum_{ij} 2*<ij|g|u> - <ji|g|u> + 2*<ij|g|\tau_i\tau_j> - <ji|g|\tau_i\tau_j> , where i and j are determined by u (see CC_Pair class) since we do not compute all pairs (symmetry reasons) the off diagonal pair energies are conted twice the cc2 pair functions are dependent on the doubles (see CC_Pair structure, and make_pair function) so make shure they are updated

Parameters
world
info

References madness::Pairs< T >::pairs2vector(), madness::World::rank(), and madness::PairVectorMap::triangular_map().

Referenced by madness::CC2::solve_cc2().

◆ compute_cc2_excitation_energy()

◆ compute_cis_expectation_value()

double madness::CCPotentials::compute_cis_expectation_value ( World & world,
const CC_vecfunction & x,
const vector_real_function_3d & V,
const bool print,
const Info & info )
static

◆ compute_cispd_energy()

double madness::CCPotentials::compute_cispd_energy ( const CC_vecfunction & x,
const Pairs< CCPair > mp2,
const Pairs< CCPair > cispd ) const

◆ compute_excited_pair_energy()

double madness::CCPotentials::compute_excited_pair_energy ( World & world,
const CCPair & d,
const CC_vecfunction & x,
const Info & info )
static

Something like a pair energy for CIS(D)/LRCC2 to estimate energy convergence calculates the response part of s2b and s2c which are independent of the mp2 amplitudes

References madness::CCConvolutionOperatorPtr(), d, madness::FunctionDefaults< NDIM >::k, madness::CC_vecfunction::functions, madness::CC_vecfunction::get_vecfunction(), MADNESS_CHECK_THROW, make_xy_op_u(), make_xy_u(), madness::OT_G12, madness::World::rank(), madness::RESPONSE, madness::CC_vecfunction::size(), and madness::CC_vecfunction::type.

Referenced by iterate_pair_macrotask().

◆ compute_kinetic_energy()

double madness::CCPotentials::compute_kinetic_energy ( World & world,
const vector_real_function_3d & xbra,
const vector_real_function_3d & xket )
static

◆ compute_pair_correlation_energy()

double madness::CCPotentials::compute_pair_correlation_energy ( World & world,
const CCPair & u,
const CC_vecfunction & singles,
const Info & info )
static

Compute pair correlation energies of MP2 or CC2 Ground State.

Parameters
[in]uthe Pair_function
[in]singlesthe Singles (for MP2 give empty function) for the energy contribution over disconnected doubles
[out]2*<ij|g|u>- <ji|g|u> , where i and j are determined by u (see CC_Pair class)

References madness::CCConvolutionOperatorPtr(), madness::CT_CC2, madness::CT_MP2, madness::CCFunction< T, NDIM >::function, madness::CC_vecfunction::functions, madness::CC_vecfunction::get_vecfunction(), madness::GROUND_STATE, madness::CCFunction< T, NDIM >::inner(), madness::inner(), MADNESS_ASSERT, madness::OT_G12, madness::PARTICLE, madness::World::rank(), madness::CC_vecfunction::type, and u().

Referenced by iterate_pair_macrotask(), make_constant_part_macrotask(), and madness::MacroTaskComputeCorrelationEnergy::operator()().

◆ fock_residue_6d()

◆ fock_residue_6d_macrotask()

◆ get_active_mo_bra()

vector_real_function_3d madness::CCPotentials::get_active_mo_bra ( ) const
inline

returns a vector of all active mos multiplied with the squared nuclear currelation factor: mo_bra = R^2*mo_ket

References function().

◆ get_active_mo_ket()

vector_real_function_3d madness::CCPotentials::get_active_mo_ket ( ) const
inline

returns a vector of all active mos without nuclear correlation factor (nemos)

References function().

Referenced by make_t_intermediate(), test_pairs(), and test_singles_potential().

◆ get_epsilon() [1/2]

double madness::CCPotentials::get_epsilon ( const size_t i,
const size_t j ) const
inline

◆ get_epsilon() [2/2]

double madness::CCPotentials::get_epsilon ( const size_t i,
const size_t j,
const Info & info )
inlinestatic

returns epsilon_i + epsilon_j (needed for bsh operator of pairs)

◆ get_mo_bra()

vector_real_function_3d madness::CCPotentials::get_mo_bra ( const CC_vecfunction & ket) const
inline

get the corresponding mo bra vectors to a ket vector

References madness::CC_vecfunction::functions.

Referenced by apply_projector(), and apply_Qt().

◆ get_orbital_energies()

std::vector< double > madness::CCPotentials::get_orbital_energies ( ) const
inline

returns a vector of all orbital energies

Referenced by test_pairs(), and test_singles_potential().

◆ get_pair_function()

std::vector< CCPairFunction< double, 6 > > madness::CCPotentials::get_pair_function ( const Pairs< CCPair > & pairs,
const size_t i,
const size_t j )
static

get the correct pair function as vector of CCPairFunction functions

Parameters
[in]Thepair functions
[out]Thedemanded pair function as vector of CCPairFunction functions (includes regularization tails)

References swap_particles().

Referenced by compute_cispd_energy().

◆ init_orbital_energies()

std::vector< double > madness::CCPotentials::init_orbital_energies ( const Nemo & nemo) const
private

Transfers Eigenvalues of HF MOs from Nemo (Tensor Format) to std::vector<double> format.

References madness::nemo.

Referenced by reset_nemo().

◆ iterate_pair_macrotask()

◆ load_function()

template<typename T, size_t NDIM>
bool madness::CCPotentials::load_function ( Function< T, NDIM > & f,
const std::string name,
bool do_print ) const
inline

Function to load a function from disc

Parameters
[in]fthe function which will be loaded
[in]nameof the file in which the function was stored
do_print
Returns
true or false depending on if the data was found on disc

References madness::f, madness::FunctionDefaults< NDIM >::get_thresh(), madness::name(), madness::print(), madness::reconstructed, and madness::save().

◆ make_6D_pair()

◆ make_active_t_intermediate()

CC_vecfunction madness::CCPotentials::make_active_t_intermediate ( const CC_vecfunction & tau,
const Info & info )
static

makes the t intermediates

ti = mo_ket(i) + tau(i) skip frozen orbitals

ti = mo_ket(i) + tau(i) skip frozen core orbitals

References madness::CC_vecfunction::functions, madness::HOLE, madness::CC_vecfunction::insert(), madness::MIXED, madness::CC_vecfunction::size(), and madness::CC_vecfunction::type.

Referenced by apply_commutator_F_dQt_f12().

◆ make_bra() [1/2]

vector_real_function_3d madness::CCPotentials::make_bra ( const CC_vecfunction & t) const
inline

make bra element: R^2|t>

References madness::CC_vecfunction::get_vecfunction(), and make_bra().

Referenced by compute_cispd_energy(), and make_bra().

◆ make_bra() [2/2]

vector_real_function_3d madness::CCPotentials::make_bra ( const vector_real_function_3d & t) const
inline

◆ make_constant_part_cispd()

◆ make_constant_part_cispd_Qt()

◆ make_constant_part_macrotask()

madness::real_function_6d madness::CCPotentials::make_constant_part_macrotask ( World & world,
const CCPair & pair,
const CC_vecfunction & gs_singles,
const CC_vecfunction & ex_singles,
const LowRankFunction< double, 6 > & exchange_op,
const Info & info )
static

the constant part is the contribution to the doubles that are independent of the doubles

Compute the constant part of MP2, CC2 or LR-CC2

depending on pair.calc_type different terms are included in the constant part.

Parameters
[in]pairthe (empty) pair function, determines the terms in the constant part, contains some bookkeeping information (bsh_eps, i, j)
[in]gs_singlesthe ground-state singles for CC2 (used for the T1-transformed SO projector), may be left empty for MP2
[in]ex_singlesthe excited-state singles for CC2 (used for the T1-transformed SO projector), may be left empty for MP2 and GS-CC2
[in]infothe Info object, containing the some basic quantities (MOs, parameters, etc)
Returns
the constant part of the MP2, CC2 or LR-CC2: G(Q12(g~|titj>))

CC-equations from Kottmann et al., JCTC 13, 5956 (2017) MP2: cp = G Q g~ |ij> g~ = Ue - KffK GS-CC2: eqs. (6,7) cp = G Qt g~ |t_i t_j> g~ = Ue - KffK - Fock_commutator - reduced_Fock LRCC2: eqs. (24-29) cp = G d(Qt g~ d|t_i t_j>) = G (Qt g~ d|t_i t_j> + Qt dg~ |t_i t_j> + dQt g~ |t_i t_j>)

References apply_Vreg(), madness::CCPair::bsh_eps, madness::BSHOperator(), cc, compute_pair_correlation_energy(), madness::copy(), madness::CoulombOperatorPtr(), madness::CT_CC2, madness::CT_LRCC2, madness::CT_MP2, madness::CCPair::ctype, madness::FunctionFactory< T, NDIM >::empty(), madness::timer::end(), energy, madness::ExchangeCommutator::fk_provider(), G, madness::FunctionDefaults< NDIM >::get_thresh(), madness::CC_vecfunction::get_vecfunction(), madness::HOLE, madness::CCPair::i, madness::CCPair::j, madness::ExchangeCommutator::kf_provider(), lo, MADNESS_CHECK_THROW, make_full_t_intermediate(), madness::MemoryMeasurer::measure_and_print(), madness::MIXED, madness::name(), madness::outer(), p(), madness::pair_energy_weights< double, 6 >(), madness::print(), madness::print_header3(), madness::print_pair_energy_table_RI(), madness::Function< T, NDIM >::print_size(), Q(), madness::Function< T, NDIM >::reduce_rank(), madness::MemoryMeasurer::release_free_memory(), madness::Projector< T, NDIM >::set_spaces(), madness::QProjector< T, NDIM >::set_spaces(), madness::StrongOrthogonalityProjector< T, NDIM >::set_spaces(), madness::Function< T, NDIM >::set_thresh(), madness::FunctionDefaults< NDIM >::set_thresh(), madness::Function< T, NDIM >::truncate(), madness::CCPair::update_u(), and V().

Referenced by madness::MacroTaskConstantPart::operator()().

◆ make_full_t_intermediate() [1/2]

CC_vecfunction madness::CCPotentials::make_full_t_intermediate ( const CC_vecfunction & tau) const

◆ make_full_t_intermediate() [2/2]

CC_vecfunction madness::CCPotentials::make_full_t_intermediate ( const CC_vecfunction & tau,
const Info & info )
static

makes the t intermediates

makes the t intermediates t_i = mo_ket_(i) + tau(i) if the core is frozen the core ti will just be mo_ket_

ti = mo_ket(i) + tau(i) if the core is frozen the core ti will just be mo_ket_

References function(), madness::HOLE, madness::CC_vecfunction::insert(), madness::MIXED, madness::CC_vecfunction::size(), and madness::CC_vecfunction::type.

◆ make_mo_bra()

madness::CC_vecfunction madness::CCPotentials::make_mo_bra ( const Nemo & nemo) const
private

Helper function to initialize the const mo_bra and ket elements adn orbital energies.

References madness::HOLE, mo_bra(), mo_bra(), madness::mul(), madness::nemo, madness::reconstruct(), madness::set_thresh(), and madness::truncate().

Referenced by reset_nemo().

◆ make_mo_ket()

madness::CC_vecfunction madness::CCPotentials::make_mo_ket ( const Nemo & nemo) const
private

Helper function to initialize the const mo_bra and ket elements.

References madness::HOLE, mo_ket(), mo_ket(), madness::nemo, madness::reconstruct(), madness::set_thresh(), and madness::truncate().

Referenced by reset_nemo().

◆ make_pair_cc2()

CCPair madness::CCPotentials::make_pair_cc2 ( World & world,
const real_function_6d & u,
const CC_vecfunction & gs_singles,
const size_t i,
const size_t j,
const Info & info,
const bool compute_Q12_f12_ij )
static

◆ make_pair_ex()

madness::CCPair madness::CCPotentials::make_pair_ex ( const real_function_6d & u,
const CC_vecfunction & tau,
const CC_vecfunction & x,
const size_t i,
const size_t j,
const CalcType ctype ) const

creates pair functions for Excited states the full pair-functions is: pair = u + Qt12f12|xitj> + Qt12f12|tixj> - OxQtf12|titj> - QtOxf12|titj> the old Ansatz (not QtAnsatz) was: pair = u + Q12f12|xitj> + Q12f12|tixj> this is decomposed in different types of CCPairFunction the CC_Pair2 class holds an vector of CCPairFunction we use: Qt12 = 1 - Ot1 - Ot2 + Ot12 = 1 - Ot1(1-0.5*Ot2) - Ot2(1-0.5O*t1) functions[0] = u , the pure 6D part functions[1] = f12|xitj> functions[2] = f12|tixj> functions[3] = -Ot1(1-0.5*Ot2)f12|xitj> functions[4] = -(1-0.5*Ot1)Ot2f12|xitj> functions[5] = -Ot1(1-0.5*Ot2)f12|tixj> functions[6] = -(1-0.5*Ot1)Ot2f12|tixj> functions[7] = -OxQtf12|titj> only for QtAnsatz functions[8] = -QtOxf12|titj> only for QtAnsatz

References apply_Q12t(), apply_Qt(), bsh_eps, madness::CCPair::bsh_eps, madness::copy(), madness::CT_ADC2, madness::CT_CISPD, madness::CT_LRCC2, madness::EXCITED_STATE, get_epsilon(), madness::CC_vecfunction::get_vecfunction(), madness::HOLE, madness::CCPairFunction< T, NDIM >::invert_sign(), MADNESS_ASSERT, make_full_t_intermediate(), make_t_intermediate(), madness::CC_vecfunction::omega, madness::PARTICLE, residual(), madness::RESPONSE, madness::CC_vecfunction::size(), madness::CC_vecfunction::type, and u().

Referenced by test_pairs(), and test_singles_potential().

◆ make_pair_gs()

madness::CCPair madness::CCPotentials::make_pair_gs ( const real_function_6d & u,
const CC_vecfunction & tau,
const size_t i,
const size_t j ) const

creates pair functions for ground states the full pair-functions is: pair = u + Qt12f12|titj> this is decomposed in different types of CCPairFunction the CC_Pair2 class holds an vector of CCPairFunction we use: Qt12 = 1 - Ot1 - Ot2 + Ot12 = 1 - Ot1(1-0.5*Ot2) - Ot2(1-0.5O*t1) depending on parameters.QtAnsatz we use the t functions also in the projector functions[0] = u , the pure 6D part functions[1] = f12|titj> functions[2] = -Ot1(1-0.5*Ot2)f12|titj> functions[3] = -(1-0.5*Ot1)Ot2f12|titj>

References apply_Q12t(), apply_Qt(), bsh_eps, madness::CCPair::bsh_eps, madness::CT_CC2, madness::CT_MP2, get_epsilon(), madness::GROUND_STATE, madness::HOLE, madness::CCTimer::info(), madness::CCPairFunction< T, NDIM >::invert_sign(), MADNESS_ASSERT, MADNESS_EXCEPTION, make_full_t_intermediate(), make_t_intermediate(), madness::MIXED, madness::PARTICLE, residual(), madness::Function< T, NDIM >::truncate(), madness::CC_vecfunction::type, and u().

Referenced by test_pairs(), and test_singles_potential().

◆ make_pair_lrcc2()

◆ make_pair_mp2()

CCPair madness::CCPotentials::make_pair_mp2 ( World & world,
const real_function_6d & u,
const size_t i,
const size_t j,
const Info & info,
bool compute_Q12_f12_ij )
static

◆ make_t_intermediate() [1/2]

CC_vecfunction madness::CCPotentials::make_t_intermediate ( const CC_vecfunction & tau,
const CCParameters & parameters ) const

makes the t intermediates t_i = mo_ket_(i) + factor*tau(i) if factor!=1 then we can not use intermediates and set the type to UNDEFINED

References madness::CCParameters::freeze(), function(), madness::CC_vecfunction::functions, get_active_mo_ket(), madness::HOLE, madness::CC_vecfunction::insert(), madness::MIXED, madness::CC_vecfunction::size(), and madness::CC_vecfunction::type.

Referenced by make_pair_ex(), and make_pair_gs().

◆ make_t_intermediate() [2/2]

CCFunction< double, 3 > madness::CCPotentials::make_t_intermediate ( const CCFunction< double, 3 > & tau) const

◆ make_xy_ff_ab()

double madness::CCPotentials::make_xy_ff_ab ( const CCFunction< double, 3 > & x,
const CCFunction< double, 3 > & y,
const CCFunction< double, 3 > & a,
const CCFunction< double, 3 > & b ) const
inline

References a, b, and madness::error().

◆ make_xy_gf_ab()

double madness::CCPotentials::make_xy_gf_ab ( const CCFunction< double, 3 > & x,
const CCFunction< double, 3 > & y,
const CCFunction< double, 3 > & a,
const CCFunction< double, 3 > & b ) const

Helper Function which performs the operation $ <xy|g12f12|ab> $

Parameters
[in]functionx, if nuclear correlation is used make sure this is the correct bra function
[in]functiony, if nuclear correlation is used make sure this is the correct bra function
[in]functiona,
[in]functionb,

References a, apply_gf(), b, madness::CCFunction< T, NDIM >::function, and madness::truncate().

◆ make_xy_op_ab()

double madness::CCPotentials::make_xy_op_ab ( const CCFunction< double, 3 > & x,
const CCFunction< double, 3 > & y,
const CCConvolutionOperator< double, 3 > & op,
const CCFunction< double, 3 > & a,
const CCFunction< double, 3 > & b ) const

Helper Function which returns

Returns
<xy|op|ab>
Parameters
[in]functionx, if nuclear correlation is used make sure this is the correct bra function
[in]functiony, if nuclear correlation is used make sure this is the correct bra function
[in]functiona,
[in]functionb,

References a, b, madness::CCFunction< T, NDIM >::function, madness::HOLE, op(), and madness::CCFunction< T, NDIM >::type.

◆ make_xy_op_u() [1/2]

double madness::CCPotentials::make_xy_op_u ( const CCFunction< double, 3 > & x,
const CCFunction< double, 3 > & y,
const CCConvolutionOperator< double, 3 > & op,
const CCPairFunction< double, 6 > & u )
static

Functions which operate with the CCPairFunction structure

Parameters
[in]functionx, if nuclear correlation is used make sure this is the correct bra function
[in]functiony, if nuclear correlation is used make sure this is the correct bra function
[in]CCPairFunctionu,

References madness::CCFunction< T, NDIM >::f(), madness::inner(), op(), and u().

◆ make_xy_op_u() [2/2]

double madness::CCPotentials::make_xy_op_u ( const CCFunction< double, 3 > & x,
const CCFunction< double, 3 > & y,
const CCConvolutionOperator< double, 3 > & op,
const std::vector< CCPairFunction< double, 6 > > & u )
static

returns <xy|op|u> loops over every entry in the vector and accumulates results helper function for CIS(D) energy

References make_xy_op_u(), op(), and u().

Referenced by compute_cispd_energy(), compute_excited_pair_energy(), make_xy_op_u(), and test_compare_pairs().

◆ make_xy_u()

double madness::CCPotentials::make_xy_u ( const CCFunction< double, 3 > & x,
const CCFunction< double, 3 > & y,
const std::vector< CCPairFunction< double, 6 > > & u )
static

returns <xy|u> for a vector of CCPairFunction the result is accumulated for every vercotr helper functions for CIS(D) energy

References u().

Referenced by compute_cispd_energy(), and compute_excited_pair_energy().

◆ mo_bra() [1/2]

CC_vecfunction madness::CCPotentials::mo_bra ( ) const
inline

Referenced by make_mo_bra(), and update_info().

◆ mo_bra() [2/2]

CCFunction< double, 3 > madness::CCPotentials::mo_bra ( const size_t & i) const
inline

returns a specific mo multiplied with the squared nuclear correlation factor

Referenced by fock_residue_6d_macrotask(), and make_mo_bra().

◆ mo_ket() [1/2]

CC_vecfunction madness::CCPotentials::mo_ket ( ) const
inline

Referenced by make_mo_ket(), and update_info().

◆ mo_ket() [2/2]

CCFunction< double, 3 > madness::CCPotentials::mo_ket ( const size_t & i) const
inline

returns a specific mo

Referenced by fock_residue_6d_macrotask(), and make_mo_ket().

◆ overlap() [1/2]

double madness::CCPotentials::overlap ( const CCPair & x) const

Computes the squared norm of the pair function <x|x> including all regularization tails means: if x = u + f12|mn> + |ab> --> <x|x> = <u|u> + <u|f12|mn> + <u|ab> + ....

References madness::CCPair::functions, madness::CCPair::name(), and overlap().

◆ overlap() [2/2]

double madness::CCPotentials::overlap ( const CCPairFunction< double, 6 > & f1,
const CCPairFunction< double, 6 > & f2 ) const
inline

Calculate the Overlap between two CCPairFunction <f1|f2>

Parameters
[in]6Dfunction 1
[in]6Dfunction 2

References f1, f2, and madness::inner().

Referenced by overlap(), test(), test_compare_pairs(), and test_pair_consistency().

◆ plot() [1/2]

void madness::CCPotentials::plot ( const real_function_3d & f,
const std::string & msg,
const bool doprint = true ) const

Plotting (convenience).

References madness::f, madness::CCTimer::info(), and madness::plot_plane().

◆ plot() [2/2]

void madness::CCPotentials::plot ( const vector_real_function_3d & f,
const std::string & msg ) const

Plotting (convenience).

References madness::f, madness::FunctionDefaults< NDIM >::k, madness::CCTimer::info(), and plot().

Referenced by plot().

◆ print_3d_references()

void madness::CCPotentials::print_3d_references ( World & world,
const std::vector< CCPair > & pair_vec,
const Info & info )
static

quick 3D-only Ue / GUe / GQUe references for all pairs (no 6D work)

reuses CorrelationFactor::compute_3d_references; meant to be called right before the constant-part macrotask to compare the 3D references cheaply.

constructs a CorrelationFactor like the constant-part macrotask does and calls CorrelationFactor::compute_3d_references for each pair, so the 3D references can be compared cheaply before the expensive constant part runs.

References madness::print(), madness::print_header3(), and madness::World::rank().

◆ print_size()

template<size_t NDIM>
void madness::CCPotentials::print_size ( const Function< double, NDIM > & f,
const std::string & msg,
const bool print = true ) const
inline

print size of a function

References madness::f, and madness::print().

Referenced by apply_transformed_Ue(), make_constant_part_cispd(), and make_constant_part_cispd_Qt().

◆ reset_nemo()

void madness::CCPotentials::reset_nemo ( const std::shared_ptr< const Nemo > nemo)
inline

◆ swap_particles() [1/2]

real_function_6d madness::CCPotentials::swap_particles ( const real_function_6d & f) const
inline

◆ swap_particles() [2/2]

std::vector< CCPairFunction< double, 6 > > madness::CCPotentials::swap_particles ( const std::vector< CCPairFunction< double, 6 > > & f)
inlinestatic

swap the particles of the CCPairFunction and return a new vector of swapped functions

References madness::f.

◆ test()

◆ test_compare_pairs()

◆ test_pair_consistency()

void madness::CCPotentials::test_pair_consistency ( const CCPairFunction< double, 6 > & u,
const size_t i,
const size_t j,
const CC_vecfunction & x ) const

forms the regularized functions from Q and Qt Ansatz for CIS(D) where tau=0 and t=mo so that Qt=Q

References apply_Qt(), madness::CT_CISPD, madness::EXCITED_STATE, madness::CCPairFunction< T, NDIM >::invert_sign(), overlap(), and u().

◆ test_pairs()

◆ test_singles_potential()

◆ update_info()

Info madness::CCPotentials::update_info ( const CCParameters & parameters,
const std::shared_ptr< const Nemo > nemo ) const
inline

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