pomerol
2.1
|
Base class for sparse container types whose elements are addressable by four single-particle indices. More...
#include <IndexContainer4.hpp>
Public Member Functions | |
template<typename... IndexTypes> | |
IndexContainer4 (SourceObject const &Source, IndexClassification< IndexTypes... > const &IndexInfo) | |
void | fill (std::set< IndexCombination4 > Indices=std::set< IndexCombination4 >()) |
ElementWithPermFreq< ElementType > & | create (IndexCombination4 const &Indices) |
bool | isInContainer (IndexCombination4 const &Indices) const |
bool | isInContainer (ParticleIndex Index1, ParticleIndex Index2, ParticleIndex Index3, ParticleIndex Index4) const |
ElementWithPermFreq< ElementType > & | operator() (IndexCombination4 const &Indices) |
ElementWithPermFreq< ElementType > & | operator() (ParticleIndex Index1, ParticleIndex Index2, ParticleIndex Index3, ParticleIndex Index4) |
Protected Member Functions | |
std::set< IndexCombination4 > | enumerateIndices () const |
Protected Attributes | |
ParticleIndex | NumIndices |
Each of the four indices can change in the range [0; NumIndices[. More... | |
SourceObject const & | Source |
Stored elements are created by calling Source.createElement(Indices). More... | |
std::map< IndexCombination4, ElementWithPermFreq< ElementType > > | ElementsMap |
Sparse storage for the decorated elements. More... | |
std::map< IndexCombination4, std::shared_ptr< ElementType > > | NonTrivialElements |
Sparse storage for the plain (non-decorated) elements. More... | |
Base class for sparse container types whose elements are addressable by four single-particle indices.
Base class for sparse container types whose elements are addressable by four single-particle indices. The stored elements are also decorated by ElementWithPermFreq.
ElementType | Type of an element. |
SourceObject | Type of the source object used to create the elements. |
Definition at line 66 of file IndexContainer4.hpp.
|
inline |
Construct from a source object and an index classification object. The container is initially empty and shall be populated with elements by a subsequent call to fill().
IndexTypes | Types of indices carried by a single creation/annihilation operator. |
[in] | Source | Source object used to create stored elements. |
[in] | IndexInfo | Classification of single-particle indices. |
Definition at line 91 of file IndexContainer4.hpp.
|
inline |
Create a stored element from the source object by its index combination.
[in] | Indices | Index combination of the element to be created. |
Definition at line 192 of file IndexContainer4.hpp.
|
inlineprotected |
Generate a complete set of index combinations usable to address elements in the container.
Definition at line 263 of file IndexContainer4.hpp.
|
inline |
Fill the container with elements from the source object. Each element is created by calling Source.createElement(IndexCombination).
[in] | Indices | Set of index combinations of the elements to be created. An empty set results in creation of elements for all possible index combinations. |
Definition at line 172 of file IndexContainer4.hpp.
|
inline |
Check if an element for a given index combination is stored in the container.
[in] | Indices | Index combination. |
Definition at line 159 of file IndexContainer4.hpp.
|
inline |
Check if an element for a given index combination is stored in the container.
[in] | Index1 | First index in the combination. |
[in] | Index2 | Second index in the combination. |
[in] | Index3 | Third index in the combination. |
[in] | Index4 | Fourth index in the combination. |
Definition at line 164 of file IndexContainer4.hpp.
|
inline |
Get a reference to a stored element by its index combination.
[in] | Indices | Index combination. |
Definition at line 241 of file IndexContainer4.hpp.
|
inline |
Get a reference to a stored element by its index combination.
[in] | Index1 | First index in the combination. |
[in] | Index2 | Second index in the combination. |
[in] | Index3 | Third index in the combination. |
[in] | Index4 | Fourth index in the combination. |
Definition at line 255 of file IndexContainer4.hpp.
|
protected |
Sparse storage for the decorated elements.
Definition at line 79 of file IndexContainer4.hpp.
|
protected |
Sparse storage for the plain (non-decorated) elements.
Definition at line 81 of file IndexContainer4.hpp.
|
protected |
Each of the four indices can change in the range [0; NumIndices[.
Definition at line 69 of file IndexContainer4.hpp.
|
protected |
Stored elements are created by calling Source.createElement(Indices).
Definition at line 72 of file IndexContainer4.hpp.