public class R3x3 extends SquareMatrix<R3x3> implements java.io.Serializable
Represents an element of R3×3, the set of real, 3×3 matrices. The class also contains the usual set of matrix operations and linear transforms on R3 induced by the matrix.
gov.sns.tools.r3.R3,
Serialized Form| Modifier and Type | Class and Description |
|---|---|
static class |
R3x3.IND
Class
R3x3.IND is an enumeration of the matrix indices
for the R3x3 class. |
static class |
R3x3.POS
Enumeration for the element positions of an
R3x3 matrix element. |
| Modifier and Type | Field and Description |
|---|---|
static int |
INT_SIZE
number of dimensions (DIM=3)
|
ATTR_DATA, matImpl| Constructor and Description |
|---|
R3x3()
Creates a new instance of R3x3 initialized to zero.
|
R3x3(double[][] arrValues)
Initializing constructor for class
R3x3. |
R3x3(R3x3 matInit)
Copy Constructor - create a deep copy of the target matrix.
|
R3x3(java.lang.String strTokens)
Parsing Constructor - create a R3x3 instance and initialize it
according to a token string of element values.
|
| Modifier and Type | Method and Description |
|---|---|
R3x3 |
clone()
Creates and returns a deep copy of this matrix.
|
static R3x3 |
copy(R3x3 matTarget)
Create a deep copy of the given
R3x3 matrix object. |
double |
getElem(R3x3.POS pos)
Return matrix element value.
|
static R3x3 |
newIdentity()
Create a new instance of the identity matrix
|
protected R3x3 |
newInstance()
Handles object creation required by the base class.
|
static R3x3 |
newRotationX(double dblAng)
Create and return the generator element of SO(3) which is
a counter-clockwise rotation about the x axis.
|
static R3x3 |
newRotationY(double dblAng)
Create and return the generator element of SO(3) which is
a counter-clockwise rotation about the y axis.
|
static R3x3 |
newRotationZ(double dblAng)
Create and return the generator element of SO(3) which is
a counter-clockwise rotation about the z axis.
|
static R3x3 |
newZero()
Create a new instance of a zero matrix.
|
static R3x3 |
parse(java.lang.String strTokens)
Create a R3x3 instance and initialize it
according to a token string of element values.
|
void |
setElem(R3x3.IND i,
R3x3.IND j,
double s)
Element assignment - assigns matrix element to the specified value
|
void |
setElem(R3x3.POS pos,
double val)
Set the element specified by the position in the argument to the
new value in the second argument.
|
R3 |
times(R3 vec)
Nondestructive Matrix-Vector multiplication.
|
assignIdentity, conjugateInv, conjugateTrans, det, getSize, inverse, isEquivalentTo, isSymmetric, setElem, solve, solveInPlace, times, times, times, timesEquals, timesEquals, transposeassignMatrix, assignZero, conditionNumber, copy, equals, getArrayCopy, getColCnt, getElem, getElem, getMatrix, getRowCnt, hashCode, load, max, minus, minusEquals, newInstance, norm1, norm2, normF, normInf, plus, plusEquals, print, save, setElem, setMatrix, setMatrix, setSubMatrix, toString, toStringMatrix, toStringMatrix, toStringMatrixpublic static final int INT_SIZE
public R3x3()
public R3x3(R3x3 matInit)
matInit - initial valuepublic R3x3(double[][] arrValues)
throws java.lang.ArrayIndexOutOfBoundsException
R3x3. The values of the
new matrix are set to the given Java primitive type array (the array
itself is unchanged). The dimensions of the argument must be
3×3.arrValues - initial values for the new matrix objectjava.lang.ArrayIndexOutOfBoundsException - the argument must have the dimensions 3×3public R3x3(java.lang.String strTokens)
throws java.lang.IllegalArgumentException,
java.lang.NumberFormatException
strTokens - token vector of 3x3=9 numeric valuesjava.lang.IllegalArgumentException - wrong number of token stringsjava.lang.NumberFormatException - bad number format, unparseablepublic static R3x3 newZero()
public static R3x3 newIdentity()
public static R3x3 newRotationX(double dblAng)
rotation - angle in radianspublic static R3x3 newRotationY(double dblAng)
rotation - angle in radianspublic static R3x3 newRotationZ(double dblAng)
rotation - angle in radianspublic static R3x3 copy(R3x3 matTarget)
R3x3 matrix object. The returned
object is completely decoupled from the original.matTarget - matrix to be copiedpublic static R3x3 parse(java.lang.String strTokens) throws java.lang.IllegalArgumentException, java.lang.NumberFormatException
strTokens - token vector of 3x3=9 numeric valuesjava.lang.IllegalArgumentException - wrong number of token stringsjava.lang.NumberFormatException - bad number format, unparseablepublic R3x3 clone()
clone in class BaseMatrix<R3x3>BaseMatrix.clone()public void setElem(R3x3.IND i, R3x3.IND j, double s) throws java.lang.ArrayIndexOutOfBoundsException
i - row indexj - column indexjava.lang.ArrayIndexOutOfBoundsException - index must be in {0,1,2}public void setElem(R3x3.POS pos, double val)
pos - matrix positionval - new element valuepublic double getElem(R3x3.POS pos)
i - row indexj - column indexprotected R3x3 newInstance()
newInstance in class BaseMatrix<R3x3>MBaseMatrix.newInstance()