|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.ObjectFEJDMath.Matrix22
Used to manipulate 2*2 matrix Note : to compute : vectleft * m * vectright use the following syntax : m.multVectLeft(vectleft).mult(vectright);
Field Summary | |
private double[] |
mat
The coefficients of the matrix |
Constructor Summary | |
Matrix22()
Makes a new empty matrix |
|
Matrix22(double x,
double y,
double z,
double t)
Makes a new matrix with the coefficients x,y,z,t |
Method Summary | |
double |
det()
Returns the determinant of the matrix |
double |
getNum(int a,
int b)
Returns the value of the coefficient (a,b) of the matrix (1 based as usual in math) |
Matrix22 |
inv()
Returns the invert of the matrix |
Matrix22 |
mult(Matrix22 m)
Returns the matrix multiplied by m |
Vector2 |
multVectLeft(Vector2 v)
Returns the result of the multiplication of v and the matrix |
Vector2 |
multVectRight(Vector2 v)
Returns the result of the multiplication of the matrix and v |
Matrix22 |
scalMult(double l)
Returns the matrix multiplied by the scalar value l |
void |
setNum(int a,
int b,
double val)
Sets the coefficient (a,b) of the matrix to val (1 based as usual in math) |
java.lang.String |
toString()
Returns the matrix in a mathematical format |
Matrix22 |
transpose()
Returns the matrix transposed |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
private double[] mat
Constructor Detail |
public Matrix22()
public Matrix22(double x, double y, double z, double t)
Method Detail |
public double getNum(int a, int b)
public void setNum(int a, int b, double val)
public double det()
public Matrix22 inv()
public Matrix22 mult(Matrix22 m)
public Matrix22 scalMult(double l)
public Matrix22 transpose()
public Vector2 multVectLeft(Vector2 v)
public Vector2 multVectRight(Vector2 v)
public java.lang.String toString()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |