PSCF v1.1
|
Two-dimensional array container template (abstract). More...
#include <Matrix.h>
Public Member Functions | |
virtual | ~Matrix () |
Destructor. More... | |
int | capacity1 () const |
Get number of rows (range of the first array index). More... | |
int | capacity2 () const |
Get number of columns (range of the second array index). More... | |
Data const & | operator() (int i, int j) const |
Return element (i,j) of matrix by const reference. More... | |
Data & | operator() (int i, int j) |
Return element (i,j) of matrix by reference. More... | |
Data * | cArray () |
Return pointer to underlying one-dimensional C array. More... | |
Data const * | cArray () const |
Return pointer to const to underlying one-dimensional C array. More... | |
Protected Member Functions | |
Matrix () | |
Default constructor. More... | |
Protected Attributes | |
Data * | data_ |
Pointer to 1D C array of all elements. More... | |
int | capacity1_ |
Number of rows (range of first index). More... | |
int | capacity2_ |
Number of columns (range of first index). More... | |
Two-dimensional array container template (abstract).
An Matrix object A is a two-dimensional array in which the operator A(i, j) returns a reference to element in column j of row i.
The memory for a Matrix is stored in a single one-dimensional C array, in which each row is stored as a consecutive block.
Class Matrix is an abstract class because it cannot allocate memory. Concrete subclasses include DMatrix and FMatrix.
|
virtual |
|
inlineprotected |
|
inline |
Get number of rows (range of the first array index).
Definition at line 136 of file Matrix.h.
Referenced by Util::bcast(), Pscf::LuSolver::computeLU(), Util::recv(), and Util::send().
|
inline |
Get number of columns (range of the second array index).
Definition at line 143 of file Matrix.h.
Referenced by Util::bcast(), Pscf::LuSolver::computeLU(), Util::recv(), and Util::send().
|
inline |
|
inline |
|
inline |
Return pointer to underlying one-dimensional C array.
Definition at line 178 of file Matrix.h.
Referenced by Pscf::LuSolver::inverse().
|
inline |
|
protected |
Pointer to 1D C array of all elements.
Definition at line 84 of file Matrix.h.
Referenced by Util::DMatrix< Data >::DMatrix(), Util::FMatrix< Data, M, N >::FMatrix(), and Util::DMatrix< Data >::operator=().
|
protected |
Number of rows (range of first index).
Definition at line 87 of file Matrix.h.
Referenced by Util::DMatrix< Data >::DMatrix(), Util::FMatrix< Data, M, N >::FMatrix(), and Util::DMatrix< Data >::operator=().
|
protected |
Number of columns (range of first index).
Definition at line 90 of file Matrix.h.
Referenced by Util::DMatrix< Data >::DMatrix(), Util::FMatrix< Data, M, N >::FMatrix(), and Util::DMatrix< Data >::operator=().