#include <SIBCMatrix33d.h>
Inheritance diagram for CSIBCMatrix33d:

Public Member Functions |
|
| CSIBCMatrix33d (void) | |
| CSIBCMatrix33d (const CSIBCVector3Dd &in_vct0, const CSIBCVector3Dd &in_vct1, const CSIBCVector3Dd &in_vct2, const bool in_bAreRows=true) | |
| CSIBCMatrix33d (const double in_dA00, const double in_dA01, const double in_dA02, const double in_dA10, const double in_dA11, const double in_dA12, const double in_dA20, const double in_dA21, const double in_dA22) | |
| CSIBCMatrix33d (int in_nRow, int in_nCol, const CSIBCMatrix44d &in_mat) | |
| double | Get (const int in_nRow, const int in_nCol) const |
| CSIBCMatrix33d & | Set (int in_nRow, int in_nCol, const double in_dVal) |
| CSIBCMatrix33d & | Set (const double in_dA00, const double in_dA01, const double in_dA02, const double in_dA10, const double in_dA11, const double in_dA12, const double in_dA20, const double in_dA21, const double in_dA22) |
| CSIBCMatrix33d & | Set (double in_dVal[3][3]) |
| CSIBCMatrix33d & | Set (const CSIBCMatrix33d &in_mat) |
| CSIBCMatrix33d & | Set (int in_nRow, int in_nCol, const CSIBCMatrix44d &in_mat) |
| CSIBCMatrix33d & | SetRow (const int in_nRow, const CSIBCVector3Dd &in_vct) |
| CSIBCMatrix33d & | SetRow (const int in_nRow, double in_dA0, double in_dA1, double in_dA2) |
| CSIBCMatrix33d & | SetCol (const int in_nCol, const CSIBCVector3Dd &in_vct) |
| CSIBCMatrix33d & | SetCol (const int in_nCol, double in_dA0, double in_dA1, double in_dA2) |
| CSIBCMatrix33d & | SetNull () |
| CSIBCMatrix33d & | SetIdentity () |
| bool | operator== (const CSIBCMatrix33d &in_mat) const |
| bool | operator!= (const CSIBCMatrix33d &in_mat) const |
| bool | IsNull (const double in_dEpsilon=PICO_EPS) const |
| bool | IsSingular (const double in_dEpsilon=PICO_EPS) const |
| bool | IsSymmetric (const double in_dEpsilon=PICO_EPS) const |
| CSIBCMatrix33d & | Add (const CSIBCMatrix33d &in_mat1, const CSIBCMatrix33d &in_mat2) |
| CSIBCMatrix33d & | Add (const CSIBCMatrix33d &in_mat) |
| CSIBCMatrix33d & | Sub (const CSIBCMatrix33d &in_mat1, const CSIBCMatrix33d &in_mat2) |
| CSIBCMatrix33d & | Sub (const CSIBCMatrix33d &in_mat) |
| CSIBCMatrix33d & | Mul (const CSIBCMatrix33d &in_mat1, const CSIBCMatrix33d &in_mat2) |
| CSIBCMatrix33d & | Mul (const CSIBCMatrix33d &in_mat) |
| CSIBCMatrix33d & | MulTransByReg (const CSIBCMatrix33d &in_mat1, const CSIBCMatrix33d &in_mat2) |
| CSIBCMatrix33d & | MulRegByTrans (const CSIBCMatrix33d &in_mat1, const CSIBCMatrix33d &in_mat2) |
| CSIBCMatrix33d & | Negate (const CSIBCMatrix33d &in_mat) |
| CSIBCMatrix33d & | Negate () |
| CSIBCMatrix33d & | Mul (const double in_dFactor, const CSIBCMatrix33d &in_mat) |
| CSIBCMatrix33d & | Mul (const CSIBCMatrix33d &in_mat, const double in_dFactor) |
| CSIBCMatrix33d & | Mul (const double in_dFactor) |
| CSIBCMatrix33d & | Div (const CSIBCMatrix33d &in_mat, const double in_dFactor) |
| CSIBCMatrix33d & | Div (const double in_dFactor) |
| double | GetDet (void) const |
| double | GetTrace (void) const |
| CSIBCMatrix33d & | Transpose (const CSIBCMatrix33d &in_mat) |
| CSIBCMatrix33d & | Transpose (void) |
| bool | Invert (const CSIBCMatrix33d &in_mat) |
| bool | Invert (void) |
| bool | TransposeInverse (const CSIBCMatrix33d &in_mat) |
| bool | TransposeInverse (void) |
| CSIBCMatrix33d & | Adjoint (const CSIBCMatrix33d &in_mat) |
| CSIBCMatrix33d & | Adjoint (void) |
| bool | GetEigenVectors (CSIBCMatrix33d &out_matEigenVectors, CSIBCVector3Dd &out_vctEigenValues, const double in_dEps=PICO_EPS) const |
| CSIBCMatrix33d & | Symmetry (CSIBCMatrix33d &in_mat) const |
| CSIBCMatrix33d & | Symmetry (void) const |
| void | SetOuterProduct (const CSIBCVector3Dd &in_vct1, const CSIBCVector3Dd &in_vct2) |
Friends |
|
| bool | AreAlmostEqual (const CSIBCMatrix33d &in_mat1, const CSIBCMatrix33d &in_mat2, const double in_dEpsilon=PICO_EPS) |
CSIBCMatrix33d objects represent matricies, and define a set of operations which are useful in the context of a matrix. Unlike CSIBCMatrix4x4, there is no method of accessing the matrix data directly, thus it does not matter whether the values are stored in column major, or row major order.
This class uses double precision floating point numbers to store element values. There exists three other matrix classes, CSIBCMatrix44d, CSIBCMatrix4x4 and CSIBCMatrixMNd. They are used to represent 4x4 matricies with double precision floating-point numbers, 4x4 matricies with single precision floating-point numbers, and MxN matricies with double precision floating-point numbers, respectively.
| CSIBCMatrix33d | ( | void | ) |
Default Constructor. Sets all elements in the matrix to zero.
| CSIBCMatrix33d | ( | const CSIBCVector3Dd & | in_vct0, | |
| const CSIBCVector3Dd & | in_vct1, | |||
| const CSIBCVector3Dd & | in_vct2, | |||
| const bool | in_bAreRows = true |
|||
| ) |
Constructor. Sets the rows of the new matrix to be in_vct0, in_vct1, and in_vct2. If in_bAreRows is false, then the input vectors are used as the columns of the new matrix.
| in_vct0 | The vector to use for the first row (or column) of the matrix. | |
| in_vct1 | The vector to use for the second row (or column) of the matrix. | |
| in_vct2 | The vector to use for the third row (or column) of the matrix. | |
| in_bAreRows | Whether the vectors given represent rows or columns of the matrix (true == Rows, false == Columns). Defaults to true (rows). |
| CSIBCMatrix33d | ( | const double | in_dA00, | |
| const double | in_dA01, | |||
| const double | in_dA02, | |||
| const double | in_dA10, | |||
| const double | in_dA11, | |||
| const double | in_dA12, | |||
| const double | in_dA20, | |||
| const double | in_dA21, | |||
| const double | in_dA22 | |||
| ) |
Constructor. Specifies the value of each element in the new matrix.
| in_dA00 | The value for the element in row 1, column 1. | |
| in_dA01 | The value for the element in row 1, column 2 | |
| in_dA02 | The value for the element in row 1, column 3 | |
| in_dA10 | The value for the element in row 2, column 1. | |
| in_dA11 | The value for the element in row 2, column 2 | |
| in_dA12 | The value for the element in row 2, column 3 | |
| in_dA20 | The value for the element in row 3, column 1. | |
| in_dA21 | The value for the element in row 3, column 2 | |
| in_dA22 | The value for the element in row 3, column 3 |
| CSIBCMatrix33d | ( | int | in_nRow, | |
| int | in_nCol, | |||
| const CSIBCMatrix44d & | in_mat | |||
| ) |
Constructor. Creates a 3x3 matrix from a 4x4 matrix, in_mat, by removing the column and row from in_mat specified by in_nRow, and in_nCol.
| in_nRow | The row to remove from in_mat (zero indexed). |
|
| in_nCol | The column to remove from in_mat (zero indexed). |
|
| in_mat | The 4x4 matrix to remove a row and a column from to produce the new matrix. |
| double Get | ( | const int | in_nRow, | |
| const int | in_nCol | |||
| ) | const |
Returns an element of the marix.
| in_nRow | Row index of the element to retrieve (zero indexed). | |
| in_nCol | Column index of the element to retrieve (zero indexed). |
Reimplemented in CSIBCRotMatd.
Sets an element of the matrix.
| in_nRow | Row index of the element to set (zero indexed). | |
| in_nCol | Column index of the element to set (zero indexed). | |
| in_dVal | Value for the element. |
Reimplemented in CSIBCRotMatd.
| CSIBCMatrix33d& Set | ( | const double | in_dA00, | |
| const double | in_dA01, | |||
| const double | in_dA02, | |||
| const double | in_dA10, | |||
| const double | in_dA11, | |||
| const double | in_dA12, | |||
| const double | in_dA20, | |||
| const double | in_dA21, | |||
| const double | in_dA22 | |||
| ) |
Sets all elements of the matrix.
| in_dA00 | The value for the element in row 1, column 1. | |
| in_dA01 | The value for the element in row 1, column 2. | |
| in_dA02 | The value for the element in row 1, column 3. | |
| in_dA10 | The value for the element in row 2, column 1. | |
| in_dA11 | The value for the element in row 2, column 2. | |
| in_dA12 | The value for the element in row 2, column 3. | |
| in_dA20 | The value for the element in row 3, column 1. | |
| in_dA21 | The value for the element in row 3, column 2. | |
| in_dA22 | The value for the element in row 3, column 3. |
| CSIBCMatrix33d& Set | ( | double | in_dVal[3][3] | ) |
Sets all elements of the matrix.
| in_dVal | 3x3 array of double values, containing the new values for all the matrix elements. |
Reimplemented in CSIBCRotMatd.
| CSIBCMatrix33d& Set | ( | const CSIBCMatrix33d & | in_mat | ) |
Sets all elements of the matrix to those contained in in_mat.
| in_mat | Matrix to copy all element values from. |
Reimplemented in CSIBCRotMatd.
| CSIBCMatrix33d& Set | ( | int | in_nRow, | |
| int | in_nCol, | |||
| const CSIBCMatrix44d & | in_mat | |||
| ) |
Sets all elements of this matrix to be a submatrix of in_mat.
| in_nRow | Row index of the row to remove from in_mat (zero indexed). |
|
| in_nCol | Column index of the column to remove from in_mat (zero indexed). |
|
| in_mat | The matrix to use element values from (with column in_nCol and row in_nRow removed). |
Sets all elements in a row of the matrix.
| in_nRow | Row index of the row to set (zero indexed). | |
| in_vct | Vector containing the values to replace the specified row elements with. |
Reimplemented in CSIBCRotMatd.
| CSIBCMatrix33d& SetRow | ( | const int | in_nRow, | |
| double | in_dA0, | |||
| double | in_dA1, | |||
| double | in_dA2 | |||
| ) |
Sets all elements in a row of the matrix.
| in_nRow | Row index of the row to set (zero indexed). | |
| in_dA0 | Value for the element in the first column of the row. | |
| in_dA1 | Value for the element in the second column of the row. | |
| in_dA2 | Value for the element in the third column of the row. |
Reimplemented in CSIBCRotMatd.
Sets all elements in a column of the matrix.
| in_nCol | Column index of the column to set (zero indexed). | |
| in_vct | Vector containing the values to replace the specified column elements with. |
Reimplemented in CSIBCRotMatd.
| CSIBCMatrix33d& SetCol | ( | const int | in_nCol, | |
| double | in_dA0, | |||
| double | in_dA1, | |||
| double | in_dA2 | |||
| ) |
Sets all elements in a column of the matrix.
| in_nCol | Column index of the column to set (zero indexed). | |
| in_dA0 | Value for the element in the first row of the column. | |
| in_dA1 | Value for the element in the second row of the column. | |
| in_dA2 | Value for the element in the third row of the column. |
Reimplemented in CSIBCRotMatd.
Sets all elements in the matrix to zero.
Reimplemented in CSIBCRotMatd.
Sets this matrix to be the identity matrix.
Reimplemented in CSIBCRotMatd.
Determines whether all corresponding elements of this matrix and in_mat are exactly equal.
| in_mat | The matrix to compare equality with. |
Reimplemented in CSIBCRotMatd.
Determines whether any corresponding elements of this matrix and in_mat are different.
| in_mat | The matrix to compare inequality with. |
Reimplemented in CSIBCRotMatd.
Determines whether all elements of this matrix are zero. Since this function uses floating-point comparison, a threshhold value of in_dEpsilon is used for equality comparison.
| in_dEpsilon | Floating-point comparison error range. Defaults to PICO_EPS |
Determines whether the matrix is singular. A singular matrix is a square matrix that has no inverse. A matrix is singular iff it has a determinant of zero. Since this function uses floating-point comparison (for the determinant value), a threshhold value of in_dEpsilon is used for equality comparison.
| in_dEpsilon | Floating-point comparison error range. Defaults to PICO_EPS |
Determines whether the matrix is symmetric. A symmetric matrix is one that is equal to its transpose. Since this function uses floating-point comparison, a threshhold value of in_dEpsilon is used for equality comparison.
| in_dEpsilon | Floating-point comparison error range. Defaults to PICO_EPS |
Computes the matrix addition of two matricies, and stores the result in this matrix.
| in_mat1 | The first matrix to add. | |
| in_mat2 | The second matrix to add. |
| CSIBCMatrix33d& Add | ( | const CSIBCMatrix33d & | in_mat | ) |
Computes the matrix addition of this matrix and in_mat, and stores the result in this matrix.
| in_mat | The matrix to add to this matrix. |
Computes the difference of two matricies (in_mat1 - in_mat2) and stores the result in this matrix.
| in_mat1 | The matrix to subtract from. | |
| in_mat2 | The matrix to subtract. |
| CSIBCMatrix33d& Sub | ( | const CSIBCMatrix33d & | in_mat | ) |
Computes the difference of this matrix and in_mat2 (this - in_mat) and stores the result in this matrix.
| in_mat | The matrix to subtract. |
Computes the matrix multiplication of two matricies (in_mat1 * in_mat2) and stores the result in this matrix.
| in_mat1 | The first matrix in the multiplication (on the left). | |
| in_mat2 | The second matrix in the multiplication (on the right). |
| CSIBCMatrix33d& Mul | ( | const CSIBCMatrix33d & | in_mat | ) |
Computes the matrix multiplication of this matrix and in_mat (this * in_mat) and stores the result in this matrix.
| in_mat | The matrix to right-multiply this matrix by. |
Computes the matrix multiplication of the transpose of in_mat1 and in_mat2 (in_mat1^T * in_mat2) and stores the result in this matrix.
| in_mat1 | The first matrix in the multiplication (on the left), to be transposed before multiplication. | |
| in_mat2 | The second matrix in the multiplication (on the right). |
Computes the matrix multiplication of in_mat1 and the transpose of in_mat2 (in_mat1 * in_mat2^T) and stores the result in this matrix.
| in_mat1 | The first matrix in the multiplication (on the left). | |
| in_mat2 | The second matrix in the multiplication (on the right), to be transposed before multiplication. |
Sets this matrix to the negative of in_mat. The 'negative' of a matrix is produced by multiplying each element of the matrix by -1.
| in_mat | Matrix containing the data to set this matrix to the negative of. |
| CSIBCMatrix33d& Negate | ( | ) |
Sets this matrix to its negative. The 'negative' of a matrix is produced by multiplying each element of the matrix by -1.
Reimplemented in CSIBCRotMatd.
| CSIBCMatrix33d& Mul | ( | const double | in_dFactor, | |
| const CSIBCMatrix33d & | in_mat | |||
| ) |
Scales each element of in_mat by in_dFactor, and assigns the result to the corresponding element in this matrix.
| in_dFactor | Scaling factor for elements of in_mat |
|
| in_mat | The input matrix, to scale and assign to this matrix. |
| CSIBCMatrix33d& Mul | ( | const CSIBCMatrix33d & | in_mat, | |
| const double | in_dFactor | |||
| ) |
Scales each element of in_mat by in_dFactor, and assigns the result to the corresponding element in this matrix.
| in_mat | The input matrix, to scale and assign to this matrix. | |
| in_dFactor | Scaling factor for elements of in_mat |
| CSIBCMatrix33d& Mul | ( | const double | in_dFactor | ) |
Scales each component of this matrix by in_dFactor
| in_dFactor | Scaling factor for elements in this matrix |
Divides each component of in_mat by in_dFactor and assigns the result to the corresponding element in this matrix.
| in_mat | The input matrix, to divide and assign to this matrix. | |
| in_dFactor | Dividing factor for elements of in_mat |
| CSIBCMatrix33d& Div | ( | const double | in_dFactor | ) |
Divides each component of this matrix by in_dFactor.
| in_dFactor | Dividing factor for elements of this matrix. |
Computes the determinant of this matrix.
Reimplemented in CSIBCRotMatd.
Computes the trace of this matrix. A trace is the sum of all the diagonal elements of a matrix.
Reimplemented in CSIBCRotMatd.
Sets this matrix to be the transpose of in_mat.
| in_mat | Matrix containing the transpose of the desired matrix. |
| CSIBCMatrix33d& Transpose | ( | void | ) |
Sets this matrix to its transpose.
Reimplemented in CSIBCRotMatd.
Sets this matrix to be the inverse of in_mat.
| in_mat | Matrix containing the inverse of the desired matrix. |
in_mat could be inverted and the assignment was successful, false otherwise. | bool Invert | ( | void | ) |
Sets this matrix to its inverse.
Reimplemented in CSIBCRotMatd.
Sets this matrix to the transpose of the inverse of in_mat.
| in_mat | Matrix containing the transpose of the inverse of the desired matrix. |
| bool TransposeInverse | ( | void | ) |
Sets this matrix to the transpose of the inverse of itself.
CSIBCMatrix33d::Inverse
Sets this matrix to the adjoint of in_mat.
| in_mat | Matrix containing the adjoint of the desired matrix. |
| CSIBCMatrix33d& Adjoint | ( | void | ) |
Sets this matrix to its adjoint.
| bool GetEigenVectors | ( | CSIBCMatrix33d & | out_matEigenVectors, | |
| CSIBCVector3Dd & | out_vctEigenValues, | |||
| const double | in_dEps = PICO_EPS |
|||
| ) | const |
Computes the eigenvectors and eigenvalues of this matrix. Since this method uses floating-point comparison, a threshhold value of in_dEps is used for equality comparison.
| out_matEigenVector | Matrix whose rows represent the eigenvectors of this matrix. | |
| out_vctEigenValues | Vector whose components represent the eigenvalues of the corresponding eigenvectors in out_matEigenVector. |
|
| in_dEps | Floating-point comparison error range. Defaults to PICO_EPS |
Not implemented yet
| CSIBCMatrix33d& Symmetry | ( | void | ) | const |
Not implemented yet
Not implemented yet
| bool AreAlmostEqual | ( | const CSIBCMatrix33d & | in_mat1, | |
| const CSIBCMatrix33d & | in_mat2, | |||
| const double | in_dEpsilon = PICO_EPS |
|||
| ) | [friend] |
Determines whether all corresponding elements of the matricies in_mat1 and in_mat2 are equal. Since this method uses floating-point comparison, a threshhold value of in_dEpsilon is used for equality comparison.
| in_mat1 | First matrix for equality comparison. | |
| in_mat2 | Second matrix for equality comparison. | |
| in_dEpsilon | Floating-point comparison error range. Defaults to PICO_EPS. |