Methods
clone() → {ALMath.Matrix3}
Function clone a matrix.
Returns:
- A copy of this.
- Type
- ALMath.Matrix3
determinant() → {number}
Function to compute the matrix determinant.
Returns:
- The determinant of this.
- Type
- number
divideByScalar(n) → {ALMath.Matrix3}
Function to divide by scalar n.
Parameters:
Name | Type | Description |
---|---|---|
n |
number | Scalar to divide. |
Throws:
Division by zero.
Returns:
- this that is the division between this and scalar n.
- Type
- ALMath.Matrix3
equals() → {boolean}
Function compare two matrices.
Returns:
- true if this and v are equals, false otherwise.
- Type
- boolean
identity()
Function to set this matrix to the identity matrix.
inverse() → {ALMath.Matrix3}
Function to compute matrix inverse.
Throws:
Singular matrix. The matrix hasn't inverse.
Returns:
- this that is the invert matrix.
- Type
- ALMath.Matrix3
multiplyByScalar(n) → {ALMath.Matrix3}
Function to multiply by scalar n.
Parameters:
Name | Type | Description |
---|---|---|
n |
number | Scalar to multiply. |
Returns:
- this that is the multiplication between this and scalar n.
- Type
- ALMath.Matrix3
multiplyByVector(v) → {ALMath.Vector3}
Function to multiply by vector v.
Parameters:
Name | Type | Description |
---|---|---|
v |
ALMath.Vector3 | Vector to multiply. |
Returns:
- A new vector which is the multiplication between the matrix this and the vector v.
- Type
- ALMath.Vector3
set(n11, n12, n13, n21, n22, n23, n31, n32, n33)
Function to set each component.
Set the component in row major order.
Parameters:
Name | Type | Description |
---|---|---|
n11 |
number | component for row 1 column 1. |
n12 |
number | component for row 1 column 2. |
n13 |
number | component for row 1 column 3. |
n21 |
number | component for row 2 column 1. |
n22 |
number | component for row 2 column 2. |
n23 |
number | component for row 2 column 3. |
n31 |
number | component for row 3 column 1. |
n32 |
number | component for row 3 column 2. |
n33 |
number | component for row 3 column 3. |
transpose() → {ALMath.Matrix3}
Function to transpose matrix.
Returns:
- this that is the transpose matrix.
- Type
- ALMath.Matrix3