MADNESS 0.10.1
Public Types | Public Member Functions | Static Public Member Functions | Public Attributes | Static Public Attributes | Private Member Functions | Static Private Member Functions | Friends | List of all members
madness::CCPairFunction< T, NDIM > Class Template Reference

a 6D function, either in full or low rank form, possibly including an 2-particle function More...

#include <ccpairfunction.h>

Inheritance diagram for madness::CCPairFunction< T, NDIM >:
Inheritance graph
[legend]
Collaboration diagram for madness::CCPairFunction< T, NDIM >:
Collaboration graph
[legend]

Public Types

using pureT = Function< T, NDIM >
 

Public Member Functions

 CCPairFunction ()=default
 empty ctor
 
 CCPairFunction (const CCPairFunction &other)=default
 copy ctor – shallow
 
 CCPairFunction (const Function< T, LDIM > &f1, const Function< T, LDIM > &f2)
 takes a deep copy of the argument functions
 
 CCPairFunction (const Function< T, NDIM > &ket)
 takes a shallow copy of the argument function
 
 CCPairFunction (const std::pair< std::vector< Function< T, LDIM > >, std::vector< Function< T, LDIM > > > &f)
 takes a deep copy of the argument functions
 
 CCPairFunction (const std::shared_ptr< CCConvolutionOperator< T, LDIM > > op_, const CCFunction< T, LDIM > &f1, const CCFunction< T, LDIM > &f2)
 takes a deep copy of the argument functions
 
 CCPairFunction (const std::shared_ptr< CCConvolutionOperator< T, LDIM > > op_, const Function< T, LDIM > &f1, const Function< T, LDIM > &f2)
 takes a deep copy of the argument functions
 
 CCPairFunction (const std::shared_ptr< CCConvolutionOperator< T, LDIM > > op_, const Function< T, NDIM > &ket)
 takes a shallow copy of the argument function
 
 CCPairFunction (const std::shared_ptr< CCConvolutionOperator< T, LDIM > > op_, const std::vector< Function< T, LDIM > > &f1, const std::vector< Function< T, LDIM > > &f2)
 takes a deep copy of the argument functions
 
 CCPairFunction (const std::vector< Function< T, LDIM > > &f1, const std::vector< Function< T, LDIM > > &f2)
 takes a deep copy of the argument functions
 
const std::pair< std::vector< Function< T, LDIM > >, std::vector< Function< T, LDIM > > > assign_particles (const size_t particle) const
 small helper function that gives back (a,b) or (b,a) depending on the value of particle
 
void convert_to_pure_no_op_inplace ()
 convert this into a pure hi-dim function
 
TwoBodyFunctionSeparatedComponent< T, NDIM > & decomposed () const
 
Function< T, LDIMdirac_convolution (const CCFunction< T, LDIM > &x, const CCConvolutionOperator< T, LDIM > &op, const size_t particle) const
 result is: <x|op12|f>_particle
 
Function< T, LDIMdirac_convolution_decomposed (const CCFunction< T, LDIM > &x, const CCConvolutionOperator< T, LDIM > &op, const size_t particle) const
 
std::vector< Function< T, LDIM > > get_a () const
 
std::vector< Function< T, LDIM > > get_b () const
 
Function< T, NDIM > & get_function ()
 
Function< T, NDIM > & get_function () const
 
const CCConvolutionOperator< T, LDIM > & get_operator () const
 
const std::shared_ptr< CCConvolutionOperator< T, LDIM > > get_operator_ptr () const
 
std::vector< Function< T, LDIM > > get_vector (const int i) const
 
bool has_operator () const
 
void info () const
 
double inner_internal (const CCPairFunction &other, const Function< T, LDIM > &R2) const
 compute the inner product of this and other
 
CCPairFunction invert_sign ()
 
bool is_assigned () const
 
bool is_convertible_to_pure_no_op () const
 can this be converted to a pure representation (depends on the operator, if present)
 
bool is_decomposed () const
 
bool is_decomposed_no_op () const
 
bool is_op_decomposed () const
 
bool is_op_pure () const
 
bool is_pure () const
 
bool is_pure_no_op () const
 
double make_xy_u (const CCFunction< T, LDIM > &xx, const CCFunction< T, LDIM > &yy) const
 
CCPairFunction< T, NDIM > & multiply_with_op_inplace (const std::shared_ptr< CCConvolutionOperator< T, LDIM > > op)
 multiplication with a 2-particle function
 
std::string name (const bool transpose=false) const
 
Tensor< T >::scalar_type norm2 () const
 
CCPairFunctionoperator() (const CCPairFunction &other)
 shallow assignment operator
 
CCPairFunction operator* (const double fac) const
 scalar multiplication: f*fac
 
CCPairFunction operator* (const std::shared_ptr< CCConvolutionOperator< T, LDIM > > op)
 multiplication with a 2-particle function
 
CCPairFunctionoperator*= (const double fac)
 
CCPairFunction partial_inner (const CCPairFunction &other, const std::array< int, LDIM > &v1, const std::array< int, LDIM > &v2) const
 
Function< T, LDIMpartial_inner (const Function< T, LDIM > &f, const std::array< int, LDIM > &v1, const std::array< int, LDIM > &v2) const
 
void print_size (const std::string name1="") const
 print the size of the functions
 
Function< T, LDIMproject_out (const CCFunction< T, LDIM > &f, const size_t particle) const
 
Function< T, LDIMproject_out_decomposed (const Function< T, LDIM > &f, const size_t particle) const
 
Function< T, LDIMproject_out_op_decomposed (const CCFunction< T, LDIM > &f, const size_t particle) const
 
TwoBodyFunctionPureComponent< T, NDIM > & pure () const
 
void reset_operator (const std::shared_ptr< CCConvolutionOperator< T, LDIM > > op)
 
CCPairFunction swap_particles () const
 
CCPairFunction to_pure () const
 out-of-place conversion to pure function
 
Worldworld () const
 

Static Public Member Functions

static std::vector< CCPairFunction< T, NDIM > > apply (const ProjectorBase &P, const std::vector< CCPairFunction< T, NDIM > > &argument)
 
static std::vector< CCPairFunction< T, NDIM > > apply (const SeparatedConvolution< T, NDIM > &G, const CCPairFunction< T, NDIM > &argument)
 
static std::vector< CCPairFunction< T, NDIM > > apply (const SeparatedConvolution< T, NDIM > &G, const std::vector< CCPairFunction< T, NDIM > > &argument)
 
static bool is_collected (const std::vector< CCPairFunction< T, NDIM > > &other)
 

Public Attributes

std::shared_ptr< TwoBodyFunctionComponentBasecomponent
 the 3 types of 6D-function that occur in the CC potential which coupled doubles to singles
 

Static Public Attributes

static constexpr std::size_t LDIM =NDIM/2
 

Private Member Functions

std::vector< CCPairFunctionconsolidate (const std::vector< CCPairFunction > &other, const std::vector< std::string > &options, const std::vector< Vector< double, LDIM > > &centers) const
 

Static Private Member Functions

static std::vector< CCPairFunctioncollect_same_types (const std::vector< CCPairFunction > &other)
 collect all terms with of similiar type: pure, op_pure, decomposed, op_decomposed
 
static std::vector< CCPairFunctiondec_to_pure (const std::vector< CCPairFunction > &other)
 turn decomposed functions without operator into pure functions without operators
 
static std::vector< CCPairFunctionop_dec_to_dec (const std::vector< CCPairFunction > &other, const std::vector< Vector< double, LDIM > > &centers)
 turn decomposed functions with operator into decomposed functions using LowRankFunction
 
static std::vector< CCPairFunctionop_dec_to_pure (const std::vector< CCPairFunction > &other)
 turn decomposed functions with operator into pure functions without operators
 
static std::vector< CCPairFunctionop_pure_to_pure (const std::vector< CCPairFunction > &other)
 turn pure functions with operator into pure functions without operators
 
static std::vector< CCPairFunctionremove_linearly_dependent_terms (const std::vector< CCPairFunction > &other, double thresh=-1.0)
 remove linear dependent terms in the low-rank parts
 

Friends

std::vector< CCPairFunctionconsolidate (const std::vector< CCPairFunction > &other, const std::vector< std::string > options=std::vector< std::string >(), const std::vector< Vector< double, LDIM > > centers=std::vector< Vector< double, LDIM > >())
 collect the terms into a compact format
 
CCPairFunction copy (const CCPairFunction &other)
 deep copy
 
hashT hash_value (const CCPairFunction &f)
 
double inner (const CCPairFunction &a, const CCPairFunction &b)
 
double inner (const CCPairFunction &a, const CCPairFunction &b, const Function< T, LDIM > &R2)
 
double inner (const std::vector< CCPairFunction > &va, const std::vector< CCPairFunction > &vb, const Function< T, LDIM > R2=Function< T, LDIM >())
 
CCPairFunction< T, NDIMmultiply (const CCPairFunction< T, NDIM > &other, const Function< T, LDIM > &f, const std::array< int, LDIM > &v1)
 multiply CCPairFunction with a 3D function of one of the two particles
 
std::vector< CCPairFunctionmultiply (const std::vector< CCPairFunction > &other, const Function< T, LDIM > f, const std::array< int, LDIM > &v1)
 
CCPairFunction operator* (const double fac, const CCPairFunction &f)
 scalar multiplication: fac*f
 
CCPairFunction operator* (const std::shared_ptr< CCConvolutionOperator< T, LDIM > > op, const CCPairFunction &f)
 multiplication with a 2-particle function
 
std::vector< CCPairFunctionoperator* (const std::shared_ptr< CCConvolutionOperator< T, LDIM > > op, const std::vector< CCPairFunction > &f)
 multiplication with a 2-particle function
 
std::vector< CCPairFunctionswap_particles (const std::vector< CCPairFunction > &argument)
 

Detailed Description

template<typename T = double, std::size_t NDIM = 6>
class madness::CCPairFunction< T, NDIM >

a 6D function, either in full or low rank form, possibly including an 2-particle function

Helper structure for the coupling potential of CC Singles and Doubles because of the regularization of the CC-Wavefunction (for CC2: |tauij> = |uij> + Qt12*f12*|titj>) we have 6D-functions in std format |u> : type==pure_ we have 6D-functions in separated format: type==decomposed_ (e.g O1*f12*|titj> = |xy> with x=|k> and y=<k|f12|ti>*|tj>) we have 6D-function like f12|xy> which are not needed to be represented on the 6D MRA-Grid, type==op_decomposed_ functionality

Member Typedef Documentation

◆ pureT

template<typename T = double, std::size_t NDIM = 6>
using madness::CCPairFunction< T, NDIM >::pureT = Function<T,NDIM>

Constructor & Destructor Documentation

◆ CCPairFunction() [1/10]

template<typename T = double, std::size_t NDIM = 6>
madness::CCPairFunction< T, NDIM >::CCPairFunction ( )
default

empty ctor

◆ CCPairFunction() [2/10]

template<typename T = double, std::size_t NDIM = 6>
madness::CCPairFunction< T, NDIM >::CCPairFunction ( const Function< T, NDIM > &  ket)
inlineexplicit

takes a shallow copy of the argument function

References madness::CCPairFunction< T, NDIM >::component.

◆ CCPairFunction() [3/10]

template<typename T = double, std::size_t NDIM = 6>
madness::CCPairFunction< T, NDIM >::CCPairFunction ( const std::shared_ptr< CCConvolutionOperator< T, LDIM > >  op_,
const Function< T, NDIM > &  ket 
)
inlineexplicit

takes a shallow copy of the argument function

References madness::CCPairFunction< T, NDIM >::component.

◆ CCPairFunction() [4/10]

template<typename T = double, std::size_t NDIM = 6>
madness::CCPairFunction< T, NDIM >::CCPairFunction ( const std::vector< Function< T, LDIM > > &  f1,
const std::vector< Function< T, LDIM > > &  f2 
)
inlineexplicit

◆ CCPairFunction() [5/10]

template<typename T = double, std::size_t NDIM = 6>
madness::CCPairFunction< T, NDIM >::CCPairFunction ( const Function< T, LDIM > &  f1,
const Function< T, LDIM > &  f2 
)
inlineexplicit

takes a deep copy of the argument functions

References f1.

◆ CCPairFunction() [6/10]

template<typename T = double, std::size_t NDIM = 6>
madness::CCPairFunction< T, NDIM >::CCPairFunction ( const std::pair< std::vector< Function< T, LDIM > >, std::vector< Function< T, LDIM > > > &  f)
inlineexplicit

takes a deep copy of the argument functions

◆ CCPairFunction() [7/10]

template<typename T = double, std::size_t NDIM = 6>
madness::CCPairFunction< T, NDIM >::CCPairFunction ( const std::shared_ptr< CCConvolutionOperator< T, LDIM > >  op_,
const CCFunction< T, LDIM > &  f1,
const CCFunction< T, LDIM > &  f2 
)
inlineexplicit

takes a deep copy of the argument functions

References f1.

◆ CCPairFunction() [8/10]

template<typename T = double, std::size_t NDIM = 6>
madness::CCPairFunction< T, NDIM >::CCPairFunction ( const std::shared_ptr< CCConvolutionOperator< T, LDIM > >  op_,
const std::vector< Function< T, LDIM > > &  f1,
const std::vector< Function< T, LDIM > > &  f2 
)
inlineexplicit

◆ CCPairFunction() [9/10]

template<typename T = double, std::size_t NDIM = 6>
madness::CCPairFunction< T, NDIM >::CCPairFunction ( const std::shared_ptr< CCConvolutionOperator< T, LDIM > >  op_,
const Function< T, LDIM > &  f1,
const Function< T, LDIM > &  f2 
)
inlineexplicit

takes a deep copy of the argument functions

References f1.

◆ CCPairFunction() [10/10]

template<typename T = double, std::size_t NDIM = 6>
madness::CCPairFunction< T, NDIM >::CCPairFunction ( const CCPairFunction< T, NDIM > &  other)
default

copy ctor – shallow

Member Function Documentation

◆ apply() [1/3]

template<typename T , std::size_t NDIM>
std::vector< CCPairFunction< T, NDIM > > madness::CCPairFunction< T, NDIM >::apply ( const ProjectorBase P,
const std::vector< CCPairFunction< T, NDIM > > &  argument 
)
static

◆ apply() [2/3]

template<typename T = double, std::size_t NDIM = 6>
static std::vector< CCPairFunction< T, NDIM > > madness::CCPairFunction< T, NDIM >::apply ( const SeparatedConvolution< T, NDIM > &  G,
const CCPairFunction< T, NDIM > &  argument 
)
static

◆ apply() [3/3]

template<typename T = double, std::size_t NDIM = 6>
static std::vector< CCPairFunction< T, NDIM > > madness::CCPairFunction< T, NDIM >::apply ( const SeparatedConvolution< T, NDIM > &  G,
const std::vector< CCPairFunction< T, NDIM > > &  argument 
)
static

◆ assign_particles()

template<typename T , std::size_t NDIM>
const std::pair< std::vector< Function< T, CCPairFunction< T, NDIM >::LDIM > >, std::vector< Function< T, CCPairFunction< T, NDIM >::LDIM > > > madness::CCPairFunction< T, NDIM >::assign_particles ( const size_t  particle) const

small helper function that gives back (a,b) or (b,a) depending on the value of particle

References MADNESS_EXCEPTION.

◆ collect_same_types()

template<typename T = double, std::size_t NDIM = 6>
std::vector< CCPairFunction< T, NDIM > > madness::CCPairFunction< T, NDIM >::collect_same_types ( const std::vector< CCPairFunction< T, NDIM > > &  other)
staticprivate

collect all terms with of similiar type: pure, op_pure, decomposed, op_decomposed

vector includes OT_ONE, meaning no operator

References madness::append(), c, madness::copy(), madness::is_collected(), MADNESS_CHECK_THROW, op(), madness::OT_ONE, madness::OT_SIZE, and madness::transform_reconstructed().

◆ consolidate()

template<typename T = double, std::size_t NDIM = 6>
std::vector< CCPairFunction > madness::CCPairFunction< T, NDIM >::consolidate ( const std::vector< CCPairFunction< T, NDIM > > &  other,
const std::vector< std::string > &  options,
const std::vector< Vector< double, LDIM > > &  centers 
) const
private

◆ convert_to_pure_no_op_inplace()

template<typename T , std::size_t NDIM>
void madness::CCPairFunction< T, NDIM >::convert_to_pure_no_op_inplace ( )

◆ dec_to_pure()

template<typename T = double, std::size_t NDIM = 6>
std::vector< CCPairFunction< T, NDIM > > madness::CCPairFunction< T, NDIM >::dec_to_pure ( const std::vector< CCPairFunction< T, NDIM > > &  other)
staticprivate

turn decomposed functions without operator into pure functions without operators

turn decomposed functions with operator into pure functions

References c, madness::CCPairFunction< T, NDIM >::convert_to_pure_no_op_inplace(), and madness::copy().

◆ decomposed()

template<typename T = double, std::size_t NDIM = 6>
TwoBodyFunctionSeparatedComponent< T, NDIM > & madness::CCPairFunction< T, NDIM >::decomposed ( ) const
inline

◆ dirac_convolution()

template<typename T = double, std::size_t NDIM = 6>
Function< T, CCPairFunction< T, NDIM >::LDIM > madness::CCPairFunction< T, NDIM >::dirac_convolution ( const CCFunction< T, LDIM > &  x,
const CCConvolutionOperator< T, LDIM > &  op,
const size_t  particle 
) const

result is: <x|op12|f>_particle

Parameters
[in]xa 3D-CC_function
[in]opa CC_convoltion_operator which is currently either f12 or g12
[in]particlethe particle on which the operation acts (can be 1 or 2)
[out]theoperator is applied and afterwards a convolution with the delta function makes a 3D-function: <x|op|u>_particle

References MADNESS_EXCEPTION, and op().

◆ dirac_convolution_decomposed()

template<typename T , std::size_t NDIM>
Function< T, CCPairFunction< T, NDIM >::LDIM > madness::CCPairFunction< T, NDIM >::dirac_convolution_decomposed ( const CCFunction< T, LDIM > &  x,
const CCConvolutionOperator< T, LDIM > &  op,
const size_t  particle 
) const
Parameters
[in]xa 3D-CC_function
[in]opa CC_convoltion_operator which is currently either f12 or g12
[in]particlethe particle on which the operation acts (can be 1 or 2)
[out]theoperator is applied and afterwards a convolution with the delta function makes a 3D-function: <x|op|u>_particle in this case u=|ab> and the result is <x|op|u>_1 = <x|op|a>*|b> for particle==1

References madness::f, madness::CCFunction< T, NDIM >::function, madness::mul(), and op().

◆ get_a()

template<typename T = double, std::size_t NDIM = 6>
std::vector< Function< T, LDIM > > madness::CCPairFunction< T, NDIM >::get_a ( ) const
inline

◆ get_b()

template<typename T = double, std::size_t NDIM = 6>
std::vector< Function< T, LDIM > > madness::CCPairFunction< T, NDIM >::get_b ( ) const
inline

◆ get_function() [1/2]

template<typename T = double, std::size_t NDIM = 6>
Function< T, NDIM > & madness::CCPairFunction< T, NDIM >::get_function ( )
inline

◆ get_function() [2/2]

template<typename T = double, std::size_t NDIM = 6>
Function< T, NDIM > & madness::CCPairFunction< T, NDIM >::get_function ( ) const
inline

◆ get_operator()

template<typename T = double, std::size_t NDIM = 6>
const CCConvolutionOperator< T, LDIM > & madness::CCPairFunction< T, NDIM >::get_operator ( ) const
inline

◆ get_operator_ptr()

template<typename T = double, std::size_t NDIM = 6>
const std::shared_ptr< CCConvolutionOperator< T, LDIM > > madness::CCPairFunction< T, NDIM >::get_operator_ptr ( ) const
inline

◆ get_vector()

template<typename T = double, std::size_t NDIM = 6>
std::vector< Function< T, LDIM > > madness::CCPairFunction< T, NDIM >::get_vector ( const int  i) const
inline

◆ has_operator()

template<typename T = double, std::size_t NDIM = 6>
bool madness::CCPairFunction< T, NDIM >::has_operator ( ) const
inline

◆ info()

template<typename T = double, std::size_t NDIM = 6>
void madness::CCPairFunction< T, NDIM >::info ( ) const
inline

◆ inner_internal()

template<typename T , std::size_t NDIM>
double madness::CCPairFunction< T, NDIM >::inner_internal ( const CCPairFunction< T, NDIM > &  other,
const Function< T, LDIM > &  R2 
) const

◆ invert_sign()

template<typename T , std::size_t NDIM>
madness::CCPairFunction< T, NDIM > madness::CCPairFunction< T, NDIM >::invert_sign ( )

make a deep copy and invert the sign deep copy necessary otherwise: shallow copy errors

◆ is_assigned()

template<typename T = double, std::size_t NDIM = 6>
bool madness::CCPairFunction< T, NDIM >::is_assigned ( ) const
inline

◆ is_collected()

template<typename T , std::size_t NDIM>
bool madness::CCPairFunction< T, NDIM >::is_collected ( const std::vector< CCPairFunction< T, NDIM > > &  other)
static

References c.

Referenced by madness::is_collected().

◆ is_convertible_to_pure_no_op()

template<typename T , std::size_t NDIM>
bool madness::CCPairFunction< T, NDIM >::is_convertible_to_pure_no_op ( ) const

can this be converted to a pure representation (depends on the operator, if present)

References madness::OT_F12, madness::OT_SLATER, and madness::type().

Referenced by test_transformations().

◆ is_decomposed()

template<typename T = double, std::size_t NDIM = 6>
bool madness::CCPairFunction< T, NDIM >::is_decomposed ( ) const
inline

◆ is_decomposed_no_op()

template<typename T = double, std::size_t NDIM = 6>
bool madness::CCPairFunction< T, NDIM >::is_decomposed_no_op ( ) const
inline

◆ is_op_decomposed()

template<typename T = double, std::size_t NDIM = 6>
bool madness::CCPairFunction< T, NDIM >::is_op_decomposed ( ) const
inline

◆ is_op_pure()

template<typename T = double, std::size_t NDIM = 6>
bool madness::CCPairFunction< T, NDIM >::is_op_pure ( ) const
inline

◆ is_pure()

template<typename T = double, std::size_t NDIM = 6>
bool madness::CCPairFunction< T, NDIM >::is_pure ( ) const
inline

◆ is_pure_no_op()

template<typename T = double, std::size_t NDIM = 6>
bool madness::CCPairFunction< T, NDIM >::is_pure_no_op ( ) const
inline

◆ make_xy_u()

template<typename T , std::size_t NDIM>
double madness::CCPairFunction< T, NDIM >::make_xy_u ( const CCFunction< T, LDIM > &  xx,
const CCFunction< T, LDIM > &  yy 
) const

◆ multiply_with_op_inplace()

template<typename T = double, std::size_t NDIM = 6>
CCPairFunction< T, NDIM > & madness::CCPairFunction< T, NDIM >::multiply_with_op_inplace ( const std::shared_ptr< CCConvolutionOperator< T, LDIM > >  op)

multiplication with a 2-particle function

References op().

Referenced by madness::CCPairFunction< T, NDIM >::operator*().

◆ name()

template<typename T = double, std::size_t NDIM = 6>
std::string madness::CCPairFunction< T, NDIM >::name ( const bool  transpose = false) const
inline

◆ norm2()

template<typename T = double, std::size_t NDIM = 6>
Tensor< T >::scalar_type madness::CCPairFunction< T, NDIM >::norm2 ( ) const
inline

◆ op_dec_to_dec()

template<typename T = double, std::size_t NDIM = 6>
std::vector< CCPairFunction< T, NDIM > > madness::CCPairFunction< T, NDIM >::op_dec_to_dec ( const std::vector< CCPairFunction< T, NDIM > > &  other,
const std::vector< Vector< double, LDIM > > &  centers 
)
staticprivate

◆ op_dec_to_pure()

template<typename T = double, std::size_t NDIM = 6>
std::vector< CCPairFunction< T, NDIM > > madness::CCPairFunction< T, NDIM >::op_dec_to_pure ( const std::vector< CCPairFunction< T, NDIM > > &  other)
staticprivate

turn decomposed functions with operator into pure functions without operators

turn decomposed functions with operator into pure functions

References c, madness::CCPairFunction< T, NDIM >::convert_to_pure_no_op_inplace(), and madness::copy().

◆ op_pure_to_pure()

template<typename T = double, std::size_t NDIM = 6>
std::vector< CCPairFunction< T, NDIM > > madness::CCPairFunction< T, NDIM >::op_pure_to_pure ( const std::vector< CCPairFunction< T, NDIM > > &  other)
staticprivate

◆ operator()()

template<typename T = double, std::size_t NDIM = 6>
CCPairFunction & madness::CCPairFunction< T, NDIM >::operator() ( const CCPairFunction< T, NDIM > &  other)
inline

shallow assignment operator

References madness::CCPairFunction< T, NDIM >::component.

◆ operator*() [1/2]

template<typename T = double, std::size_t NDIM = 6>
CCPairFunction madness::CCPairFunction< T, NDIM >::operator* ( const double  fac) const
inline

scalar multiplication: f*fac

References madness::CCPairFunction< T, NDIM >::copy.

◆ operator*() [2/2]

template<typename T = double, std::size_t NDIM = 6>
CCPairFunction madness::CCPairFunction< T, NDIM >::operator* ( const std::shared_ptr< CCConvolutionOperator< T, LDIM > >  op)
inline

◆ operator*=()

template<typename T = double, std::size_t NDIM = 6>
CCPairFunction & madness::CCPairFunction< T, NDIM >::operator*= ( const double  fac)
inline

◆ partial_inner() [1/2]

template<typename T = double, std::size_t NDIM = 6>
CCPairFunction madness::CCPairFunction< T, NDIM >::partial_inner ( const CCPairFunction< T, NDIM > &  other,
const std::array< int, LDIM > &  v1,
const std::array< int, LDIM > &  v2 
) const

◆ partial_inner() [2/2]

template<typename T = double, std::size_t NDIM = 6>
Function< T, LDIM > madness::CCPairFunction< T, NDIM >::partial_inner ( const Function< T, LDIM > &  f,
const std::array< int, LDIM > &  v1,
const std::array< int, LDIM > &  v2 
) const

◆ print_size()

template<typename T = double, std::size_t NDIM = 6>
void madness::CCPairFunction< T, NDIM >::print_size ( const std::string  name1 = "") const
inline

◆ project_out()

template<typename T , std::size_t NDIM>
Function< T, CCPairFunction< T, NDIM >::LDIM > madness::CCPairFunction< T, NDIM >::project_out ( const CCFunction< T, LDIM > &  f,
const size_t  particle 
) const
Parameters
[in]fa 3D-CC_function
[in]particlethe particle on which the operation acts
[out]<f|u>_particle(projection from 6D to 3D)

References madness::f, madness::Function< T, NDIM >::is_initialized(), MADNESS_ASSERT, MADNESS_EXCEPTION, and madness::Function< T, NDIM >::project_out().

◆ project_out_decomposed()

template<typename T , std::size_t NDIM>
Function< T, CCPairFunction< T, NDIM >::LDIM > madness::CCPairFunction< T, NDIM >::project_out_decomposed ( const Function< T, LDIM > &  f,
const size_t  particle 
) const
Parameters
[in]fa 3D-CC_function
[in]particlethe particle on which the operation acts
[out]<f|u>_particle(projection from 6D to 3D) for the case that u=|ab> so <f|u>_particle = <f|a>*|b> if particle==1

References c, madness::f, and madness::inner().

◆ project_out_op_decomposed()

template<typename T , std::size_t NDIM>
Function< T, CCPairFunction< T, NDIM >::LDIM > madness::CCPairFunction< T, NDIM >::project_out_op_decomposed ( const CCFunction< T, LDIM > &  f,
const size_t  particle 
) const
Parameters
[in]fa 3D-CC_function
[in]particlethe particle on which the operation acts
[out]<f|u>_particle(projection from 6D to 3D) for the case that u=op|xy> so <f|u>_particle = <f|op|x>*|y> if particle==1

References madness::f, MADNESS_EXCEPTION, madness::mul(), op(), and sum.

◆ pure()

template<typename T = double, std::size_t NDIM = 6>
TwoBodyFunctionPureComponent< T, NDIM > & madness::CCPairFunction< T, NDIM >::pure ( ) const
inline

◆ remove_linearly_dependent_terms()

template<typename T = double, std::size_t NDIM = 6>
std::vector< CCPairFunction< T, NDIM > > madness::CCPairFunction< T, NDIM >::remove_linearly_dependent_terms ( const std::vector< CCPairFunction< T, NDIM > > &  other,
double  thresh = -1.0 
)
staticprivate

◆ reset_operator()

template<typename T = double, std::size_t NDIM = 6>
void madness::CCPairFunction< T, NDIM >::reset_operator ( const std::shared_ptr< CCConvolutionOperator< T, LDIM > >  op)
inline

◆ swap_particles()

template<typename T = double, std::size_t NDIM = 6>
CCPairFunction madness::CCPairFunction< T, NDIM >::swap_particles ( ) const
inline
Parameters
[out]particlesare interchanged, if the function was u(1,2) the result is u(2,1)

References madness::CCPairFunction< T, NDIM >::component, and madness::CCPairFunction< T, NDIM >::copy.

Referenced by madness::apply(), and test_swap_particles().

◆ to_pure()

template<typename T = double, std::size_t NDIM = 6>
CCPairFunction madness::CCPairFunction< T, NDIM >::to_pure ( ) const
inline

out-of-place conversion to pure function

References madness::CCPairFunction< T, NDIM >::copy, and MADNESS_CHECK.

◆ world()

template<typename T = double, std::size_t NDIM = 6>
World & madness::CCPairFunction< T, NDIM >::world ( ) const
inline

Friends And Related Symbol Documentation

◆ consolidate

template<typename T = double, std::size_t NDIM = 6>
std::vector< CCPairFunction > consolidate ( const std::vector< CCPairFunction< T, NDIM > > &  other,
const std::vector< std::string >  options = std::vector<std::string>(),
const std::vector< Vector< double, LDIM > >  centers = std::vector<Vector<double,LDIM>>() 
)
friend

collect the terms into a compact format

Parameters
[in]othera vector of CCPairFunctions
[in]optionsa vector of strings which can be "one_term", "op_pure_to_pure", "svd"
[in]centersa vector of 3D-vectors which are the centers of the grid for low-rank functions TODO: implement a function for removing linearly dependent terms without orthonormalization

◆ copy

template<typename T = double, std::size_t NDIM = 6>
CCPairFunction copy ( const CCPairFunction< T, NDIM > &  other)
friend

◆ hash_value

template<typename T = double, std::size_t NDIM = 6>
hashT hash_value ( const CCPairFunction< T, NDIM > &  f)
friend

◆ inner [1/3]

template<typename T = double, std::size_t NDIM = 6>
double inner ( const CCPairFunction< T, NDIM > &  a,
const CCPairFunction< T, NDIM > &  b 
)
friend

◆ inner [2/3]

template<typename T = double, std::size_t NDIM = 6>
double inner ( const CCPairFunction< T, NDIM > &  a,
const CCPairFunction< T, NDIM > &  b,
const Function< T, LDIM > &  R2 
)
friend

◆ inner [3/3]

template<typename T = double, std::size_t NDIM = 6>
double inner ( const std::vector< CCPairFunction< T, NDIM > > &  va,
const std::vector< CCPairFunction< T, NDIM > > &  vb,
const Function< T, LDIM R2 = Function<T,LDIM>() 
)
friend

◆ multiply [1/2]

template<typename T = double, std::size_t NDIM = 6>
CCPairFunction< T, NDIM > multiply ( const CCPairFunction< T, NDIM > &  other,
const Function< T, LDIM > &  f,
const std::array< int, LDIM > &  v1 
)
friend

multiply CCPairFunction with a 3D function of one of the two particles

◆ multiply [2/2]

template<typename T = double, std::size_t NDIM = 6>
std::vector< CCPairFunction > multiply ( const std::vector< CCPairFunction< T, NDIM > > &  other,
const Function< T, LDIM f,
const std::array< int, LDIM > &  v1 
)
friend

◆ operator* [1/3]

template<typename T = double, std::size_t NDIM = 6>
CCPairFunction operator* ( const double  fac,
const CCPairFunction< T, NDIM > &  f 
)
friend

scalar multiplication: fac*f

◆ operator* [2/3]

template<typename T = double, std::size_t NDIM = 6>
CCPairFunction operator* ( const std::shared_ptr< CCConvolutionOperator< T, LDIM > >  op,
const CCPairFunction< T, NDIM > &  f 
)
friend

multiplication with a 2-particle function

◆ operator* [3/3]

template<typename T = double, std::size_t NDIM = 6>
std::vector< CCPairFunction > operator* ( const std::shared_ptr< CCConvolutionOperator< T, LDIM > >  op,
const std::vector< CCPairFunction< T, NDIM > > &  f 
)
friend

multiplication with a 2-particle function

◆ swap_particles

template<typename T = double, std::size_t NDIM = 6>
std::vector< CCPairFunction > swap_particles ( const std::vector< CCPairFunction< T, NDIM > > &  argument)
friend

Member Data Documentation

◆ component

template<typename T = double, std::size_t NDIM = 6>
std::shared_ptr<TwoBodyFunctionComponentBase> madness::CCPairFunction< T, NDIM >::component

the 3 types of 6D-function that occur in the CC potential which coupled doubles to singles

Referenced by madness::CCPairFunction< T, NDIM >::CCPairFunction(), madness::CCPairFunction< T, NDIM >::CCPairFunction(), madness::CCPairFunction< T, NDIM >::CCPairFunction(), madness::CCPairFunction< T, NDIM >::CCPairFunction(), madness::CCPairFunction< T, NDIM >::decomposed(), madness::CCPairFunction< T, NDIM >::get_a(), madness::CCPairFunction< T, NDIM >::get_b(), madness::CCPairFunction< T, NDIM >::get_function(), madness::CCPairFunction< T, NDIM >::get_function(), madness::CCPairFunction< T, NDIM >::get_operator(), madness::CCPairFunction< T, NDIM >::get_operator_ptr(), madness::CCPairFunction< T, NDIM >::get_vector(), madness::CCPairFunction< T, NDIM >::has_operator(), madness::CCPairFunction< T, NDIM >::is_assigned(), madness::CCPairFunction< T, NDIM >::is_decomposed(), madness::CCPairFunction< T, NDIM >::is_decomposed_no_op(), madness::CCPairFunction< T, NDIM >::is_op_decomposed(), madness::CCPairFunction< T, NDIM >::is_pure(), madness::CCPairFunction< T, NDIM >::name(), madness::CCPairFunction< T, NDIM >::norm2(), madness::CCPairFunction< T, NDIM >::operator()(), madness::CCPairFunction< T, NDIM >::operator*=(), madness::CCPairFunction< T, NDIM >::print_size(), madness::CCPairFunction< T, NDIM >::pure(), madness::CCPairFunction< T, NDIM >::reset_operator(), madness::CCPairFunction< T, NDIM >::swap_particles(), test_constructor(), and madness::CCPairFunction< T, NDIM >::world().

◆ LDIM

template<typename T = double, std::size_t NDIM = 6>
constexpr std::size_t madness::CCPairFunction< T, NDIM >::LDIM =NDIM/2
staticconstexpr

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