|
JavaView® v2.12 | ||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Object | +--jv.vecmath.PcMatrix
Linear algebra class for small matrices of complex numbers.
PdMatrix, Serialized Form| Field Summary | |
PuComplex[][] |
m_data
Data array containing the components of the vector. |
| Constructor Summary | |
PcMatrix()
Create a new matrix of zero size. |
|
PcMatrix(int aSize)
Create a square matrix with given dimension. |
|
PcMatrix(int iSize,
int jSize)
Create a non-square matrix with given dimensions. |
|
| Method Summary | |
void |
add(PcMatrix m)
|
void |
add(PcMatrix m1,
PcMatrix m2)
|
PuComplex[] |
aEigenvector(PuComplex l)
Matrix must be 2x2. |
java.lang.Object |
clone()
Duplicate matrix and data array. |
void |
copy(PcMatrix m)
|
static PcMatrix |
copyNew(PcMatrix mat)
Create a new matrix as clone of argument matrix. |
PuComplex[] |
eigenvalues()
Matrix must be 2x2. |
int |
getISize()
Get number of rows of matrix. |
int |
getJSize()
Get number of columns of matrix. |
int |
getSize()
Get dimension of square matrix, return -1 for non-square matrices. |
boolean |
isSquare()
Check if matrix is square. |
void |
leftMult(PcMatrix m)
Multiply with square matrix from left of same sizes using this = m*this.
|
void |
mult(PcMatrix m1,
PcMatrix m2)
Multiply two matrices of possibly different sizes using this = m1*m2.
|
void |
multScalar(PcMatrix m,
PuComplex scalar)
|
void |
multScalar(PuComplex scalar)
|
void |
rightMult(PcMatrix m)
Multiply with square matrix from right of same sizes using this = this*m.
|
void |
setConstant(PuComplex aValue)
Set all matrix entries to a constant value. |
void |
setIdentity()
Initialize square matrix to be identity matrix. |
void |
setSize(int aSize)
Set dimension of square matrix. |
void |
setSize(int iSize,
int jSize)
Set dimension of non-square matrix. |
void |
sub(PcMatrix m)
|
void |
sub(PcMatrix m1,
PcMatrix m2)
|
java.lang.String |
toShortString()
Create a short string representation of matrix with all instance variables. |
java.lang.String |
toString()
Create a multi-line string representation with detailed information about all instance variables. |
void |
transpose()
Transpose a square matrix by this = transpose(this). |
| Methods inherited from class java.lang.Object |
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Field Detail |
public PuComplex[][] m_data
| Constructor Detail |
public PcMatrix()
public PcMatrix(int aSize)
public PcMatrix(int iSize,
int jSize)
| Method Detail |
public java.lang.Object clone()
copyNew(PcMatrix).copyNew(PcMatrix)public static PcMatrix copyNew(PcMatrix mat)
public int getISize()
public int getJSize()
public int getSize()
public void setSize(int aSize)
public void setSize(int iSize,
int jSize)
public boolean isSquare()
public void setIdentity()
public void setConstant(PuComplex aValue)
public void add(PcMatrix m)
public void add(PcMatrix m1,
PcMatrix m2)
public void sub(PcMatrix m)
public void sub(PcMatrix m1,
PcMatrix m2)
public void copy(PcMatrix m)
public void multScalar(PuComplex scalar)
public void multScalar(PcMatrix m,
PuComplex scalar)
public void leftMult(PcMatrix m)
this = m*this.
Size of 'this' does not change.public void rightMult(PcMatrix m)
this = this*m.
Size of 'this' does not change.
public void mult(PcMatrix m1,
PcMatrix m2)
this = m1*m2.
Size of 'this' is adjusted to have number of rows equal to first factor
and number of columns equal to second factor.public void transpose()
this = transpose(this).public java.lang.String toString()
toString in class java.lang.Objectpublic java.lang.String toShortString()
public PuComplex[] eigenvalues()
public PuComplex[] aEigenvector(PuComplex l)
l - eigenvalue of matrix
|
JavaView® v2.12 | ||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||