OpenWalnut
1.4.0
|
#include <WTensorBase.h>
Public Types | |
enum | { dataSize = 1 } |
Declare a compile-time constant as enum and not as static constant. More... | |
Public Member Functions | |
WTensorBaseSym () | |
Standard constructor. More... | |
WTensorBaseSym (WTensorBaseSym const &t) | |
Copy constructor. More... | |
WTensorBaseSym const & | operator= (WTensorBaseSym const &t) |
Copy operator. More... | |
std::size_t | getDimension () const |
Get the dimension of this tensor. More... | |
std::size_t | getOrder () const |
Get the order of this tensor. More... | |
template<typename Index_T > | |
Data_T & | operator[] (std::vector< Index_T > const &) |
Get the value of this scalar. More... | |
template<typename Index_T > | |
Data_T const & | operator[] (std::vector< Index_T > const &) const |
Get the value of this scalar. More... | |
template<typename Index_T > | |
Data_T & | operator[] (Index_T[]) |
Get the value of this scalar. More... | |
template<typename Index_T > | |
Data_T const & | operator[] (Index_T[]) const |
Get the value of this scalar. More... | |
bool | operator== (WTensorBaseSym const &other) const |
Compare this WTensorBase to another one. More... | |
bool | operator!= (WTensorBaseSym const &other) const |
Compare this WTensorBase to another one. More... | |
Protected Attributes | |
Data_T | m_data |
Stores the value. More... | |
Friends | |
class | ::WTensorBaseSymTest |
class | ::WTensorFuncTest |
dim | The dimension of the tensor, i.e. the number of components in each direction. |
Data_T | The datatype of the components, double by default. |
Specialization for order = 0. This essentially encapsulates a scalar. The purpose of this specialization is compatibility for generic tensor functions.
Definition at line 1026 of file WTensorBase.h.
anonymous enum |
Declare a compile-time constant as enum and not as static constant.
Enumerator | |
---|---|
dataSize |
The number of elements to store. |
Definition at line 1157 of file WTensorBase.h.
|
inline |
Standard constructor.
All elements are set to Data_T().
Definition at line 1038 of file WTensorBase.h.
|
inline |
Copy constructor.
t | The tensor to copy from. |
Definition at line 1048 of file WTensorBase.h.
|
inline |
Get the dimension of this tensor.
Definition at line 1071 of file WTensorBase.h.
|
inline |
Get the order of this tensor.
Definition at line 1081 of file WTensorBase.h.
|
inline |
Compare this WTensorBase to another one.
other | The WBensorBase to compare to. |
Definition at line 1149 of file WTensorBase.h.
References WTensorBaseSym< order, dim, Data_T >::m_data.
|
inline |
Copy operator.
t | The tensor to copy from. |
Definition at line 1060 of file WTensorBase.h.
References WTensorBaseSym< order, dim, Data_T >::m_data.
|
inline |
Compare this WTensorBase to another one.
other | The WBensorBase to compare to. |
Definition at line 1137 of file WTensorBase.h.
References WTensorBaseSym< order, dim, Data_T >::m_data.
|
inline |
Get the value of this scalar.
Definition at line 1092 of file WTensorBase.h.
References WTensorBaseSym< order, dim, Data_T >::m_data.
|
inline |
Get the value of this scalar.
Definition at line 1103 of file WTensorBase.h.
References WTensorBaseSym< order, dim, Data_T >::m_data.
|
inline |
Get the value of this scalar.
Definition at line 1114 of file WTensorBase.h.
References WTensorBaseSym< order, dim, Data_T >::m_data.
|
inline |
Get the value of this scalar.
Definition at line 1125 of file WTensorBase.h.
References WTensorBaseSym< order, dim, Data_T >::m_data.
|
protected |
Stores the value.
Definition at line 1169 of file WTensorBase.h.