67 inline static SP::EMM_2Tensors
New() {
92 return (*
this)[index][j+dim*i];
104 return (*
this)[index][j+dim*i];
124 (*this)(index,i,j)=v;
138 return (*
this)(index,i,j);
149 for (
tUSInt k=0;k<2;k++) n*=dim;
virtual tUSInt getTensorSize() const
get thememory size of the storage of each tensor
Definition: EMM_2Tensors.h:146
const tReal & getValue(const tUIndex &index, const tUSInt &i, const tUSInt &j) const
get the value of the tensor at index and at coordinates i,j
Definition: EMM_2Tensors.h:135
virtual ~EMM_2Tensors(void)
destroy
Definition: EMM_2Tensors.cpp:10
#define tUSInt
Definition: types.h:28
EMM_2Tensors()
create a 2 order tensor
Definition: EMM_2Tensors.cpp:4
static SP::EMM_2Tensors New()
builds a full tensor
Definition: EMM_2Tensors.h:67
const tUSInt & getDimension() const
get the dimension of the tensor
Definition: EMM_Tensors.h:252
DEFINE_SPTR(EMM_2Tensors)
void setValue(const tUIndex &index, const tUSInt &i, const tUSInt &j, const tReal &v)
set the value of the tensor at index and at coordinates i,j to v
Definition: EMM_2Tensors.h:120
virtual const tReal & operator()(const tUIndex &index, const tUSInt &i, const tUSInt &j) const
get the values at index i,j of the tensor at index
Definition: EMM_2Tensors.h:90
#define tUIndex
Definition: types.h:126
This class describes a morse array of tensors of 2 order.
Definition: EMM_2Tensors.h:17
virtual tReal & operator()(const tUIndex &index, const tUSInt &i, const tUSInt &j)
get the values at index i,j of the tensor at index
Definition: EMM_2Tensors.h:102
virtual SP::EMM_Tensors NewInstance() const
create a new instance
Definition: EMM_2Tensors.h:77
#define tReal
Definition: types.h:118
This class describes a morse array of tensors.
Definition: EMM_Tensors.h:20
class Free introduced for deleting a smart pointer
Definition: CORE_Object.h:141