Dune Core Modules (2.9.0)

Dune::MatrixIndexSet Class Reference

Stores the nonzero entries in a sparse matrix. More...

#include <dune/istl/matrixindexset.hh>

Public Member Functions

 MatrixIndexSet ()
 Default constructor.
 
 MatrixIndexSet (size_type rows, size_type cols)
 Constructor setting the matrix size.
 
void resize (size_type rows, size_type cols)
 Reset the size of an index set.
 
void add (size_type i, size_type j)
 Add an index to the index set.
 
size_type size () const
 Return the number of entries.
 
size_type rows () const
 Return the number of rows.
 
size_type rowsize (size_type row) const
 Return the number of entries in a given row.
 
template<class MatrixType >
void import (const MatrixType &m, size_type rowOffset=0, size_type colOffset=0)
 Import all nonzero entries of a sparse matrix into the index set. More...
 
template<class MatrixType >
void exportIdx (MatrixType &matrix) const
 Initializes a BCRSMatrix with the indices contained in this MatrixIndexSet. More...
 

Detailed Description

Stores the nonzero entries in a sparse matrix.

Member Function Documentation

◆ exportIdx()

template<class MatrixType >
void Dune::MatrixIndexSet::exportIdx ( MatrixType &  matrix) const
inline

Initializes a BCRSMatrix with the indices contained in this MatrixIndexSet.

Template Parameters
MatrixTypeNeeds to be BCRSMatrix<...>
Parameters
matrixreference to the MatrixType object

◆ import()

template<class MatrixType >
void Dune::MatrixIndexSet::import ( const MatrixType &  m,
size_type  rowOffset = 0,
size_type  colOffset = 0 
)
inline

Import all nonzero entries of a sparse matrix into the index set.

Template Parameters
MatrixTypeNeeds to be BCRSMatrix<...>
Parameters
mreference to the MatrixType object
rowOffsetdon't write to rows<rowOffset
colOffsetdon't write to cols<colOffset

The documentation for this class was generated from the following file:
Creative Commons License   |  Legal Statements / Impressum  |  Hosted by TU Dresden  |  generated with Hugo v0.80.0 (Mar 27, 23:31, 2024)