|
JScience v4.3 | ||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectorg.jscience.mathematics.vector.Matrix<Complex>
org.jscience.mathematics.vector.ComplexMatrix
public final class ComplexMatrix
This class represents an optimized matrix implementation
for complex numbers.
Instances of this class can be created from ComplexVector,
either as rows or columns if the matrix is transposed. For example:
ComplexVector<Rational> column0 = ComplexVector.valueOf(...);
ComplexVector<Rational> column1 = ComplexVector.valueOf(...);
ComplexMatrix<Rational> M = ComplexMatrix.valueOf(column0, column1).transpose();
| Field Summary |
|---|
| Fields inherited from class org.jscience.mathematics.vector.Matrix |
|---|
XML |
| Method Summary | |
|---|---|
ComplexMatrix |
adjoint()
Returns the adjoint of this matrix. |
Complex |
cofactor(int i,
int j)
Returns the cofactor of an element in this matrix. |
ComplexMatrix |
copy()
Returns a copy of this matrix allocated
by the calling thread (possibly on the stack). |
Complex |
determinant()
Returns the determinant of this matrix. |
Complex |
get(int i,
int j)
Returns a single element from this matrix. |
ComplexVector |
getColumn(int j)
Returns the column identified by the specified index in this matrix. |
ComplexVector |
getDiagonal()
Returns the diagonal vector. |
int |
getNumberOfColumns()
Returns the number of columns n for this matrix. |
int |
getNumberOfRows()
Returns the number of rows m for this matrix. |
ComplexVector |
getRow(int i)
Returns the row identified by the specified index in this matrix. |
ComplexMatrix |
inverse()
Returns the inverse of this matrix (must be square). |
ComplexMatrix |
minus(Matrix<Complex> that)
Returns the difference between this matrix and the one specified. |
ComplexMatrix |
opposite()
Returns the negation of this matrix. |
ComplexMatrix |
plus(Matrix<Complex> that)
Returns the sum of this matrix with the one specified. |
ComplexMatrix |
tensor(Matrix<Complex> that)
Returns the linear algebraic matrix tensor product of this matrix and another (Kronecker product). |
ComplexMatrix |
times(Complex k)
Returns the product of this matrix by the specified factor. |
ComplexMatrix |
times(Matrix<Complex> that)
Returns the product of this matrix with the one specified. |
ComplexVector |
times(Vector<Complex> v)
Returns the product of this matrix by the specified vector. |
ComplexMatrix |
transpose()
Returns the transpose of this matrix. |
static ComplexMatrix |
valueOf(Complex[][] elements)
Returns a complex matrix from the specified 2-dimensional array. |
static ComplexMatrix |
valueOf(ComplexVector... rows)
Returns a complex matrix holding the specified row vectors (column vectors if transposed). |
static ComplexMatrix |
valueOf(java.util.List<ComplexVector> rows)
Returns a complex matrix holding the row vectors from the specified collection (column vectors if transposed). |
static ComplexMatrix |
valueOf(Matrix<Complex> that)
Returns a complex matrix equivalent to the specified matrix. |
ComplexVector |
vectorization()
Returns the vectorization of this matrix. |
| Methods inherited from class org.jscience.mathematics.vector.Matrix |
|---|
divide, equals, equals, hashCode, isSquare, pow, pseudoInverse, solve, solve, toString, toText, trace |
| Methods inherited from class java.lang.Object |
|---|
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
| Method Detail |
|---|
public static ComplexMatrix valueOf(Complex[][] elements)
elements - this matrix elements.
DimensionException - if rows have different length.ComplexVectorpublic static ComplexMatrix valueOf(ComplexVector... rows)
transposed).
rows - the row vectors.
DimensionException - if the rows do not have the same dimension.public static ComplexMatrix valueOf(java.util.List<ComplexVector> rows)
transposed).
rows - the list of row vectors.
DimensionException - if the rows do not have the same dimension.public static ComplexMatrix valueOf(Matrix<Complex> that)
that - the matrix to convert.
that or a complex matrix holding the same elements
as the specified matrix.public int getNumberOfRows()
Matrixm for this matrix.
getNumberOfRows in class Matrix<Complex>public int getNumberOfColumns()
Matrixn for this matrix.
getNumberOfColumns in class Matrix<Complex>
public Complex get(int i,
int j)
Matrix
get in class Matrix<Complex>i - the row index (range [0..m[).j - the column index (range [0..n[).
public ComplexVector getRow(int i)
Matrix
getRow in class Matrix<Complex>i - the row index (range [0..m[).
public ComplexVector getColumn(int j)
Matrix
getColumn in class Matrix<Complex>j - the column index (range [0..n[).
public ComplexVector getDiagonal()
Matrix
getDiagonal in class Matrix<Complex>public ComplexMatrix opposite()
Matrix
opposite in interface GroupAdditive<Matrix<Complex>>opposite in class Matrix<Complex>-this.public ComplexMatrix plus(Matrix<Complex> that)
Matrix
plus in interface GroupAdditive<Matrix<Complex>>plus in class Matrix<Complex>that - the matrix to be added.
this + that.public ComplexMatrix minus(Matrix<Complex> that)
Matrix
minus in class Matrix<Complex>that - the matrix to be subtracted.
this - that.public ComplexMatrix times(Complex k)
Matrix
times in interface VectorSpace<Matrix<Complex>,Complex>times in class Matrix<Complex>k - the coefficient multiplier.
this · kpublic ComplexVector times(Vector<Complex> v)
Matrix
times in class Matrix<Complex>v - the vector.
this · vpublic ComplexMatrix times(Matrix<Complex> that)
Matrix
times in interface Ring<Matrix<Complex>>times in class Matrix<Complex>that - the matrix multiplier.
this · that.public ComplexMatrix inverse()
Matrix
inverse in class Matrix<Complex>1 / thispublic Complex determinant()
Matrix
determinant in class Matrix<Complex>public ComplexMatrix transpose()
Matrix
transpose in class Matrix<Complex>A'.
public Complex cofactor(int i,
int j)
Matrix
cofactor in class Matrix<Complex>i - the row index.j - the column index.
THIS[i,j].public ComplexMatrix adjoint()
Matrix
adjoint in class Matrix<Complex>public ComplexMatrix tensor(Matrix<Complex> that)
MatrixDenseMatrix.
tensor in class Matrix<Complex>that - the second matrix.
this ⊗ thatpublic ComplexVector vectorization()
MatrixDenseVector.
vectorization in class Matrix<Complex>public ComplexMatrix copy()
Matrixallocated
by the calling thread (possibly on the stack).
copy in interface javolution.lang.ValueTypecopy in class Matrix<Complex>
|
JScience v4.3 | ||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||