VR-Link JAVA API Documentation
 All Classes Namespaces Files Functions Variables Enumerator Pages
List of all members | Public Member Functions | Static Public Attributes | Private Attributes | Static Private Attributes
com.mak.vrlj.math.Matrix3d Class Reference

A 3x3 matrix. More...

+ Inheritance diagram for com.mak.vrlj.math.Matrix3d:
+ Collaboration diagram for com.mak.vrlj.math.Matrix3d:

Public Member Functions

 Matrix3d ()
 No-arg constructor.
 Matrix3d (ConstMatrix3d original)
 Copy constructor.
 Matrix3d (double r1c1, double r1c2, double r1c3, double r2c1, double r2c2, double r2c3, double r3c1, double r3c2, double r3c3)
 Construct a matrix from primitive elements.
void assignFrom (ConstMatrix3d other)
 Assign element values for this matrix from another.
boolean equals (Object obj)
double get (int r, int c)
 Get the value of a matrix element by row and column.
ConstTaitBryan getBodyToRef_to_Euler ()
 Get this rotation matrix as a TaitBryan.
Vector3d getColumn (int column)
 Get a column of this matrix as a vector.
Vector3d getColumn1 ()
 Get a column of this matrix as a vector.
Vector3d getColumn2 ()
 Get a column of this matrix as a vector.
Vector3d getColumn3 ()
 Get a column of this matrix as a vector.
double getDeterminant ()
Vector3d getDiagonal ()
ConstMatrix3d getInverse ()
double getR1C1 ()
 Get a single, specific matrix element.
double getR1C2 ()
 Get a single, specific matrix element.
double getR1C3 ()
 Get a single, specific matrix element.
double getR2C1 ()
 Get a single, specific matrix element.
double getR2C2 ()
 Get a single, specific matrix element.
double getR2C3 ()
 Get a single, specific matrix element.
double getR3C1 ()
 Get a single, specific matrix element.
double getR3C2 ()
 Get a single, specific matrix element.
double getR3C3 ()
 Get a single, specific matrix element.
Vector3d getRow (int row)
 Get a row of this matrix as a Vector3d.
Vector3d getRow1 ()
Vector3d getRow2 ()
Vector3d getRow3 ()
double getTrace ()
 Return the trace of this matrix.
int hashCode ()
void multiply (ConstMatrix3d left, ConstMatrix3d right)
 Multiple two matricies and store the result in this matrix.
void multiply (double scalar)
 Multiply this matrix by a scalar.
void normalize ()
 Normalize this matrix by dividing all elements by the determinant of this matrix.
void postMultiplyByVector (ConstVector3d vec, Vector3d result)
 Postmultiply this matrix by a vector, and store the result.
void postMultiplyByVector (ConstVector3f vec, Vector3f result)
 Postmultiply this matrix by a vector, and store the result.
void set (int row, int column, double value)
 Set a matrix element by its row and column numbers.
void setR1C1 (double r1c1)
void setR1C2 (double r1c2)
void setR1C3 (double r1c3)
void setR2C1 (double r2c1)
void setR2C2 (double r2c2)
void setR2C3 (double r2c3)
void setR3C1 (double r3c1)
void setR3C2 (double r3c2)
void setR3C3 (double r3c3)
String toString ()
void transpose ()
 Convert this matrix to its transpose.

Static Public Attributes

static final ConstMatrix3d zero = new Matrix3d(0, 0, 0, 0, 0, 0, 0, 0, 0)
 Matrix with all zeroes.
static final ConstMatrix3d identity = new Matrix3d(1, 0, 0, 0, 1, 0, 0, 0, 1)
 Identity matrix with all zeroes except ones on its diagonal.

Private Attributes

double R1C1
double R1C2
double R1C3
double R2C1
double R2C2
double R2C3
double R3C1
double R3C2
double R3C3

Static Private Attributes

static final double REAL_BIG = 1e6

Detailed Description

A 3x3 matrix.

Constructor & Destructor Documentation

com.mak.vrlj.math.Matrix3d.Matrix3d ( )
inline
com.mak.vrlj.math.Matrix3d.Matrix3d ( ConstMatrix3d  original)
inline

Copy constructor.

Parameters
originalsource for copy.

References com.mak.vrlj.math.Matrix3d.assignFrom().

com.mak.vrlj.math.Matrix3d.Matrix3d ( double  r1c1,
double  r1c2,
double  r1c3,
double  r2c1,
double  r2c2,
double  r2c3,
double  r3c1,
double  r3c2,
double  r3c3 
)
inline

Member Function Documentation

void com.mak.vrlj.math.Matrix3d.assignFrom ( ConstMatrix3d  other)
inline
boolean com.mak.vrlj.math.Matrix3d.equals ( Object  obj)
inline
double com.mak.vrlj.math.Matrix3d.get ( int  row,
int  column 
)
inlinevirtual
ConstTaitBryan com.mak.vrlj.math.Matrix3d.getBodyToRef_to_Euler ( )
inlinevirtual
Vector3d com.mak.vrlj.math.Matrix3d.getColumn ( int  column)
inlinevirtual

Get a column of this matrix as a vector.

Parameters
column
Returns
column as a Vector3d

Implements com.mak.vrlj.math.ConstMatrix3d.

References com.mak.vrlj.math.Matrix3d.getColumn1(), com.mak.vrlj.math.Matrix3d.getColumn2(), and com.mak.vrlj.math.Matrix3d.getColumn3().

Vector3d com.mak.vrlj.math.Matrix3d.getColumn1 ( )
inlinevirtual

Get a column of this matrix as a vector.

Returns
column 1

Implements com.mak.vrlj.math.ConstMatrix3d.

References com.mak.vrlj.math.Matrix3d.R1C1, com.mak.vrlj.math.Matrix3d.R2C1, and com.mak.vrlj.math.Matrix3d.R3C1.

Referenced by com.mak.vrlj.math.Matrix3d.getColumn().

Vector3d com.mak.vrlj.math.Matrix3d.getColumn2 ( )
inlinevirtual

Get a column of this matrix as a vector.

Returns
column 2

Implements com.mak.vrlj.math.ConstMatrix3d.

References com.mak.vrlj.math.Matrix3d.R1C2, com.mak.vrlj.math.Matrix3d.R2C2, and com.mak.vrlj.math.Matrix3d.R3C2.

Referenced by com.mak.vrlj.math.Matrix3d.getColumn().

Vector3d com.mak.vrlj.math.Matrix3d.getColumn3 ( )
inlinevirtual

Get a column of this matrix as a vector.

Returns
column 3

Implements com.mak.vrlj.math.ConstMatrix3d.

References com.mak.vrlj.math.Matrix3d.R1C3, com.mak.vrlj.math.Matrix3d.R2C3, and com.mak.vrlj.math.Matrix3d.R3C3.

Referenced by com.mak.vrlj.math.Matrix3d.getColumn().

double com.mak.vrlj.math.Matrix3d.getDeterminant ( )
inlinevirtual
Vector3d com.mak.vrlj.math.Matrix3d.getDiagonal ( )
inlinevirtual
ConstMatrix3d com.mak.vrlj.math.Matrix3d.getInverse ( )
inlinevirtual
double com.mak.vrlj.math.Matrix3d.getR1C1 ( )
inlinevirtual

Get a single, specific matrix element.

Returns
the value of element R1C1.

Implements com.mak.vrlj.math.ConstMatrix3d.

References com.mak.vrlj.math.Matrix3d.R1C1.

Referenced by com.mak.vrlj.coord.Smoother.rotMatrixFromRotRatesAndTime(), and com.mak.vrlj.coord.Smoother.smoothBodyToGeoc().

double com.mak.vrlj.math.Matrix3d.getR1C2 ( )
inlinevirtual

Get a single, specific matrix element.

Returns
the value of element R1C2.

Implements com.mak.vrlj.math.ConstMatrix3d.

References com.mak.vrlj.math.Matrix3d.R1C2.

Referenced by com.mak.vrlj.coord.Smoother.rotMatrixFromRotRatesAndTime().

double com.mak.vrlj.math.Matrix3d.getR1C3 ( )
inlinevirtual

Get a single, specific matrix element.

Returns
the value of element R1C3.

Implements com.mak.vrlj.math.ConstMatrix3d.

References com.mak.vrlj.math.Matrix3d.R1C3.

Referenced by com.mak.vrlj.coord.Smoother.rotMatrixFromRotRatesAndTime().

double com.mak.vrlj.math.Matrix3d.getR2C1 ( )
inlinevirtual

Get a single, specific matrix element.

Returns
the value of element R2C1.

Implements com.mak.vrlj.math.ConstMatrix3d.

References com.mak.vrlj.math.Matrix3d.R2C1.

Referenced by com.mak.vrlj.coord.Smoother.rotMatrixFromRotRatesAndTime().

double com.mak.vrlj.math.Matrix3d.getR2C2 ( )
inlinevirtual

Get a single, specific matrix element.

Returns
the value of element R2C2.

Implements com.mak.vrlj.math.ConstMatrix3d.

References com.mak.vrlj.math.Matrix3d.R2C2.

Referenced by com.mak.vrlj.coord.Smoother.rotMatrixFromRotRatesAndTime().

double com.mak.vrlj.math.Matrix3d.getR2C3 ( )
inlinevirtual

Get a single, specific matrix element.

Returns
the value of element R2C3.

Implements com.mak.vrlj.math.ConstMatrix3d.

References com.mak.vrlj.math.Matrix3d.R2C3.

Referenced by com.mak.vrlj.coord.Smoother.rotMatrixFromRotRatesAndTime().

double com.mak.vrlj.math.Matrix3d.getR3C1 ( )
inlinevirtual

Get a single, specific matrix element.

Returns
the value of element R3C1.

Implements com.mak.vrlj.math.ConstMatrix3d.

References com.mak.vrlj.math.Matrix3d.R3C1.

Referenced by com.mak.vrlj.coord.Smoother.rotMatrixFromRotRatesAndTime().

double com.mak.vrlj.math.Matrix3d.getR3C2 ( )
inlinevirtual

Get a single, specific matrix element.

Returns
the value of element R3C2.

Implements com.mak.vrlj.math.ConstMatrix3d.

References com.mak.vrlj.math.Matrix3d.R3C2.

Referenced by com.mak.vrlj.coord.Smoother.rotMatrixFromRotRatesAndTime().

double com.mak.vrlj.math.Matrix3d.getR3C3 ( )
inlinevirtual

Get a single, specific matrix element.

Returns
the value of element R3C3.

Implements com.mak.vrlj.math.ConstMatrix3d.

References com.mak.vrlj.math.Matrix3d.R3C3.

Referenced by com.mak.vrlj.coord.Smoother.rotMatrixFromRotRatesAndTime().

Vector3d com.mak.vrlj.math.Matrix3d.getRow ( int  row)
inlinevirtual

Get a row of this matrix as a Vector3d.

Parameters
row
Returns
row of this matrix as a Vector3d.

Implements com.mak.vrlj.math.ConstMatrix3d.

References com.mak.vrlj.math.Matrix3d.getRow1(), com.mak.vrlj.math.Matrix3d.getRow2(), and com.mak.vrlj.math.Matrix3d.getRow3().

Vector3d com.mak.vrlj.math.Matrix3d.getRow1 ( )
inlinevirtual
Vector3d com.mak.vrlj.math.Matrix3d.getRow2 ( )
inlinevirtual
Vector3d com.mak.vrlj.math.Matrix3d.getRow3 ( )
inlinevirtual
double com.mak.vrlj.math.Matrix3d.getTrace ( )
inlinevirtual

Return the trace of this matrix.

Returns
the sum of the diagonal elements.

Implements com.mak.vrlj.math.ConstMatrix3d.

References com.mak.vrlj.math.Matrix3d.R1C1, com.mak.vrlj.math.Matrix3d.R2C2, and com.mak.vrlj.math.Matrix3d.R3C3.

int com.mak.vrlj.math.Matrix3d.hashCode ( )
inline
void com.mak.vrlj.math.Matrix3d.multiply ( ConstMatrix3d  left,
ConstMatrix3d  right 
)
inline
void com.mak.vrlj.math.Matrix3d.multiply ( double  scalar)
inline
void com.mak.vrlj.math.Matrix3d.normalize ( )
inline
void com.mak.vrlj.math.Matrix3d.postMultiplyByVector ( ConstVector3d  vec,
Vector3d  result 
)
inlinevirtual
void com.mak.vrlj.math.Matrix3d.postMultiplyByVector ( ConstVector3f  vec,
Vector3f  result 
)
inlinevirtual
void com.mak.vrlj.math.Matrix3d.set ( int  row,
int  column,
double  value 
)
inline

Set a matrix element by its row and column numbers.

Parameters
rowthe row of the element.
columnthe column of the element.
valuethe new value to store in the element.

References com.mak.vrlj.math.Matrix3d.R1C1, com.mak.vrlj.math.Matrix3d.R1C2, com.mak.vrlj.math.Matrix3d.R1C3, com.mak.vrlj.math.Matrix3d.R2C1, com.mak.vrlj.math.Matrix3d.R2C2, com.mak.vrlj.math.Matrix3d.R2C3, com.mak.vrlj.math.Matrix3d.R3C1, com.mak.vrlj.math.Matrix3d.R3C2, and com.mak.vrlj.math.Matrix3d.R3C3.

Referenced by com.mak.vrlj.math.Matrix3d.getInverse().

void com.mak.vrlj.math.Matrix3d.setR1C1 ( double  r1c1)
inline
void com.mak.vrlj.math.Matrix3d.setR1C2 ( double  r1c2)
inline
void com.mak.vrlj.math.Matrix3d.setR1C3 ( double  r1c3)
inline
void com.mak.vrlj.math.Matrix3d.setR2C1 ( double  r2c1)
inline
void com.mak.vrlj.math.Matrix3d.setR2C2 ( double  r2c2)
inline
void com.mak.vrlj.math.Matrix3d.setR2C3 ( double  r2c3)
inline
void com.mak.vrlj.math.Matrix3d.setR3C1 ( double  r3c1)
inline
void com.mak.vrlj.math.Matrix3d.setR3C2 ( double  r3c2)
inline
void com.mak.vrlj.math.Matrix3d.setR3C3 ( double  r3c3)
inline
String com.mak.vrlj.math.Matrix3d.toString ( )
inline
void com.mak.vrlj.math.Matrix3d.transpose ( )
inline

Member Data Documentation

final ConstMatrix3d com.mak.vrlj.math.Matrix3d.identity = new Matrix3d(1, 0, 0, 0, 1, 0, 0, 0, 1)
static

Identity matrix with all zeroes except ones on its diagonal.

Referenced by com.mak.vrlj.math.TaitBryan.eulerToEuler(), and com.mak.vrlj.coord.Smoother.rotMatrixFromRotRatesAndTime().

double com.mak.vrlj.math.Matrix3d.R1C1
private
double com.mak.vrlj.math.Matrix3d.R1C2
private
double com.mak.vrlj.math.Matrix3d.R1C3
private
double com.mak.vrlj.math.Matrix3d.R2C1
private
double com.mak.vrlj.math.Matrix3d.R2C2
private
double com.mak.vrlj.math.Matrix3d.R2C3
private
double com.mak.vrlj.math.Matrix3d.R3C1
private
double com.mak.vrlj.math.Matrix3d.R3C2
private
double com.mak.vrlj.math.Matrix3d.R3C3
private
final double com.mak.vrlj.math.Matrix3d.REAL_BIG = 1e6
staticprivate
final ConstMatrix3d com.mak.vrlj.math.Matrix3d.zero = new Matrix3d(0, 0, 0, 0, 0, 0, 0, 0, 0)
static

The documentation for this class was generated from the following file:

Document ID: Generated on Tue Mar 1 02:56:17 EST 2016 from SVN revision 162687
Copyright © 2005-2014 VT MÄK. All Rights Reserved (www.mak.com)