20 #ifndef LIBMESH_SPARSE_SHELL_MATRIX_H 21 #define LIBMESH_SPARSE_SHELL_MATRIX_H 25 #include "libmesh/libmesh_common.h" 26 #include "libmesh/reference_counted_object.h" 27 #include "libmesh/libmesh.h" 28 #include "libmesh/shell_matrix.h" 29 #include "libmesh/sparse_matrix.h" 106 template <
typename T>
115 template <
typename T>
119 _m.get_diagonal(dest);
126 #endif // LIBMESH_SPARSE_SHELL_MATRIX_H virtual void vector_mult(NumericVector< T > &dest, const NumericVector< T > &arg) const override
Multiplies the matrix with arg and stores the result in dest.
virtual numeric_index_type n() const override
Provides a uniform interface to vector storage schemes for different linear algebra libraries...
The libMesh namespace provides an interface to certain functionality in the library.
dof_id_type numeric_index_type
const SparseMatrix< T > & _m
The sparse matrix.
virtual void vector_mult_add(NumericVector< T > &dest, const NumericVector< T > &arg) const override
Multiplies the matrix with arg and adds the result to dest.
SparseShellMatrix(const SparseMatrix< T > &new_m)
Constructor; takes references to the sparse matrix.
This class allows to use any SparseMatrix object as a shell matrix.
virtual ~SparseShellMatrix()
Destructor.
Generic shell matrix, i.e.
virtual numeric_index_type m() const override
virtual void get_diagonal(NumericVector< T > &dest) const override
Copies the diagonal part of the matrix into dest.