Public Member Functions | Protected Attributes | List of all members
Seldon::VirtualMatrix< T > Class Template Reference

Abstract base class for all matrices. More...

#include <Matrix_Base.hxx>

Inheritance diagram for Seldon::VirtualMatrix< T >:
Seldon::Matrix_ArrayComplexSparse< T, Prop, ArrayColComplexSparse, Allocator > Seldon::Matrix_ArrayComplexSparse< T, Prop, ArrayColSymComplexSparse, Allocator > Seldon::Matrix_ArrayComplexSparse< T, Prop, ArrayRowComplexSparse, Allocator > Seldon::Matrix_ArrayComplexSparse< T, Prop, ArrayRowSymComplexSparse, Allocator > Seldon::Matrix_ArraySparse< T, Prop, ArrayColSparse, Allocator > Seldon::Matrix_ArraySparse< T, Prop, ArrayColSymSparse, Allocator > Seldon::Matrix_ArraySparse< T, Prop, ArrayRowSparse, Allocator > Seldon::Matrix_ArraySparse< T, Prop, ArrayRowSymSparse, Allocator > Seldon::Matrix_Band< T, General, ArrowCol, Allocator > Seldon::Matrix_Band< T, General, BandedCol, Allocator > Seldon::Matrix_Band< T, Prop, Storage, typename SeldonDefaultAllocator< Storage, T >::allocator > Seldon::Matrix_Base< T, NewAlloc< T > > Seldon::Matrix_Base< T, typename SeldonDefaultAllocator< Storage, T >::allocator > Seldon::Matrix_Base< T, typename SeldonDefaultAllocator< VectFull, T >::allocator > Seldon::Matrix_ArrayComplexSparse< T, Prop, Storage, Allocator > Seldon::Matrix_ArraySparse< T, Prop, Storage, Allocator > Seldon::Matrix_Band< T, Prop, Storage, Allocator > Seldon::Matrix_Base< T, Allocator >

Public Member Functions

 VirtualMatrix ()
 Default constructor. More...
 
 VirtualMatrix (int i, int j)
 Main constructor. More...
 
int GetM () const
 Returns the number of rows. More...
 
int GetN () const
 Returns the number of columns. More...
 
int GetM (const Seldon::SeldonTranspose &status) const
 Returns the number of rows of the matrix possibly transposed. More...
 
int GetN (const Seldon::SeldonTranspose &status) const
 Returns the number of columns of the matrix possibly transposed. More...
 
int GetM (const CBLAS_TRANSPOSE &status) const
 Returns the number of rows of the matrix possibly transposed. More...
 
int GetN (const CBLAS_TRANSPOSE &status) const
 Returns the number of columns of the matrix possibly transposed. More...
 
long GetSize () const
 Returns the number of elements in the matrix. More...
 

Protected Attributes

int m_
 
int n_
 

Detailed Description

template<class T>
class Seldon::VirtualMatrix< T >

Abstract base class for all matrices.

This class is abstract if SELDON_WITH_VIRTUAL is defined. In that case, it can be used for iterative solvers or eigenvalue solvers such that a general algorithm can be written and compiled with this abstract definition of a matrix.

Definition at line 42 of file Matrix_Base.hxx.

Constructor & Destructor Documentation

◆ VirtualMatrix() [1/2]

template<class T >
Seldon::VirtualMatrix< T >::VirtualMatrix
inline

Default constructor.

On exit, the matrix is an empty 0x0 matrix.

Definition at line 37 of file Matrix_BaseInline.cxx.

◆ VirtualMatrix() [2/2]

template<class T >
Seldon::VirtualMatrix< T >::VirtualMatrix ( int  i,
int  j 
)
inlineexplicit

Main constructor.

Builds a i x j matrix

Parameters
inumber of rows.
jnumber of columns.

Definition at line 50 of file Matrix_BaseInline.cxx.

Member Function Documentation

◆ GetM() [1/3]

template<class T >
int Seldon::VirtualMatrix< T >::GetM
inline

Returns the number of rows.

Returns
The number of rows.

Definition at line 69 of file Matrix_BaseInline.cxx.

◆ GetM() [2/3]

template<class T >
int Seldon::VirtualMatrix< T >::GetM ( const CBLAS_TRANSPOSE &  status) const
inline

Returns the number of rows of the matrix possibly transposed.

Parameters
statusassumed status about the transposition of the matrix.
Returns
The number of rows of the possibly-transposed matrix.

Definition at line 122 of file Matrix_BaseInline.cxx.

◆ GetM() [3/3]

template<class T >
int Seldon::VirtualMatrix< T >::GetM ( const Seldon::SeldonTranspose status) const
inline

Returns the number of rows of the matrix possibly transposed.

Parameters
statusassumed status about the transposition of the matrix.
Returns
The number of rows of the possibly-transposed matrix.

Definition at line 92 of file Matrix_BaseInline.cxx.

◆ GetN() [1/3]

template<class T >
int Seldon::VirtualMatrix< T >::GetN
inline

Returns the number of columns.

Returns
The number of columns.

Definition at line 80 of file Matrix_BaseInline.cxx.

◆ GetN() [2/3]

template<class T >
int Seldon::VirtualMatrix< T >::GetN ( const CBLAS_TRANSPOSE &  status) const
inline

Returns the number of columns of the matrix possibly transposed.

Parameters
statusassumed status about the transposition of the matrix.
Returns
The number of columns of the possibly-transposed matrix.

Definition at line 137 of file Matrix_BaseInline.cxx.

◆ GetN() [3/3]

template<class T >
int Seldon::VirtualMatrix< T >::GetN ( const Seldon::SeldonTranspose status) const
inline

Returns the number of columns of the matrix possibly transposed.

Parameters
statusassumed status about the transposition of the matrix.
Returns
The number of columns of the possibly-transposed matrix.

Definition at line 107 of file Matrix_BaseInline.cxx.

◆ GetSize()

template<class T >
long Seldon::VirtualMatrix< T >::GetSize
inline

Returns the number of elements in the matrix.

Returns the number of elements in the matrix, i.e. the number of rows multiplied by the number of columns.

Returns
The number of elements in the matrix.

Definition at line 153 of file Matrix_BaseInline.cxx.


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