#include <Matrix3.h>
Inheritance diagram for Matrix3:

Public Methods | |
| virtual std::string | asString () const |
| String representation. | |
| virtual std::string | typeString () const |
| Type representation. | |
| virtual void | serialize (Archive &) |
| Serialize to or from a data archive. | |
| virtual void | parseXML (const char *cdata) |
| Extract the matrix values from XML character data. | |
| Matrix3 () | |
| Default constructor. | |
| Matrix3 (const Matrix3 &other) | |
| Copy constructor. | |
| Matrix3 (double const *const def) | |
| Construct and initialize a matrix from a double[9] array. | |
| Matrix3 (double a00, double a01, double a02, double a10, double a11, double a12, double a20, double a21, double a22) | |
| Matrix3 (const Vector3 &col0, const Vector3 &col1, const Vector3 &col2) | |
| Construct and initialize a matrix from three column vectors. | |
| ~Matrix3 () | |
| Destructor. | |
| int | compare (const Matrix3 &m) const |
| Compare two matrices. | |
| bool | operator== (const Matrix3 &m) const |
| Compare two matrices for (byte) equality. | |
| bool | operator!= (const Matrix3 &m) const |
| Compare two matrices for (byte) inequality. | |
| double & | operator() (int row_, int col_) |
| Get the value (reference) of a matrix element. | |
| double | operator() (int row_, int col_) const |
| Get the (const) value of a matrix element. | |
| double | getElement (int row_, int col_) |
| Get the value of a matrix element. | |
| void | setElement (int row_, int col_, double value) |
| Set the value of a matrix element. | |
| bool | valid () const |
| Return true if all elements are valid floating point numbers. | |
| bool | isNaN () const |
| Return true if any elements are NaN (not-a-number). | |
| Matrix3 & | operator= (const Matrix3 &other) |
| Copy operator. | |
| void | set (const Matrix3 &other) |
| Set this matrix from another matrix. | |
| void | set (double const *const ptr_) |
| Set this matrix from a double[9] array. | |
| void | set (double a00, double a01, double a02, double a10, double a11, double a12, double a20, double a21, double a22) |
| Set this matrix from a list of element values. | |
| std::vector< double > | getElements () const |
| Get the matrix elements as a vector<double>. | |
| void | setElements (std::vector< double > const &v) const |
| Set this matrix from a vector<double>. | |
| Vector3 | getRow (int i) |
| Get a row vector of this matrix. | |
| Vector3 | getCol (int i) |
| Get a column vector of this matrix. | |
| void | setRow (int i, const Vector3 &v) |
| Set a row of this matrix from a vector. | |
| void | setCol (int i, const Vector3 &v) |
| Set a column of this matrix from a vector. | |
| double * | row (int i) |
| Get a pointer to a row of this matrix. | |
| double * | ptr () |
| Get a pointer to the first element of this matrix. | |
| double const * | ptr () const |
| Get a const pointer to the first element of this matrix. | |
| void | makeIdentity () |
| Set this matrix equal to the identity matrix. | |
| void | makeZero () |
| Set all matrix elements to zero. | |
| void | makeScale (const Vector3 &v) |
| Set this matrix to a scaling matrix. | |
| void | makeScale (double, double, double) |
| Set this matrix to a scaling matrix. | |
| void | makeRotate (const Vector3 &from, const Vector3 &to) |
| Make a rotation matrix to transform one vector into another. | |
| void | makeRotate (double angle, const Vector3 &axis) |
| Make a rotation matrix to rotate around a given axis. | |
| void | makeRotate (double angle, double x, double y, double z) |
| Make a rotation matrix to rotate around a given axis. | |
| void | makeRotate (const Quat &) |
| Make a rotation matrix from a quaternion. | |
| void | makeRotate (double roll, double pitch, double yaw) |
| Make a rotation matrix from euler angles. | |
| void | makeRotate (double angle1, const Vector3 &axis1, double angle2, const Vector3 &axis2, double angle3, const Vector3 &axis3) |
| Make a rotation from combining three rotations. | |
| bool | invert (const Matrix3 &m, double tolerance=1e-12) |
| Construct the inverse of a matrix. | |
| bool | invert (double tolerance=1e-12) |
| Invert this matrix. | |
| void | transpose (const Matrix3 &other) |
| Construct the transpose of a matrix. | |
| void | transpose () |
| Transpose this matrix. | |
| Matrix3 | getInverse (double tolerance=1e-12) const |
| Get the inverse of this matrix. | |
| Matrix3 | getTranspose () const |
| Get the transpose of this matrix. | |
| double | determinant () const |
| Compute the determinant of this matrix. | |
| void | getRotate (double angle, Vector3 &axis) const |
| Get the rotation angle and axis of this matrix. | |
| void | getEulerAngles (double &roll, double &pitch, double &yaw) |
| Get the Euler angles of this matrix. | |
| Vector3 | preMult (const Vector3 &v) const |
| Multiply this matrix by a row vector (v*M). | |
| Vector3 | postMult (const Vector3 &v) const |
| Multiply this matrix by a column vector (M*v). | |
| Vector3 | operator * (const Vector3 &v) const |
| Multiply this matrix by a column vector (M*v). | |
| Vector3 | getScale () const |
| Get the diagonal elements of this matrix as a vector. | |
| double | getTrace () const |
| Get the trace of this matrix. | |
| void | mult (const Matrix3 &, const Matrix3 &) |
| Matrix multipliation (M*M). | |
| void | preMult (const Matrix3 &) |
| Multiply this matrix by another matrix on the left. | |
| void | postMult (const Matrix3 &) |
| Multiply this matrix by another matrix on the right. | |
| void | operator *= (const Matrix3 &other) |
| Multiply this matrix by another matrix on the right. | |
| Matrix3 | operator * (const Matrix3 &m) const |
| Get the product of this matrix and another matrix. | |
| const Matrix3 & | operator+= (const Matrix3 &rhs) |
| Add another matrix to this matrix. | |
| const Matrix3 & | operator-= (const Matrix3 &rhs) |
| Subtract another matrix from this matrix. | |
| const Matrix3 & | operator *= (const double rhs) |
| Multiply this matrix by a scalar. | |
| const Matrix3 & | operator/= (const double rhs) |
| Divide this matrix by a scalar. | |
| Matrix3 | operator+ (const Matrix3 &rhs) const |
| Get the sum of this matrix and another matrix. | |
| Matrix3 | operator- (const Matrix3 &rhs) const |
| Get the difference of this matrix and another matrix. | |
| Matrix3 | operator * (double rhs) const |
| Get the product of this matrix and a scalar. | |
| Matrix3 | operator/ (double rhs) const |
| Get the quotient of this matrix and a scalar. | |
| Matrix3 | operator- () const |
| Get this matrix with each element negated. | |
| virtual void | convertXML () |
| Convert XML data to internal format prior to serialization. | |
Static Public Methods | |
| Matrix3 const & | identity (void) |
| Create a new identity matrix. | |
| Matrix3 | scale (const Vector3 &sv) |
| Create a new scaling matrix. | |
| Matrix3 | scale (double sx, double sy, double sz) |
| Create a new scaling matrix. | |
| Matrix3 | rotate (const Vector3 &from, const Vector3 &to) |
| Create a new rotation matrix. | |
| Matrix3 | rotate (double angle, double x, double y, double z) |
| Create a new rotation matrix. | |
| Matrix3 | rotate (double angle, const Vector3 &axis) |
| Create a new rotation matrix. | |
| Matrix3 | rotate (double angle1, const Vector3 &axis1, double angle2, const Vector3 &axis2, double angle3, const Vector3 &axis3) |
| Create a new rotation matrix. | |
| Matrix3 | rotate (double roll, double pitch, double yaw) |
| Create a new rotation matrix. | |
| Matrix3 | rotate (const Quat &quat) |
| Create a new rotation matrix. | |
| Matrix3 | inverse (const Matrix3 &matrix, double tolerance=1e-12) |
| Get the inverse of a matrix. | |
| Matrix3 | tensor (const Vector3 &a, const Vector3 &b) |
| Get the tensor product of two vectors. | |
Static Public Attributes | |
| const Matrix3 | ZERO |
| Null matrix. | |
| const Matrix3 | IDENTITY |
| Identity matrix. | |
Protected Attributes | |
| double | _mat [3][3] |
| The matrix elements. | |
Friends | |
| Vector3 | operator * (const Vector3 &v, const Matrix3 &m) |
| Multiply a matrix by a row vector (v*M). | |
| Matrix3 | operator * (double lhs, const Matrix3 &rhs) |
| Multiply a matrix by a scalar on the left (s*M). | |
| SIMDATA_EXPORT std::ostream & | operator<< (std::ostream &os, const Matrix3 &m) |
| Format this matrix for an output stream. | |
|
|
Default constructor.
|
|
|
Copy constructor.
|
|
|
Construct and initialize a matrix from a double[9] array.
|
|
||||||||||||||||||||||||||||||||||||||||
|
|
|
||||||||||||||||
|
Construct and initialize a matrix from three column vectors.
|
|
|
Destructor.
|
|
|
String representation.
Implements BaseType. |
|
|
Compare two matrices. Compares two matrices byte-by-byte. The sign of the return value is useless, since the byte comparisons are inequivalent to floating point comparisions. Used only to test for equality.
|
|
|
Convert XML data to internal format prior to serialization. This method is currently only called by the XML parser for Object classes. If another BaseType class requires this method, a call must be added to the appropriate XML handler in the parser. |
|
|
Compute the determinant of this matrix.
|
|
|
Get a column vector of this matrix.
|
|
||||||||||||
|
Get the value of a matrix element.
|
|
|
Get the matrix elements as a vector<double>.
|
|
||||||||||||||||
|
Get the Euler angles of this matrix.
|
|
|
Get the inverse of this matrix. See invert(double). |
|
||||||||||||
|
Get the rotation angle and axis of this matrix.
|
|
|
Get a row vector of this matrix.
|
|
|
Get the diagonal elements of this matrix as a vector.
|
|
|
Get the trace of this matrix.
|
|
|
Get the transpose of this matrix.
|
|
|
Create a new identity matrix.
|
|
||||||||||||
|
Get the inverse of a matrix.
|
|
|
Invert this matrix.
|
|
||||||||||||
|
Construct the inverse of a matrix.
|
|
|
Return true if any elements are NaN (not-a-number).
|
|
|
Set this matrix equal to the identity matrix.
|
|
||||||||||||||||||||||||||||
|
Make a rotation from combining three rotations.
|
|
||||||||||||||||
|
Make a rotation matrix from euler angles.
|
|
|
Make a rotation matrix from a quaternion.
|
|
||||||||||||||||||||
|
Make a rotation matrix to rotate around a given axis. |
|
||||||||||||
|
Make a rotation matrix to rotate around a given axis.
|
|
||||||||||||
|
Make a rotation matrix to transform one vector into another.
The resulting matrix will rotate the |
|
||||||||||||||||
|
Set this matrix to a scaling matrix. |
|
|
Set this matrix to a scaling matrix. The resulting matrix has the components of the input vector along the diagonal, with all off-diagonal elements equal to zero.
|
|
|
Set all matrix elements to zero.
|
|
||||||||||||
|
Matrix multipliation (M*M).
|
|
|
Get the product of this matrix and a scalar.
|
|
|
Get the product of this matrix and another matrix.
|
|
|
Multiply this matrix by a column vector (M*v).
|
|
|
Multiply this matrix by a scalar.
|
|
|
Multiply this matrix by another matrix on the right.
|
|
|
Compare two matrices for (byte) inequality.
|
|
||||||||||||
|
Get the (const) value of a matrix element.
|
|
||||||||||||
|
Get the value (reference) of a matrix element.
|
|
|
Get the sum of this matrix and another matrix.
|
|
|
Add another matrix to this matrix.
|
|
|
Get this matrix with each element negated.
|
|
|
Get the difference of this matrix and another matrix.
|
|
|
Subtract another matrix from this matrix.
|
|
|
Get the quotient of this matrix and a scalar.
|
|
|
Divide this matrix by a scalar.
|
|
|
Copy operator.
|
|
|
Compare two matrices for (byte) equality.
|
|
|
Extract the matrix values from XML character data. The nine values should be separated by white-space and arranged in order (0,0), (0,1), (0,2), (1,0), etc. Reimplemented from BaseType. |
|
|
Multiply this matrix by another matrix on the right.
|
|
|
Multiply this matrix by a column vector (M*v).
|
|
|
Multiply this matrix by another matrix on the left.
|
|
|
Multiply this matrix by a row vector (v*M).
|
|
|
Get a const pointer to the first element of this matrix.
|
|
|
Get a pointer to the first element of this matrix.
|
|
|
Create a new rotation matrix.
|
|
||||||||||||||||
|
Create a new rotation matrix.
|
|
||||||||||||||||||||||||||||
|
Create a new rotation matrix.
|
|
||||||||||||
|
Create a new rotation matrix.
|
|
||||||||||||||||||||
|
Create a new rotation matrix.
|
|
||||||||||||
|
Create a new rotation matrix.
|
|
|
Get a pointer to a row of this matrix.
|
|
||||||||||||||||
|
Create a new scaling matrix.
|
|
|
Create a new scaling matrix.
|
|
|
Serialize to or from a data archive.
Reimplemented from BaseType. |
|
||||||||||||||||||||||||||||||||||||||||
|
Set this matrix from a list of element values.
|
|
|
Set this matrix from a double[9] array.
|
|
|
Set this matrix from another matrix.
|
|
||||||||||||
|
Set a column of this matrix from a vector.
|
|
||||||||||||||||
|
Set the value of a matrix element.
|
|
|
Set this matrix from a vector<double>.
|
|
||||||||||||
|
Set a row of this matrix from a vector.
|
|
||||||||||||
|
Get the tensor product of two vectors.
|
|
|
Transpose this matrix.
|
|
|
Construct the transpose of a matrix.
|
|
|
Type representation.
Implements BaseType. |
|
|
Return true if all elements are valid floating point numbers.
|
|
||||||||||||
|
Multiply a matrix by a scalar on the left (s*M).
|
|
||||||||||||
|
Multiply a matrix by a row vector (v*M).
|
|
||||||||||||
|
Format this matrix for an output stream.
|
|
|
The matrix elements.
|
|
|
Identity matrix.
|
|
|
Null matrix.
|
|
SimData version pre-0.4.0. For more information on SimData, visit the SimData Homepage. Generated on Tue Oct 14 12:06:41 2003, using Doxygen 1.2.18. |