|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.mymedialite.datatype.SparseMatrix<T>
org.mymedialite.datatype.SymmetricSparseMatrix<java.lang.Float>
org.mymedialite.datatype.SkewSymmetricSparseMatrix
public class SkewSymmetricSparseMatrix
A skew symmetric (anti-symmetric) sparse matrix; consumes less memory. Be careful when accessing the matrix via the NonEmptyEntryIDs and NonEmptyRows properties: these contain only the entries with x > y, but not their antisymmetric counterparts. * @version 2.03
Field Summary |
---|
Fields inherited from class org.mymedialite.datatype.SparseMatrix |
---|
row_list |
Constructor Summary | |
---|---|
SkewSymmetricSparseMatrix(int dimension)
Create a skew symmetric sparse matrix with a given dimension. |
Method Summary | |
---|---|
IMatrix<java.lang.Float> |
createMatrix(int num_rows,
int num_columns)
Create a matrix with a given number of rows and columns. |
java.lang.Float |
get(int x,
int y)
Get an element of the sparse matrix. |
boolean |
isSymmetric()
Only true if all entries are zero. |
void |
set(int x,
int y,
java.lang.Float value)
Set an element of the sparse matrix. |
Methods inherited from class org.mymedialite.datatype.SymmetricSparseMatrix |
---|
nonEmptyEntryIDs, numberOfNonEmptyEntries |
Methods inherited from class org.mymedialite.datatype.SparseMatrix |
---|
get, grow, nonEmptyRows, numberOfColumns, numberOfRows, transpose |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public SkewSymmetricSparseMatrix(int dimension)
dimension
- the dimension (number of rows/columns)Method Detail |
---|
public java.lang.Float get(int x, int y)
get
in interface IMatrix<java.lang.Float>
get
in class SymmetricSparseMatrix<java.lang.Float>
x
- the row IDy
- the column ID
public void set(int x, int y, java.lang.Float value)
set
in interface IMatrix<java.lang.Float>
set
in class SymmetricSparseMatrix<java.lang.Float>
x
- the row IDy
- the column IDvalue
- the value to setpublic boolean isSymmetric()
isSymmetric
in interface IMatrix<java.lang.Float>
isSymmetric
in class SymmetricSparseMatrix<java.lang.Float>
public IMatrix<java.lang.Float> createMatrix(int num_rows, int num_columns)
IMatrix
createMatrix
in interface IMatrix<java.lang.Float>
createMatrix
in class SymmetricSparseMatrix<java.lang.Float>
num_rows
- the number of rowsnum_columns
- the number of columns
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |