dune-pdelab
2.0.0
|
A dense matrix for storing data associated with the degrees of freedom of a pair of LocalFunctionSpaces. More...
#include <dune/pdelab/gridoperator/common/diagonallocalmatrix.hh>
Classes | |
struct | iterator |
Public Types | |
typedef std::vector< T > | BaseContainer |
The type of the underlying storage container. More... | |
typedef BaseContainer::value_type | value_type |
The value type of this container. More... | |
typedef BaseContainer::size_type | size_type |
The size type of this container. More... | |
typedef BaseContainer::reference | reference |
The reference type of this container. More... | |
typedef BaseContainer::const_reference | const_reference |
The const reference type of this container. More... | |
typedef W | weight_type |
The weight type of this container. More... | |
typedef WeightedMatrixAccumulationView < DiagonalLocalMatrix > | WeightedAccumulationView |
An accumulate-only view of this container that automatically applies a weight to all contributions. More... | |
Public Member Functions | |
iterator | begin () |
iterator | end () |
DiagonalLocalMatrix () | |
Default constructor. More... | |
DiagonalLocalMatrix (size_type r, size_type c) | |
Construct a LocalMatrix with r rows and c columns. More... | |
DiagonalLocalMatrix (size_type r, size_type c, const T &t) | |
Construct a LocalMatrix with r rows and c columns and initialize its entries with t. More... | |
void | resize (size_type r, size_type c) |
Resize the matrix. More... | |
DiagonalLocalMatrix & | operator= (const T &t) |
Assign t to all entries of the matrix. More... | |
void | assign (size_type r, size_type c, const T &t) |
Resize the matrix and assign t to all entries. More... | |
template<typename LFSU , typename LFSV > | |
T & | operator() (const LFSV &lfsv, size_type i, const LFSU &lfsu, size_type j) |
Access the value associated with the i-th DOF of lfsv and the j-th DOF of lfsu. More... | |
template<typename LFSU , typename LFSV > | |
const T & | operator() (const LFSV &lfsv, size_type i, const LFSU &lfsu, size_type j) const |
Access the value associated with the i-th DOF of lfsv and the j-th DOF of lfsu (const version). More... | |
DiagonalLocalMatrix & | operator*= (const T &x) |
Multiplies all entries of the matrix with x. More... | |
size_type | nrows () const |
Returns the number of rows. More... | |
size_type | ncols () const |
Returns the number of columns. More... | |
template<class X , class R > | |
void | umv (const X &x, R &y) const |
y += A x More... | |
template<class X , class R > | |
void | usmv (const value_type &alpha, const X &x, R &y) const |
y += alpha A x More... | |
WeightedAccumulationView | weightedAccumulationView (weight_type weight) |
Returns a weighted accumulate-only view of this matrix with the given weight. More... | |
BaseContainer & | base () |
Returns the underlying storage container. More... | |
const BaseContainer & | base () const |
Returns the underlying storage container (const version). More... | |
value_type & | getEntry (size_type i, size_type j) |
Direct (unmapped) access to the (i,j)-th entry of the matrix. More... | |
const value_type & | getEntry (size_type i, size_type j) const |
Direct (unmapped) access to the (i,j)-th entry of the matrix (const version). More... | |
A dense matrix for storing data associated with the degrees of freedom of a pair of LocalFunctionSpaces.
This container represents a dense matrix based on a std::vector-like storage container and supports accessing its entries indexed by pairs of (LocalFunctionSpace,DOF of LocalFunctionSpace). If the LocalFunctionSpaces contain tags indicating whether they are trial or test spaces, the access methods will also assert that the first space is a test space and the second space is a trial space.
T | The type of values to store in the matrix. |
W | The type of weight applied in a WeightedAccumulationView. |
typedef std::vector<T> Dune::PDELab::DiagonalLocalMatrix< T, W >::BaseContainer |
The type of the underlying storage container.
typedef BaseContainer::const_reference Dune::PDELab::DiagonalLocalMatrix< T, W >::const_reference |
The const reference type of this container.
typedef BaseContainer::reference Dune::PDELab::DiagonalLocalMatrix< T, W >::reference |
The reference type of this container.
typedef BaseContainer::size_type Dune::PDELab::DiagonalLocalMatrix< T, W >::size_type |
The size type of this container.
typedef BaseContainer::value_type Dune::PDELab::DiagonalLocalMatrix< T, W >::value_type |
The value type of this container.
typedef W Dune::PDELab::DiagonalLocalMatrix< T, W >::weight_type |
The weight type of this container.
A value of this type will be used to assign a weight to contributions in a WeightedAccumulationView.
typedef WeightedMatrixAccumulationView<DiagonalLocalMatrix> Dune::PDELab::DiagonalLocalMatrix< T, W >::WeightedAccumulationView |
An accumulate-only view of this container that automatically applies a weight to all contributions.
|
inline |
Default constructor.
|
inline |
Construct a LocalMatrix with r rows and c columns.
|
inline |
Construct a LocalMatrix with r rows and c columns and initialize its entries with t.
|
inline |
Resize the matrix and assign t to all entries.
|
inline |
Returns the underlying storage container.
|
inline |
Returns the underlying storage container (const version).
|
inline |
|
inline |
|
inline |
Direct (unmapped) access to the (i,j)-th entry of the matrix.
Referenced by Dune::PDELab::DiagonalLocalMatrix< T, W >::iterator::dereference(), Dune::PDELab::DiagonalLocalMatrix< T, W >::operator()(), Dune::PDELab::DiagonalLocalMatrix< T, W >::umv(), and Dune::PDELab::DiagonalLocalMatrix< T, W >::usmv().
|
inline |
Direct (unmapped) access to the (i,j)-th entry of the matrix (const version).
|
inline |
Returns the number of columns.
|
inline |
Returns the number of rows.
Referenced by Dune::PDELab::DiagonalLocalMatrix< T, W >::end().
|
inline |
Access the value associated with the i-th DOF of lfsv and the j-th DOF of lfsu.
lfsv | The LocalFunctionSpace whose DOF will determine the row index of the entry. |
i | The index of the DOF of lfsv that will determine the row index of the entry. |
lfsu | The LocalFunctionSpace whose DOF will determine the column index of the entry. |
j | The index of the DOF of lfsu that will determine the column index of the entry. |
References Dune::PDELab::DiagonalLocalMatrix< T, W >::getEntry().
|
inline |
Access the value associated with the i-th DOF of lfsv and the j-th DOF of lfsu (const version).
lfsv | The LocalFunctionSpace whose DOF will determine the row index of the entry. |
i | The index of the DOF of lfsv that will determine the row index of the entry. |
lfsu | The LocalFunctionSpace whose DOF will determine the column index of the entry. |
j | The index of the DOF of lfsu that will determine the column index of the entry. |
References Dune::PDELab::DiagonalLocalMatrix< T, W >::getEntry().
|
inline |
Multiplies all entries of the matrix with x.
|
inline |
Assign t to all entries of the matrix.
|
inline |
Resize the matrix.
|
inline |
y += A x
References Dune::PDELab::accessBaseContainer(), and Dune::PDELab::DiagonalLocalMatrix< T, W >::getEntry().
|
inline |
y += alpha A x
References Dune::PDELab::accessBaseContainer(), and Dune::PDELab::DiagonalLocalMatrix< T, W >::getEntry().
|
inline |
Returns a weighted accumulate-only view of this matrix with the given weight.