18#include "libmesh/libmesh_config.h"
20#ifdef LIBMESH_HAVE_PETSC
23#include "libmesh/petsc_matrix_shell_matrix.h"
48 const auto m = this->_dof_map->n_dofs();
49 const auto m_l = this->_dof_map->n_local_dofs();
70std::unique_ptr<SparseMatrix<T>>
73 libmesh_not_implemented();
77std::unique_ptr<SparseMatrix<T>>
80 libmesh_not_implemented();
87 libmesh_error_msg(
"Method not appropriate for arbitrary shell matrices");
94 libmesh_error_msg(
"Method not appropriate for arbitrary shell matrices");
100 const std::vector<numeric_index_type> &,
101 const std::vector<numeric_index_type> &)
103 libmesh_error_msg(
"Method not appropriate for arbitrary shell matrices");
109 const std::vector<numeric_index_type> &)
111 libmesh_error_msg(
"Method not appropriate for arbitrary shell matrices");
118 libmesh_error_msg(
"Method not appropriate for arbitrary shell matrices");
125 libmesh_error_msg(
"Method not appropriate for arbitrary shell matrices");
132 libmesh_error_msg(
"Method not appropriate for arbitrary shell matrices");
139 libmesh_error_msg(
"Method not appropriate for arbitrary shell matrices");
146 libmesh_error_msg(
"Method not appropriate for arbitrary shell matrices");
153 libmesh_error_msg(
"Method not appropriate for arbitrary shell matrices");
160 libmesh_error_msg(
"Method not appropriate for arbitrary shell matrices");
166 std::vector<numeric_index_type> &,
167 std::vector<T> &)
const
169 libmesh_error_msg(
"Method not appropriate for arbitrary shell matrices");
176 libmesh_error_msg(
"Method not appropriate for arbitrary shell matrices");
Defines a dense matrix for use in Finite Element-type computations.
Provides a uniform interface to vector storage schemes for different linear algebra libraries.
This class allows to use a PETSc shell matrix as a PetscMatrix.
virtual Real l1_norm() const override
virtual void get_transpose(SparseMatrix< T > &dest) const override
Copies the transpose of the matrix into dest, which may be *this.
virtual Real linfty_norm() const override
virtual std::unique_ptr< SparseMatrix< T > > zero_clone() const override
virtual void add(const numeric_index_type i, const numeric_index_type j, const T value) override
Add value to the element (i,j).
virtual void set(const numeric_index_type i, const numeric_index_type j, const T value) override
Set the element (i,j) to value.
virtual void init(const numeric_index_type m, const numeric_index_type n, const numeric_index_type m_l, const numeric_index_type n_l, const numeric_index_type=30, const numeric_index_type=10, const numeric_index_type blocksize=1) override
Initialize SparseMatrix with the specified sizes.
virtual SparseMatrix< T > & operator=(const SparseMatrix< T > &) override
This looks like a copy assignment operator, but note that, unlike normal copy assignment operators,...
virtual void print_personal(std::ostream &os=libMesh::out) const override
Print the contents of the matrix to the screen in a package-personalized style, if available.
virtual void zero() override
Set all entries to 0.
virtual std::unique_ptr< SparseMatrix< T > > clone() const override
virtual T operator()(const numeric_index_type i, const numeric_index_type j) const override
virtual void get_row(numeric_index_type i, std::vector< numeric_index_type > &indices, std::vector< T > &values) const override
Get a row from the matrix.
virtual void add_matrix(const DenseMatrix< T > &dm, const std::vector< numeric_index_type > &rows, const std::vector< numeric_index_type > &cols) override
Add the full matrix dm to the SparseMatrix.
virtual void get_diagonal(NumericVector< T > &dest) const override
Copies the diagonal part of the matrix into dest.
The libMesh namespace provides an interface to certain functionality in the library.
void init_shell_mat(Obj &obj, const numeric_index_type m, const numeric_index_type n, const numeric_index_type m_l, const numeric_index_type n_l, const numeric_index_type blocksize_in)
Initialize a shell matrix object.
ParallelType
Defines an enum for parallel data structure types.
dof_id_type numeric_index_type
DIE A HORRIBLE DEATH HERE typedef LIBMESH_DEFAULT_SCALAR_TYPE Real