|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | ENUM CONSTANTS | FIELD | METHOD | DETAIL: ENUM CONSTANTS | FIELD | METHOD |
java.lang.Objectjava.lang.Enum<Matrix.WriteFormat>
maspack.matrix.Matrix.WriteFormat
public static enum Matrix.WriteFormat
Describes the general format for writing matrix values.
Enum Constant Summary | |
---|---|
CRS
Compressed row storage (CRS) format. |
|
Dense
Usual dense matrix format, as in |
|
MatrixMarket
MatrixMarket format. |
|
Sparse
Sparse format consisting of the non-zero entries, in row-major order, each written as a 3-tuples containing the i and j indices (0-based) and the associated value. |
|
SYMMETRIC_CRS
Same as CRS, except that the matrix is assumed to be symmetric and only the upper triangular values are stored. |
Method Summary | |
---|---|
static Matrix.WriteFormat |
valueOf(java.lang.String name)
Returns the enum constant of this type with the specified name. |
static Matrix.WriteFormat[] |
values()
Returns an array containing the constants of this enum type, in the order they are declared. |
Methods inherited from class java.lang.Enum |
---|
compareTo, equals, getDeclaringClass, hashCode, name, ordinal, toString, valueOf |
Methods inherited from class java.lang.Object |
---|
getClass, notify, notifyAll, wait, wait, wait |
Enum Constant Detail |
---|
public static final Matrix.WriteFormat Dense
1.00 0.00 0.50 2.30 4.10 0.00 0.00 2.00 3.00
public static final Matrix.WriteFormat Sparse
Dense
would be output as
( 0 0 1 ) ( 0 2 0.50 ) ( 1 0 2.30 ) ( 1 1 4.10 ) ( 2 1 2.00 ) ( 2 2 3.00 )
public static final Matrix.WriteFormat MatrixMarket
Dense
would be
output as
%%MatrixMarket matrix coordinate real general 3 3 6 1 1 1 1 3 0.50 2 1 2.30 2 2 4.10 3 2 2.00 3 3 3.00
public static final Matrix.WriteFormat CRS
Dense
would be output as
3 1 3 5 7 1 3 1 2 2 3 1.00 0.50 2.30 4.10 2.00 3.00
public static final Matrix.WriteFormat SYMMETRIC_CRS
Method Detail |
---|
public static Matrix.WriteFormat[] values()
for (Matrix.WriteFormat c : Matrix.WriteFormat.values()) System.out.println(c);
public static Matrix.WriteFormat valueOf(java.lang.String name)
name
- the name of the enum constant to be returned.
java.lang.IllegalArgumentException
- if this enum type has no constant
with the specified name
java.lang.NullPointerException
- if the argument is null
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | ENUM CONSTANTS | FIELD | METHOD | DETAIL: ENUM CONSTANTS | FIELD | METHOD |