dune-fem 2.8.0
|
#include <dune/fem/operator/matrix/spmatrix.hh>
Public Types | |
typedef T | field_type |
matrix field type | |
typedef IndexT | size_type |
matrix index type | |
typedef SparseRowMatrix< field_type, size_type, ValuesVector, IndicesVector > | ThisType |
typedef ThisType | MatrixBaseType |
Public Member Functions | |
SparseRowMatrix (const ThisType &)=delete | |
SparseRowMatrix () | |
construct matrix of zero size | |
SparseRowMatrix (const size_type rows, const size_type cols, const size_type nz) | |
void | reserve (const size_type rows, const size_type cols, const size_type nz) |
reserve memory for given rows, columns and number of non zeros | |
template<class Stencil > | |
void | fillPattern (const Stencil &stencil, const size_type rowBlockSize, const size_type colBlockSize) |
reserve memory for given rows, columns and number of non zeros | |
size_type | rows () const |
return number of rows | |
size_type | cols () const |
return number of columns | |
void | set (const size_type row, const size_type col, const field_type val) |
set entry to value (also setting 0 will result in an entry) | |
void | add (const size_type row, const size_type col, const field_type val) |
add value to row,col entry | |
template<class ArgDFType , class DestDFType > | |
void | apply (const ArgDFType &f, DestDFType &ret) const |
ret = A*f | |
field_type | get (const size_type row, const size_type col) const |
return value of entry (row,col) | |
void | clear () |
set all matrix entries to zero | |
void | clearRow (const size_type row) |
set all entries in row to zero | |
void | scale (const size_type row, const size_type col, const field_type val) |
scale all entries in row with a given value | |
size_type | maxNzPerRow () const |
size_type | numNonZeros () const |
size_type | numNonZeros (size_type row) const |
std::pair< const field_type, size_type > | realValue (size_type index) const |
void | print (std::ostream &s=std::cout, unsigned int offset=0) const |
print matrix | |
template<class SizeT , class NumericT > | |
void | fillCSRStorage (std::vector< std::map< SizeT, NumericT > > &matrix) const |
void | compress () |
size_type | startRow (const size_type row) const |
size_type | endRow (const size_type row) const |
std::tuple< ValuesVector &, IndicesVector &, IndicesVector & > | exportCRS () |
Static Public Attributes | |
static const size_type | defaultCol = std::numeric_limits<size_type>::max() |
static const size_type | zeroCol = std::numeric_limits<size_type>::max()-1 |
static const int | firstCol = 0 |
Protected Member Functions | |
void | resize (size_type rows, size_type cols, size_type nz) |
resize matrix | |
size_type | colIndex (size_type row, size_type col) |
returns local col index for given global (row,col) | |
Protected Attributes | |
ValuesVector | values_ |
IndicesVector | columns_ |
IndicesVector | rows_ |
std::array< size_type, 2 > | dim_ |
size_type | maxNzPerRow_ |
bool | compressed_ |
typedef T Dune::Fem::SparseRowMatrix< T, IndexT, ValuesVector, IndicesVector >::field_type |
matrix field type
typedef ThisType Dune::Fem::SparseRowMatrix< T, IndexT, ValuesVector, IndicesVector >::MatrixBaseType |
type of the base matrix for consistency with ISTLMatrixObject
typedef IndexT Dune::Fem::SparseRowMatrix< T, IndexT, ValuesVector, IndicesVector >::size_type |
matrix index type
typedef SparseRowMatrix<field_type,size_type,ValuesVector,IndicesVector> Dune::Fem::SparseRowMatrix< T, IndexT, ValuesVector, IndicesVector >::ThisType |
|
delete |
|
inlineexplicit |
construct matrix of zero size
|
inline |
construct matrix with 'rows' rows and 'cols' columns, maximum 'nz' non zero values in each row
|
inline |
add value to row,col entry
|
inline |
ret = A*f
|
inline |
set all matrix entries to zero
|
inline |
set all entries in row to zero
|
inlineprotected |
returns local col index for given global (row,col)
|
inline |
return number of columns
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
reserve memory for given rows, columns and number of non zeros
|
inline |
return value of entry (row,col)
|
inline |
return max number of non zeros used in SparseRowMatrixObject::reserve
|
inline |
return max number of non zeros used in SparseRowMatrixObject::reserve
|
inline |
return number of non zeros in row used in ColCompMatrix::setMatrix
|
inline |
print matrix
|
inline |
return pair (value,column) used in ColCompMatrix::setMatrix and FemPy CRS matrix export
|
inline |
reserve memory for given rows, columns and number of non zeros
|
inlineprotected |
resize matrix
|
inline |
return number of rows
|
inline |
scale all entries in row with a given value
|
inline |
set entry to value (also setting 0 will result in an entry)
|
inline |
|
protected |
|
protected |
|
static |
|
protected |
|
static |
|
protected |
|
protected |
|
protected |
|
static |