1#ifndef _chi_meshtensor_rank2_dim3_h
2#define _chi_meshtensor_rank2_dim3_h
10 std::vector<chi_mesh::Vector3>
t;
50 for (
int i=0; i<3; ++i)
51 for (
int j=0; j<3; ++j)
52 new_t[i](j) = this->t[i][j] + that.
t[i][j];
61 for (
int i=0; i<3; ++i)
62 for (
int j=0; j<3; ++j)
63 this->t[i](j) += that.
t[i][j];
74 for (
int i=0; i<3; ++i)
75 for (
int j=0; j<3; ++j)
76 new_t[i](j) = this->t[i][j] - that.
t[i][j];
85 for (
int i=0; i<3; ++i)
86 for (
int j=0; j<3; ++j)
87 this->t[i](j) -= that.
t[i][j];
98 for (
int i=0; i<3; ++i)
99 for (
int j=0; j<3; ++j)
100 new_t[i](j) = this->t[i][j]*value;
109 for (
int i=0; i<3; ++i)
110 for (
int j=0; j<3; ++j)
111 this->t[i](j) *= value;
122 for (
int i=0; i<3; ++i)
123 for (
int j=0; j<3; ++j)
124 new_t[i](j) = this->t[i][j]/value;
133 for (
int i=0; i<3; ++i)
134 for (
int j=0; j<3; ++j)
135 this->t[i](j) /= value;
146 for (
int i=0; i<3; ++i)
147 for (
int j=0; j<3; ++j)
148 new_t[i](j) = this->t[j][i];
166 for (
int i=0; i<3; ++i)
176 std::stringstream out;
178 for (
int i=0;i<3;i++)
180 for (
int j=0;j<3;j++)
182 out <<
t[i][j] <<
" ";
chi_mesh::TensorRank2Dim3 operator*(const double value, const chi_mesh::TensorRank2Dim3 &that)
TensorRank2Dim3 operator-(const TensorRank2Dim3 &that) const
TensorRank2Dim3 operator+(const TensorRank2Dim3 &that) const
TensorRank2Dim3 & operator=(const TensorRank2Dim3 &that)
TensorRank2Dim3 & operator/=(const double value)
TensorRank2Dim3(const TensorRank2Dim3 &that)
TensorRank2Dim3 & operator-=(const TensorRank2Dim3 &that)
TensorRank2Dim3 Transpose()
std::vector< chi_mesh::Vector3 > t
Tensor entries.
TensorRank2Dim3 operator*(const double value) const
TensorRank2Dim3 & operator*=(const double value)
Vector3 Dot(const chi_mesh::Vector3 &v) const
TensorRank2Dim3 & operator+=(const TensorRank2Dim3 &that)
chi_mesh::Vector3 Diag() const
TensorRank2Dim3(const double value)
TensorRank2Dim3 operator/(const double value) const
chi_mesh::Vector3 & operator[](int index)