Public Member Functions
fmatvec::Matrix< ST, AT > Class Template Reference

This is the basic matrix class for arbitrary matrices. More...

#include <matrix.h>

List of all members.

Public Member Functions

 Matrix (int m, int n)
 Standard constructor.
AT & operator() (int i, int j)
 Element operator.
const AT & operator() (int i, int j) const
 Element operator.
int rows () const
 Number of rows.
int cols () const
 Number of columns.
 operator std::vector< std::vector< AT > > ()
 Cast to std::vector<std::vector<AT> >.

Detailed Description

template<class ST, class AT>
class fmatvec::Matrix< ST, AT >

This is the basic matrix class for arbitrary matrices.

Template class Matrix with shape type ST and atomic type AT. The first template parameter defines the shape type, the second parameter the atomic type of the matrix. Valid shape types are General, Symmetric, GeneralBand, Diagonal and Sparse. Valid atomic types are int, float, double, complex<float> and complex<double>


Constructor & Destructor Documentation

template<class ST, class AT>
fmatvec::Matrix< ST, AT >::Matrix ( int  m,
int  n 
)
inline

Standard constructor.

The standard constructor.

Parameters:
mThe number of rows
nThe number of columns

Member Function Documentation

template<class ST, class AT>
int fmatvec::Matrix< ST, AT >::cols ( ) const
inline
template<class ST , class AT >
fmatvec::Matrix< ST, AT >::operator std::vector< std::vector< AT > > ( )

Cast to std::vector<std::vector<AT> >.

Returns:
The std::vector<std::vector<AT> > representation of the matrix
template<class ST, class AT>
AT& fmatvec::Matrix< ST, AT >::operator() ( int  i,
int  j 
)

Element operator.

Returns a reference to the element in the i-th row and the j-th column.

Parameters:
iThe i-th row of the matrix
jThe j-th column of the matrix
Returns:
A reference to the element A(i,j).
See also:
operator()(int,int) const

Referenced by fmatvec::Matrix< General, AT >::operator()(), and fmatvec::Matrix< Symmetric, AT >::operator()().

template<class ST, class AT>
const AT& fmatvec::Matrix< ST, AT >::operator() ( int  i,
int  j 
) const

Element operator.

See operator()(int,int)

template<class ST, class AT>
int fmatvec::Matrix< ST, AT >::rows ( ) const
inline

The documentation for this class was generated from the following file: