50 Tensor(
const double &xx,
const double &xy,
const double &xz,
const double &yx,
const double &yy,
const double &yz,
const double &zx,
const double &zy,
const double &zz);
83 void setXX(
const double& xx);
86 void setXY(
const double& xy);
89 void setXZ(
const double& xz);
92 void setYX(
const double& xx);
95 void setYY(
const double& xy);
98 void setYZ(
const double& xz);
101 void setZX(
const double& xx);
104 void setZY(
const double& xy);
107 void setZZ(
const double& xz);
155 double trace()
const;
Tensor tensorEigenvalues
Definition Tensor.cpp:41
Tensor tensorG2
Definition Tensor.cpp:39
Tensor tensorNonConsCobase
Definition Tensor.cpp:36
TensorElement
Enumeration for the tensor elements.
Definition Tensor.h:41
@ ZZ
Definition Tensor.h:41
@ XY
Definition Tensor.h:41
@ XZ
Definition Tensor.h:41
@ YZ
Definition Tensor.h:41
@ YX
Definition Tensor.h:41
@ YY
Definition Tensor.h:41
@ XX
Definition Tensor.h:41
@ ZX
Definition Tensor.h:41
@ ZY
Definition Tensor.h:41
Tensor tensorCobase
Definition Tensor.cpp:35
Tensor tensorD
Definition Tensor.cpp:44
Tensor tensorP
Definition Tensor.cpp:42
Tensor operator*(const double &scalar, const Tensor &a)
Definition Tensor.cpp:576
Tensor tensorBuff
Definition Tensor.cpp:33
Tensor operator+(const Tensor &a, const Tensor &b)
Definition Tensor.cpp:585
Tensor tensorA
Definition Tensor.cpp:40
Tensor tensorG
Definition Tensor.cpp:38
Tensor operator-(const Tensor &a, const Tensor &b)
Definition Tensor.cpp:594
Tensor tensorF
Definition Tensor.cpp:37
Tensor tensorPinverse
Definition Tensor.cpp:43
Tensor tensorIdentity
Definition Tensor.cpp:34
Class for a coordinate system object such as coordinates of the vertex or a vector.
Definition Coord.h:43
Class for a matrix 3x3 system object.
Definition Tensor.h:46
void setYZ(const double &xz)
Set the value in the yz-element of the Tensor object.
Definition Tensor.cpp:130
void setTensorByColumns(const Coord &x, const Coord &y, const Coord &z)
Definition Tensor.cpp:284
void correctZeros()
Set to perfect zero each of the epsilon terms.
Definition Tensor.cpp:181
void matrixProduct(const Tensor &tensor2, Tensor &resultingTensor) const
Compute the matrix product of the two tensors.
Definition Tensor.cpp:345
const double & getZX() const
Return the value of the zx-element of the Tensor object.
Definition Tensor.h:76
const double & getXZ() const
Return the value of the xz-element of the Tensor object.
Definition Tensor.h:68
bool isIdentity() const
Return true if equal to identity.
Definition Tensor.cpp:408
void setZZ(const double &xz)
Set the value in the zz-element of the Tensor object.
Definition Tensor.cpp:142
void setZY(const double &xy)
Set the value in the zy-element of the Tensor object.
Definition Tensor.cpp:138
void transpose(Tensor &transposedTensor) const
Compute the transpose of the tensor.
Definition Tensor.cpp:328
void setXZ(const double &xz)
Set the value in the xz-element of the Tensor object.
Definition Tensor.cpp:118
double determinant() const
Return the determinant of the tensor.
Definition Tensor.cpp:378
std::array< double, 9 > m_array
Definition Tensor.h:181
Tensor()
Definition Tensor.cpp:46
Tensor & operator*=(const double &scalar)
Definition Tensor.cpp:517
void setYY(const double &xy)
Set the value in the yy-element of the Tensor object.
Definition Tensor.cpp:126
double trace() const
Return the trace of the tensor.
Definition Tensor.cpp:371
~Tensor()
Definition Tensor.cpp:98
void tensorToArray(double *array) const
Transform the Tensor into 1D array (pointer)
Definition Tensor.cpp:310
void setTensor(const Tensor &tensor)
Set the Tensor object.
Definition Tensor.cpp:146
Tensor & operator-=(const Tensor &a)
Definition Tensor.cpp:565
const double & getElement(const int &element) const
Return the value of the specific element of the Tensor object.
Definition Tensor.h:62
void localProjection(const Coord &normal, const Coord &tangent, const Coord &binormal)
Projection in the local coordinate system which is defined by the transmitted normal,...
Definition Tensor.cpp:200
void reverseProjection(const Coord &normal, const Coord &tangent, const Coord &binormal)
Reverse projection in the absolute Cartesian coordinate system.
Definition Tensor.cpp:234
void eigen(Tensor &eigenvalues, Tensor &eigenvectors) const
Compute the eigenvalues and eigenvectors of the tensor with Jacobi's algorithm.
Definition Tensor.cpp:428
const double & getZY() const
Return the value of the zy-element of the Tensor object.
Definition Tensor.h:78
Coord scalar(const Coord &a) const
Return the scalar product between the Tensor and the Coord.
Definition Tensor.cpp:190
const double & getYX() const
Return the value of the yx-element of the Tensor object.
Definition Tensor.h:70
void setZX(const double &xx)
Set the value in the zx-element of the Tensor object.
Definition Tensor.cpp:134
static const Tensor defaultTensor
Default Tensor object (const version)
Definition Tensor.h:56
void setXX(const double &xx)
Set the value in the xx-element of the Tensor object.
Definition Tensor.cpp:110
void setTensorByLines(const Coord &x, const Coord &y, const Coord &z)
Definition Tensor.cpp:267
Tensor & operator+=(const Tensor &a)
Definition Tensor.cpp:555
void tensorToCoords(Coord &x, Coord &y, Coord &z) const
Transform the Tensor into Coords (vectors)
Definition Tensor.cpp:301
static Tensor defaultTensorNonConst
Default Tensor object (non-const version)
Definition Tensor.h:59
Tensor & operator/=(const double &scalar)
Definition Tensor.cpp:527
const double & getYY() const
Return the value of the yy-element of the Tensor object.
Definition Tensor.h:72
Tensor operator/(const double &scalar) const
Definition Tensor.cpp:546
const double & getZZ() const
Return the value of the zz-element of the Tensor object.
Definition Tensor.h:80
void setXY(const double &xy)
Set the value in the xy-element of the Tensor object.
Definition Tensor.cpp:114
const double & getXX() const
Return the value of the xx-element of the Tensor object.
Definition Tensor.h:64
void inverse(Tensor &inverseTensor) const
Compute the inverse of the tensor.
Definition Tensor.cpp:387
void setYX(const double &xx)
Set the value in the yx-element of the Tensor object.
Definition Tensor.cpp:122
void identity()
Set the Tensor object to identity.
Definition Tensor.cpp:164
Tensor & operator=(const double &scalar)
Definition Tensor.cpp:497
void arrayToTensor(const double *array)
Transform the 1D array (pointer) into Tensor.
Definition Tensor.cpp:319
const double & getYZ() const
Return the value of the yz-element of the Tensor object.
Definition Tensor.h:74
const double & getXY() const
Return the value of the xy-element of the Tensor object.
Definition Tensor.h:66
Tensor operator*(const double &scalar) const
Definition Tensor.cpp:537