Package no.uib.cipr.matrix.io
Class VectorInfo
java.lang.Object
no.uib.cipr.matrix.io.VectorInfo
Contains information on a vector in a variant of the Matrix Market exchange format
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic enumWhat kind of numbers are stored -
Constructor Summary
ConstructorsConstructorDescriptionVectorInfo(boolean sparse, VectorInfo.VectorField field) Creates a specific type -
Method Summary
Modifier and TypeMethodDescriptionbooleanisArray()Returnstrueif the vector is in array format, elsefalsebooleanReturnstrueif the vector stores complex numbers, elsefalsebooleanReturnstrueif the vector is in coordinate format, elsefalsebooleanisDense()Returnstrueif the vector is in array format, elsefalsebooleanReturnstrueif the vector stores integers, elsefalsebooleanReturnstrueif the vector does not store any numbers, elsefalsebooleanisReal()Returnstrueif the vector stores real numbers, elsefalsebooleanisSparse()Returnstrueif the vector is in coordinate format, elsefalsetoString()Returns a string representation of the specifier.
-
Constructor Details
-
VectorInfo
Creates a specific type- Parameters:
sparse- True for sparse vectors, else falsefield- Type of data stored
-
-
Method Details
-
isSparse
public boolean isSparse()Returnstrueif the vector is in coordinate format, elsefalse -
isCoordinate
public boolean isCoordinate()Returnstrueif the vector is in coordinate format, elsefalse -
isDense
public boolean isDense()Returnstrueif the vector is in array format, elsefalse -
isArray
public boolean isArray()Returnstrueif the vector is in array format, elsefalse -
isReal
public boolean isReal()Returnstrueif the vector stores real numbers, elsefalse -
isInteger
public boolean isInteger()Returnstrueif the vector stores integers, elsefalse -
isComplex
public boolean isComplex()Returnstrueif the vector stores complex numbers, elsefalse -
isPattern
public boolean isPattern()Returnstrueif the vector does not store any numbers, elsefalse -
toString
Returns a string representation of the specifier. Can be used to provide a header for writing to a file. It is a two-line output, which can look like this:%%MatrixMarket vector coordinate real
-