public class SymmetricMatrix extends DenseMatrix
aij = aji for all elements.
values| Constructor and Description |
|---|
SymmetricMatrix(double[][] values)
Construct with given values, which must be jagged and represent the lower
triangular values
|
SymmetricMatrix(int size)
Construct with given size
|
| Modifier and Type | Method and Description |
|---|---|
protected void |
assertInvariant() |
int |
columnCount()
Get the number of columns
|
static DenseMatrix |
fromJagged(double[][] values)
Create from jagged low triangular values
|
static DenseMatrix |
fromSquare(double[][] square)
Create from a square matrix
|
double |
get(int row,
int column) |
protected double[][] |
makeValues(int rows,
int columns) |
Vector |
mult(Vector v)
Returns
y = Ax. |
double |
put(int row,
int column,
double value)
Set the value at the given row/column
|
int |
rowCount() |
double[] |
rowwiseMean() |
double[][] |
unwrap() |
add, applyMultiplication, fill, newInstance, rows, usedasArray, asColumnMajorArray, column, columns, dense, density, elementCount, from, getHistogram, indexOf, isSquare, max, mean, min, newInstance, row, sparse, storeSparseOn, storeSparseOn, toString, transposeMultiply, transposeNonTransposeMultiplypublic SymmetricMatrix(int size)
size - public SymmetricMatrix(double[][] values)
values - protected void assertInvariant() throws IllegalArgumentException
assertInvariant in class DenseMatrixIllegalArgumentExceptionprotected double[][] makeValues(int rows, int columns)
makeValues in class DenseMatrixpublic int columnCount()
MatrixcolumnCount in class DenseMatrixpublic double get(int row, int column)
get in class DenseMatrixpublic double put(int row, int column, double value)
Matrixput in class DenseMatrixpublic int rowCount()
rowCount in class DenseMatrixpublic static DenseMatrix fromSquare(double[][] square)
square - public static DenseMatrix fromJagged(double[][] values)
values - public double[][] unwrap()
unwrap in class DenseMatrixpublic double[] rowwiseMean()
rowwiseMean in class Matrix