#include <sym_mat3.h>

Public Types | |
|
typedef af::tiny_plain < NumType, 6 > | base_type |
Public Member Functions | |
| sym_mat3 () | |
| Default constructor. Elements are not initialized. | |
| sym_mat3 (NumType const &e00, NumType const &e11, NumType const &e22, NumType const &e01, NumType const &e02, NumType const &e12) | |
| Constructor. | |
| sym_mat3 (base_type const &a) | |
| Constructor. | |
| sym_mat3 (const NumType *a) | |
| Constructor. | |
| sym_mat3 (NumType const &diag) | |
| Constructor for diagonal matrix. | |
| sym_mat3 (af::tiny_plain< NumType, 3 > const &diag) | |
| Constructor for diagonal matrix. | |
| sym_mat3 (mat3< NumType > const &m) | |
| Construction from full 3x3 matrix. | |
| sym_mat3 (mat3< NumType > const &m, NumType const &relative_tolerance) | |
| Construction from full 3x3 matrix. | |
| NumType const & | operator() (std::size_t r, std::size_t c) const |
| Access elements with 2-dimensional indices. | |
| NumType & | operator() (std::size_t r, std::size_t c) |
| Access elements with 2-dimensional indices. | |
| vec3< NumType > | diagonal () const |
| Return diagonal elements. | |
| sym_mat3 | transpose () |
| Return the transposed matrix. | |
| NumType | trace () const |
| Return trace (sum of diagonal elements). | |
| NumType | determinant () const |
| Return determinant. | |
| sym_mat3 | co_factor_matrix_transposed () const |
| Return the transposed of the co-factor matrix. | |
| sym_mat3 | inverse () const |
| Return the inverse matrix. | |
| sym_mat3 | tensor_transform (mat3< NumType > const &c) const |
| Tensor transform: c * (*this) * c.transpose(). | |
| sym_mat3 | antisymmetric_tensor_transform (NumType const &v0, NumType const &v1, NumType const &v2) const |
| Antisymmetric tensor transform: c * (*this) * c.transpose(). | |
| sym_mat3 | antisymmetric_tensor_transform (vec3< NumType > const &v) const |
| Antisymmetric tensor transform: c * (*this) * c.transpose(). | |
| sym_mat3 | tensor_transpose_transform (mat3< NumType > const &c) const |
| Tensor transform: c.transpose() * (*this) * c. | |
| NumType | dot (sym_mat3 const &other) const |
| Sum of 9 element-wise products. | |
Construction from full 3x3 matrix.
The off-diagonal elements of the new sym_mat3 are copied from the upper-right triangle of m.
An exception is thrown if the absolute value of the difference between any pair of off-diagonal elements is different from zero.
See also: mat3<>::is_symmetric()
Construction from full 3x3 matrix.
The off-diagonal elements of the new sym_mat3 are determined as the averages of the corresponding off-diagonal elements of the input matrix m.
If relative_tolerance is greater than or equal to zero, it is used to check the input matrix m. An exception is thrown if the absolute value of the difference between any pair of off-diagonal elements is larger than max_abs*relative_tolerance, where max_abs is the maximum of the absolute values of the elements of m.
See also: mat3<>::is_symmetric()
| sym_mat3 transpose | ( | ) | [inline] |
Return the transposed matrix.
In analogy with mat3, return a new instance.
| sym_mat3 co_factor_matrix_transposed | ( | ) | const [inline] |
Return the transposed of the co-factor matrix.
The inverse matrix is obtained by dividing the result by the determinant().
Referenced by principal_axes_of_inertia::distance_to_inertia_ellipsoid_surface(), and sym_mat3< scitbx::sym_mat3< double > >::inverse().
| sym_mat3 inverse | ( | ) | const [inline] |
Return the inverse matrix.
An exception is thrown if the matrix is not invertible, i.e. if the determinant() is zero.
| sym_mat3< NumType > antisymmetric_tensor_transform | ( | NumType const & | v0, | |
| NumType const & | v1, | |||
| NumType const & | v2 | |||
| ) | const [inline] |
Antisymmetric tensor transform: c * (*this) * c.transpose().
c is the antisymmetric matrix {{ 0, v0, v1}, {-v0, 0, v2} {-v1, -v2, 0}}
Referenced by sym_mat3< scitbx::sym_mat3< double > >::antisymmetric_tensor_transform().
Antisymmetric tensor transform: c * (*this) * c.transpose().
c is the antisymmetric matrix {{ 0, v[0], v[1]}, {-v[0], 0, v[2]} {-v[1], -v[2], 0 }}
1.5.6