15#ifndef dealii_petsc_block_sparse_matrix_h
16#define dealii_petsc_block_sparse_matrix_h
21#ifdef DEAL_II_WITH_PETSC
116 template <
size_t block_rows,
size_t block_columns>
118 const std::array<std::array<Mat, block_columns>, block_rows> &);
171 reinit(
const std::vector<IndexSet> &rows,
172 const std::vector<IndexSet> &cols,
181 reinit(
const std::vector<IndexSet> &sizes,
276 std::vector<IndexSet>
284 std::vector<IndexSet>
314 operator const Mat &()
const;
360 , petsc_nest_matrix(nullptr)
373 template <
size_t block_rows,
size_t block_columns>
375 const std::array<std::array<Mat, block_columns>, block_rows> &arrayA)
378 this->
reinit(block_rows, block_columns);
379 this->
sub_objects.reinit(block_rows, block_columns);
380 for (
auto r = 0; r < block_rows; ++r)
381 for (
auto c = 0; c < block_columns; ++c)
400 this->
block(r, c) = d;
void Tvmult_nonblock_nonblock(VectorType &dst, const VectorType &src) const
void vmult_nonblock_nonblock(VectorType &dst, const VectorType &src) const
void Tvmult_block_block(BlockVectorType &dst, const BlockVectorType &src) const
const value_type & const_reference
void Tvmult_nonblock_block(VectorType &dst, const BlockVectorType &src) const
unsigned int n_block_rows() const
void vmult_block_block(BlockVectorType &dst, const BlockVectorType &src) const
types::global_dof_index size_type
Table< 2, SmartPointer< BlockType, BlockMatrixBase< SparseMatrix > > > sub_objects
typename BlockType::value_type value_type
void vmult_nonblock_block(VectorType &dst, const BlockVectorType &src) const
MatrixIterator< BlockMatrixIterators::Accessor< BlockMatrixBase, true > > const_iterator
unsigned int n_block_cols() const
const value_type * const_pointer
BlockType & block(const unsigned int row, const unsigned int column)
void vmult_block_nonblock(BlockVectorType &dst, const VectorType &src) const
MatrixIterator< BlockMatrixIterators::Accessor< BlockMatrixBase, false > > iterator
void Tvmult_block_nonblock(BlockVectorType &dst, const VectorType &src) const
void Tvmult(BlockVector &dst, const BlockVector &src) const
BaseClass::reference reference
~BlockSparseMatrix() override
void vmult(BlockVector &dst, const BlockVector &src) const
void reinit(const size_type n_block_rows, const size_type n_block_columns)
BlockSparseMatrix & operator=(const BlockSparseMatrix &)
BaseClass::pointer pointer
MPI_Comm get_mpi_communicator() const
BaseClass::const_pointer const_pointer
void create_empty_matrices_if_needed()
std::uint64_t n_nonzero_elements() const
BaseClass::BlockType BlockType
std::vector< IndexSet > locally_owned_domain_indices() const
BaseClass::value_type value_type
std::vector< IndexSet > locally_owned_range_indices() const
BaseClass::const_reference const_reference
void compress(VectorOperation::values operation)
#define DEAL_II_NAMESPACE_OPEN
#define DEAL_II_NAMESPACE_CLOSE
static ::ExceptionBase & ExcScalarAssignmentOnlyForZeroValue()
#define Assert(cond, exc)