public class IMatrix extends Object
Modifier and Type | Field and Description |
---|---|
int |
columns
the count of columns of the matrix
|
double[][] |
imagmatrix
the imaginary part of the content
|
double[][] |
realmatrix
the real part of the content
|
int |
rows
the count of rows of the matrix
|
Constructor and Description |
---|
IMatrix(int rows,
int columns)
Creates a complex matrix
|
IMatrix(Matrix m)
Creates a complex copy of a matrix
|
Modifier and Type | Method and Description |
---|---|
IMatrix |
add(IMatrix b)
Addition from two matrices
|
void |
add(IMatrix b,
IMatrix result)
Addition from two matrices
|
Complex |
contraction()
Calculates the contraction from a matrix
|
IMatrix |
duplicate()
Copy a matrix
|
void |
duplicate(IMatrix result)
Copy a matrix
|
int |
getColumns()
Returns the count of columns
|
int |
getRows()
Returns the count of rows
|
IVector |
getVectorFromColumn(int index)
Creates a vector with the content of a column from this matrix
|
IVector |
getVectorFromDiagonal()
Creates a vector with the content of the diagonal elements from this matrix
|
IVector |
getVectorFromRow(int index)
Creates a vector with the content of a row from this matrix
|
IMatrix |
mul(Complex a)
Multiplikation from a scalar and a matrix
|
void |
mul(Complex a,
IMatrix result)
Multiplikation from a scalar and a matrix
|
IMatrix |
mul(IMatrix b)
Multiplikation from two matrices
|
void |
mul(IMatrix b,
IMatrix result)
Multiplikation from two matrices
|
IVector |
mul(IVector a)
Multiplikation from a vector and a matrix
|
void |
mul(IVector a,
IVector result)
Multiplikation from a vector and a matrix
|
void |
reshape(int newrows,
int newcolumns)
Resize the matrix
|
IMatrix |
similar(IMatrix U)
Similar transformation
Ut * M * U
|
void |
similar(IMatrix U,
IMatrix result)
Similar transformation
Ut * M * U
|
IMatrix |
sub(IMatrix b)
Subtraktion from two matrices
|
void |
sub(IMatrix b,
IMatrix result)
Subtraktion from two matrices
|
String |
toString()
Return a matrix as a string
|
IMatrix |
transpose()
Transpose a matrix
|
void |
transpose(IMatrix result)
Transpose a matrix
|
public double[][] realmatrix
public double[][] imagmatrix
public int rows
public int columns
public IMatrix(int rows, int columns)
public IMatrix(Matrix m)
public int getRows()
public int getColumns()
public IVector getVectorFromRow(int index)
public IVector getVectorFromColumn(int index)
public IVector getVectorFromDiagonal()
public IMatrix duplicate()
public void duplicate(IMatrix result)
public IMatrix transpose()
public void transpose(IMatrix result)
public Complex contraction()
public void reshape(int newrows, int newcolumns)
Copyright © 2021. All rights reserved.