MPQC
3.0.0-alpha
|
Tensor metadata is implicit; MTensor is Tensor + metadata. More...
#include <chemistry/qc/ccr12/mtensor.h>
Public Types | |
typedef CCR12_Info | Info |
typedef long | tile_index |
typedef long | element_index |
typedef std::pair< tile_index, tile_index > | tile_range |
typedef std::vector< tile_range > | tile_ranges |
typedef std::pair< element_index, element_index > | element_range |
typedef std::vector< element_range > | element_ranges |
typedef std::vector< element_index > | element_index_map |
Public Member Functions | |
MTensor (Info const *info, Tensor *tensor, const tile_ranges &range) | |
void | convert (const Ref< DistArray4 > &src, unsigned int tbtype, const element_index_map &eimap0, const element_index_map &eimap1, const element_index_map &eimap2, const element_index_map &eimap3, element_ranges const *mapped_element_ranges=0, bool src_is_2301=false) |
copies contents of src to this. More... | |
template<typename SrcType > | |
void | convert (const SrcType &src, int n1, int n3, const element_index_map &eimap0, const element_index_map &eimap1, const element_index_map &eimap2, const element_index_map &eimap3, element_ranges const *mapped_element_ranges=0) |
copies contents of src to this. More... | |
template<typename SrcType > | |
void | convert (const SrcType &src0, const SrcType &src1, int n0, int n1, int n2, int n3, const element_index_map &eimap0, const element_index_map &eimap1, const element_index_map &eimap2, const element_index_map &eimap3, element_ranges const *mapped_element_ranges=0, bool src1_is_1023=false) |
copies contents of (src0, src1) to this, where src0 = (01|23) and src1 = (01|32), if src1_is_1023 == false, or src1 = (10|23), if src1_is_1023 == true. More... | |
template<typename SrcType > | |
void | convert (const SrcType &src, const element_index_map &eimap0, const element_index_map &eimap1, element_ranges const *mapped_element_ranges=0) |
copies contents of src to this. More... | |
void | print (const std::string &label, std::ostream &os=ExEnv::out0()) const |
Static Public Attributes | |
static const size_t | ndim = NDIM |
|
inline |
range | is a vector of NDIM elements that contains tile range for each dimension [start, fence) |
void sc::MTensor< NDIM >::convert | ( | const Ref< DistArray4 > & | src, |
unsigned int | tbtype, | ||
const element_index_map & | eimap0, | ||
const element_index_map & | eimap1, | ||
const element_index_map & | eimap2, | ||
const element_index_map & | eimap3, | ||
element_ranges const * | mapped_element_ranges = 0 , |
||
bool | src_is_2301 = false |
||
) |
copies contents of src to this.
indexing of elements in src may be different from that in this. arrays eimap0 through eimap3 provide mapping
src integrals are assumed to not be antisymmetrized
mapped_element_ranges specifies the elements contained in src. Tiles that request elements outside these ranges will be skipped. Default to allow all elements.
src_is_2301 | set to true if src contains <2 3|0 1> integrals |
|
inline |
copies contents of src to this.
src is assumed to be a RefSCMatrix or a RefSymmSCMatrix indexing of elements in src may be different from that in this. arrays eimap0 through eimap3 provide mapping
src integrals are assumed to not be antisymmetrized
References sc::Tensor::add_block(), sc::Tensor::exists(), sc::Tensor::is_this_local(), and sc::ExEnv::out0().
|
inline |
copies contents of src to this.
src is assumed to be a RefSCMatrix or a RefSymmSCMatrix indexing of elements in src may be different from that in this. arrays eimap0 through eimap3 provide mapping.
src integrals are assumed to not be antisymmetrized.
to compute antisymmetrized integrals src must contain (01|23) and (01|32) or (10|23). if it doesn't, use convert() function that takes 2 src tensors.
References sc::Tensor::exists(), sc::Tensor::is_this_local(), sc::ExEnv::out0(), and sc::Tensor::put_block().
|
inline |
copies contents of (src0, src1) to this, where src0 = (01|23) and src1 = (01|32), if src1_is_1023 == false, or src1 = (10|23), if src1_is_1023 == true.
.src arrays are assumed to be RefSCMatrix or RefSymmSCMatrix indexing of elements in src arrays may be different from that in this. arrays eimap0 through eimap3 provide mapping.
src integrals are assumed to not be antisymmetrized.
References sc::Tensor::exists(), sc::Tensor::is_this_local(), sc::ExEnv::out0(), and sc::Tensor::put_block().