MADNESS 0.10.1
Public Types | Public Member Functions | Static Public Member Functions | Public Attributes | List of all members
madness::Pairs< T > Struct Template Reference

#include <CCStructures.h>

Public Types

typedef std::map< std::pair< int, int >, TpairmapT
 

Public Member Functions

template<typename R , typename opT >
Pairs< Rconvert (const Pairs< T > arg, const opT op) const
 convert Pairs<T> to another type
 
bool empty () const
 
void insert (int i, int j, const T &pair)
 
Toperator() (int i, int j)
 getter
 
const Toperator() (int i, int j) const
 getter
 
void swap (Pairs< T > &other)
 swap the contant of the pairmap
 

Static Public Member Functions

static std::vector< Tpairs2vector (const Pairs< T > &argument, const PairVectorMap map)
 
static Pairs vector2pairs (const std::vector< T > &argument, const PairVectorMap map)
 

Public Attributes

pairmapT allpairs
 

Detailed Description

template<typename T>
struct madness::Pairs< T >

POD holding all electron pairs with easy access Similar strucutre than the Pair structure from MP2 but with some additional features (merge at some point) This structure will also be used for intermediates

Member Typedef Documentation

◆ pairmapT

template<typename T >
typedef std::map<std::pair<int, int>, T> madness::Pairs< T >::pairmapT

Member Function Documentation

◆ convert()

template<typename T >
template<typename R , typename opT >
Pairs< R > madness::Pairs< T >::convert ( const Pairs< T arg,
const opT  op 
) const
inline

convert Pairs<T> to another type

opT op takes an object of T and returns the result type

References madness::arg(), madness::Pairs< T >::insert(), op(), and p().

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

◆ empty()

template<typename T >
bool madness::Pairs< T >::empty ( ) const
inline

◆ insert()

template<typename T >
void madness::Pairs< T >::insert ( int  i,
int  j,
const T pair 
)
inline

◆ operator()() [1/2]

template<typename T >
T & madness::Pairs< T >::operator() ( int  i,
int  j 
)
inline

getter

References madness::Pairs< T >::allpairs.

◆ operator()() [2/2]

template<typename T >
const T & madness::Pairs< T >::operator() ( int  i,
int  j 
) const
inline

getter

References madness::Pairs< T >::allpairs.

◆ pairs2vector()

template<typename T >
static std::vector< T > madness::Pairs< T >::pairs2vector ( const Pairs< T > &  argument,
const PairVectorMap  map 
)
inlinestatic

◆ swap()

template<typename T >
void madness::Pairs< T >::swap ( Pairs< T > &  other)
inline

◆ vector2pairs()

template<typename T >
static Pairs madness::Pairs< T >::vector2pairs ( const std::vector< T > &  argument,
const PairVectorMap  map 
)
inlinestatic

Member Data Documentation

◆ allpairs

template<typename T >
pairmapT madness::Pairs< T >::allpairs

The documentation for this struct was generated from the following file: