3x3 matrix class. More...
#include <fMatrix3.h>
Public Member Functions | |
fMat33 () | |
Default constructor. More... | |
fMat33 (const fMat33 &ini) | |
Copy constructor. More... | |
fMat33 (double *ini) | |
Constructor with initial values as array. More... | |
fMat33 (double _m11, double _m12, double _m13, double _m21, double _m22, double _m23, double _m31, double _m32, double _m33) | |
Constructor with all values. More... | |
fMat33 (double d1, double d2, double d3) | |
Constructor with diagonal values. More... | |
fMat33 (double ini) | |
Constructor with the same initial diagonal value. More... | |
double & | operator() (int i, int j) |
The reference to the (i, j)-th element. More... | |
double | operator() (int i, int j) const |
The value of the (i, j)-th element. More... | |
fMat33 | operator= (const fMat33 &mat) |
Assignment operator. More... | |
void | operator= (double d) |
Set the same value to the diagonal elements. More... | |
double | operator[] (int i) const |
Value of the i-th element in the array. More... | |
~fMat33 () | |
Destructor. More... | |
Friends | |
class | fVec3 |
Operators | |
fMat33 | operator- (const fMat33 &mat) |
fMat33 | operator+ (const fMat33 &mat1, const fMat33 &mat2) |
fMat33 | operator- (const fMat33 &mat1, const fMat33 &mat2) |
fMat33 | operator* (double d, const fMat33 &mat) |
fMat33 | operator* (const fMat33 &m1, const fMat33 &m2) |
fVec3 | operator* (const fMat33 &m, const fVec3 &v) |
fMat33 | operator* (const fMat33 &mat, double d) |
fMat33 | operator/ (const fMat33 &mat, double d) |
HRPBASE_EXPORT ostream & | operator<< (ostream &ost, const fMat33 &mat) |
Outputs the elements to a stream. More... | |
fMat33 | tran (const fMat33 &m) |
Returns the transpose. More... | |
double | m11 |
double | m21 |
double | m31 |
double | m12 |
double | m22 |
double | m32 |
double | m13 |
double | m23 |
double | m33 |
double | temp |
int | n_row |
int | n_col |
void | operator+= (const fMat33 &mat) |
void | operator-= (const fMat33 &mat) |
void | operator*= (double d) |
void | operator/= (double d) |
operator double * () | |
Converts to an array. More... | |
double * | data () |
Pointer to the first element. More... | |
void | tran (const fMat33 &) |
Sets the transpose. More... | |
void | cross (const fVec3 &p) |
Sets spectial matrices. More... | |
void | diag (double, double, double) |
Diagonal matrix. More... | |
void | identity () |
Identity matrix. More... | |
void | zero () |
void | set (const fMat33 &mat) |
Copies a matrix. More... | |
void | set (const class fEulerPara &ep) |
Convert from Euler parameter description. More... | |
void | neg (const fMat33 &mat) |
Functions for basic operations. More... | |
void | add (const fMat33 &mat1, const fMat33 &mat2) |
void | add (const fMat33 &mat) |
void | sub (const fMat33 &mat1, const fMat33 &mat2) |
void | mul (const fMat33 &mat1, const fMat33 &mat2) |
void | mul (double d, const fMat33 &mat) |
void | mul (const fMat33 &mat, double d) |
void | div (const fMat33 &mat, double d) |
void | mul (const fVec3 &v1, const fVec3 &v2) |
void | rot2mat (const fVec3 &, double) |
Converts from/to equivalent rotation axis and angle. More... | |
void | mat2rot (fVec3 &, double &) const |
void | ea2mat_xyz (const fVec3 &ea) |
Converts from Euler angles. More... | |
void | ea2mat_xzy (const fVec3 &ea) |
Euler angles to matrix. More... | |
void | ea2mat_zyx (const fVec3 &ea) |
Euler angles to matrix. More... | |
void | ea2mat_yzx (const fVec3 &ea) |
Euler angles to matrix. More... | |
3x3 matrix class.
Definition at line 29 of file fMatrix3.h.
|
inline |
Default constructor.
Creates a 3x3 matrix and initialize as an identity matrix.
Definition at line 37 of file fMatrix3.h.
|
inline |
Constructor with initial values as array.
Constructor with initial values as array of at least 9 elements.
Definition at line 49 of file fMatrix3.h.
|
inline |
Constructor with the same initial diagonal value.
Constructor with initial diagonal values.
Definition at line 61 of file fMatrix3.h.
|
inline |
|
inline |
Constructor with diagonal values.
Constructor with diagonal values.
Definition at line 88 of file fMatrix3.h.
|
inline |
Destructor.
Definition at line 116 of file fMatrix3.h.
Definition at line 668 of file fMatrix3.cpp.
Definition at line 655 of file fMatrix3.cpp.
|
inline |
Pointer to the first element.
Definition at line 158 of file fMatrix3.h.
void fMat33::diag | ( | double | v1, |
double | v2, | ||
double | v3 | ||
) |
Diagonal matrix.
Definition at line 224 of file fMatrix3.cpp.
Definition at line 746 of file fMatrix3.cpp.
Euler angles to matrix.
Definition at line 56 of file fMatrix3.cpp.
Euler angles to matrix.
Definition at line 122 of file fMatrix3.cpp.
Euler angles to matrix.
Definition at line 89 of file fMatrix3.cpp.
void fMat33::identity | ( | ) |
Identity matrix.
Definition at line 230 of file fMatrix3.cpp.
Definition at line 253 of file fMatrix3.cpp.
Definition at line 720 of file fMatrix3.cpp.
Definition at line 694 of file fMatrix3.cpp.
Definition at line 733 of file fMatrix3.cpp.
Definition at line 707 of file fMatrix3.cpp.
Functions for basic operations.
Definition at line 648 of file fMatrix3.cpp.
|
inline |
Converts to an array.
Definition at line 154 of file fMatrix3.h.
The reference to the (i, j)-th element.
Definition at line 517 of file fMatrix3.cpp.
The value of the (i, j)-th element.
Definition at line 529 of file fMatrix3.cpp.
void fMat33::operator*= | ( | double | d | ) |
Definition at line 443 of file fMatrix3.cpp.
Definition at line 417 of file fMatrix3.cpp.
Definition at line 430 of file fMatrix3.cpp.
void fMat33::operator/= | ( | double | d | ) |
Definition at line 450 of file fMatrix3.cpp.
Assignment operator.
Definition at line 380 of file fMatrix3.cpp.
void fMat33::operator= | ( | double | d | ) |
Set the same value to the diagonal elements.
Definition at line 394 of file fMatrix3.cpp.
|
inline |
Value of the i-th element in the array.
Definition at line 125 of file fMatrix3.h.
Converts from/to equivalent rotation axis and angle.
Definition at line 362 of file fMatrix3.cpp.
void fMat33::set | ( | const class fEulerPara & | ep | ) |
Convert from Euler parameter description.
Copies a matrix.
Definition at line 623 of file fMatrix3.cpp.
Definition at line 681 of file fMatrix3.cpp.
void fMat33::zero | ( | ) |
Zero matrix.
Definition at line 236 of file fMatrix3.cpp.
|
friend |
Definition at line 31 of file fMatrix3.h.
Definition at line 565 of file fMatrix3.cpp.
Definition at line 502 of file fMatrix3.cpp.
Definition at line 574 of file fMatrix3.cpp.
Definition at line 487 of file fMatrix3.cpp.
Definition at line 457 of file fMatrix3.cpp.
Definition at line 402 of file fMatrix3.cpp.
Definition at line 472 of file fMatrix3.cpp.
Definition at line 589 of file fMatrix3.cpp.
|
friend |
Outputs the elements to a stream.
Definition at line 974 of file fMatrix3.cpp.
Returns the transpose.
Definition at line 607 of file fMatrix3.cpp.
|
protected |
Definition at line 195 of file fMatrix3.h.
|
protected |
Definition at line 196 of file fMatrix3.h.
|
protected |
Definition at line 197 of file fMatrix3.h.
|
protected |
Definition at line 195 of file fMatrix3.h.
|
protected |
Definition at line 196 of file fMatrix3.h.
|
protected |
Definition at line 197 of file fMatrix3.h.
|
protected |
Definition at line 195 of file fMatrix3.h.
|
protected |
Definition at line 196 of file fMatrix3.h.
|
protected |
Definition at line 197 of file fMatrix3.h.
|
protected |
Definition at line 199 of file fMatrix3.h.
|
protected |
Definition at line 199 of file fMatrix3.h.
|
protected |
Definition at line 198 of file fMatrix3.h.