MyMediaLite
3.01
|
Class for storing dense matrices. More...
Public Member Functions | |
IMatrix< T > | CreateMatrix (int num_rows, int num_columns) |
Create a matrix with a given number of rows and columns. | |
void | Grow (int num_rows, int num_columns) |
Grows the matrix to the requested size, if necessary. | |
SymmetricMatrix (int dim) | |
Initializes a new instance of the SymmetricMatrix class. | |
IMatrix< T > | Transpose () |
Get the transpose of the matrix, i.e. a matrix where rows and columns are interchanged. | |
Public Attributes | |
int | dim |
Dimension, the number of rows and columns. | |
Protected Attributes | |
internal T[][] | data |
Data array: data is stored in columns. | |
Properties | |
virtual bool | IsSymmetric [get] |
True if the matrix is symmetric, false otherwise. | |
int | NumberOfColumns [get] |
The number of columns of the matrix. | |
int | NumberOfRows [get] |
The number of rows of the matrix. | |
virtual T | this[int i, int j] [get, set] |
T | this[int x, int y] [get, set] |
The value at (i,j) |
Class for storing dense matrices.
The data is stored in row-major mode. Indexes are zero-based.
T | the type of the matrix entries |
IMatrix<T> CreateMatrix | ( | int | num_rows, |
int | num_columns | ||
) | [inline] |
Create a matrix with a given number of rows and columns.
num_rows | the number of rows |
num_columns | the number of columns |
Implements IMatrix< T >.
void Grow | ( | int | num_rows, |
int | num_cols | ||
) | [inline] |
Grows the matrix to the requested size, if necessary.
The new entries are filled with zeros.
num_rows | the minimum number of rows |
num_cols | the minimum number of columns |
Implements IMatrix< T >.
SymmetricMatrix | ( | int | dim | ) | [inline] |
Initializes a new instance of the SymmetricMatrix class.
dim | the number of rows and columns |
Get the transpose of the matrix, i.e. a matrix where rows and columns are interchanged.
Implements IMatrix< T >.
int dim |
Dimension, the number of rows and columns.
virtual bool IsSymmetric [get] |
True if the matrix is symmetric, false otherwise.
True if the matrix is symmetric, false otherwise
Implements IMatrix< T >.
Reimplemented in CorrelationMatrix.
int NumberOfColumns [get] |
int NumberOfRows [get] |
T this[int x, int y] [get, set, inherited] |
The value at (i,j)
The value at (i,j)
x | the row ID |
y | the column ID |
Implemented in SparseMatrix< T >, SkewSymmetricSparseMatrix, SymmetricSparseMatrix< T >, SparseBooleanMatrix, SparseBooleanMatrixBinarySearch, and SparseBooleanMatrixStatic.