15#ifndef dealii_la_parallel_block_vector_h
16#define dealii_la_parallel_block_vector_h
37# ifdef DEAL_II_WITH_PETSC
47# ifdef DEAL_II_WITH_TRILINOS
83 template <
typename Number>
154 template <
typename OtherNumber>
168 const std::vector<IndexSet> &ghost_indices,
189 const std::vector<std::shared_ptr<const Utilities::MPI::Partitioner>>
233 template <
class Number2>
243#ifdef DEAL_II_WITH_PETSC
255#ifdef DEAL_II_WITH_TRILINOS
323 template <
typename Number2>
347 const std::vector<IndexSet> &ghost_indices,
372 const std::vector<std::shared_ptr<const Utilities::MPI::Partitioner>>
384 const std::vector<std::shared_ptr<const Utilities::MPI::Partitioner>>
463 template <
typename Number2>
471 template <
typename OtherNumber>
473 add(
const std::vector<size_type> &indices,
566 const std::shared_ptr<const Utilities::MPI::CommunicationPatternBase>
575 std::shared_ptr<const Utilities::MPI::CommunicationPatternBase>
603 template <
typename FullMatrixType>
607 const bool symmetric =
false)
const;
625 template <
typename FullMatrixType>
629 const bool symmetric =
false)
const;
640 template <
typename FullMatrixType>
644 const Number s = Number(0.),
645 const Number b = Number(1.))
const;
673 add(
const std::vector<size_type> &indices,
674 const std::vector<Number> &values);
775 const unsigned int precision = 3,
776 const bool scientific =
true,
777 const bool across =
true)
const;
819template <
typename Number>
832template <
typename Number>
841# include <deal.II/lac/la_parallel_block_vector.templates.h>
::internal::BlockVectorIterators::Iterator< BlockVectorBase, false > iterator
const value_type * const_pointer
typename BlockType::const_reference const_reference
types::global_dof_index size_type
typename BlockType::value_type value_type
::internal::BlockVectorIterators::Iterator< BlockVectorBase, true > const_iterator
typename BlockType::reference reference
typename BlockType::real_type real_type
Vector< Number > BlockType
void swap(LinearAlgebra::distributed::BlockVector< Number > &u, LinearAlgebra::distributed::BlockVector< Number > &v) noexcept
typename BaseClass::value_type value_type
bool has_ghost_elements() const
BlockVector< Number > & operator-=(const BlockVector< Number > &V)
Number operator*(const BlockVector< Number > &V) const
BlockVector(const size_type num_blocks=0, const size_type block_size=0)
void add(const std::vector< size_type > &indices, const std::vector< Number > &values)
void print(std::ostream &out, const unsigned int precision=3, const bool scientific=true, const bool across=true) const
void reinit(const std::vector< IndexSet > &local_ranges, const MPI_Comm communicator)
void sadd(const Number s, const Number a, const BlockVector< Number > &V)
void swap(BlockVector< Number > &v) noexcept
static constexpr unsigned int communication_block_size
void add(const Number a, const BlockVector< Number > &V, const Number b, const BlockVector< Number > &W)
void reinit(const std::vector< std::shared_ptr< const Utilities::MPI::Partitioner > > &partitioners, const bool make_ghosted, const MPI_Comm &comm_sm=MPI_COMM_SELF)
real_type norm_sqr() const
real_type l2_norm() const
BlockVector(const std::vector< size_type > &block_sizes)
std::size_t memory_consumption() const
BlockVector(const BlockVector< OtherNumber > &v)
typename BaseClass::iterator iterator
BlockVector(const BlockVector< Number > &V)
void reinit(const size_type num_blocks, const size_type block_size=0, const bool omit_zeroing_entries=false)
BlockVector< Number > & operator=(const TrilinosWrappers::MPI::BlockVector &trilinos_vec)
BlockVector< Number > & operator=(const PETScWrappers::MPI::BlockVector &petsc_vec)
BlockVector< Number > & operator/=(const Number factor)
void set_ghost_state(const bool ghosted) const
void add(const Number a, const BlockVector< Number > &V)
void add(const std::vector< size_type > &indices, const ::Vector< OtherNumber > &values)
BlockVector & operator=(const Vector< Number > &V)
BlockVector< Number > & operator*=(const Number factor)
Number mean_value() const
BlockVector(const std::vector< IndexSet > &local_ranges, const MPI_Comm communicator)
void scale(const BlockVector< Number > &scaling_factors)
typename BaseClass::BlockType BlockType
void reinit(const std::vector< IndexSet > &local_ranges, const std::vector< IndexSet > &ghost_indices, const MPI_Comm communicator)
typename BaseClass::size_type size_type
Number multivector_inner_product_with_metric(const FullMatrixType &matrix, const BlockVector< Number > &V, const bool symmetric=false) const
void zero_out_ghost_values() const
typename BaseClass::const_reference const_reference
real_type lp_norm(const real_type p) const
BlockVector & operator=(const BlockVector< Number2 > &V)
typename BaseClass::real_type real_type
void reinit(const BlockVector< Number2 > &V, const bool omit_zeroing_entries=false)
BlockVector & operator=(const BlockVector &V)
void reinit(const std::vector< std::shared_ptr< const Utilities::MPI::Partitioner > > &partitioners, const MPI_Comm &comm_sm=MPI_COMM_SELF)
Number add_and_dot(const Number a, const BlockVector< Number > &V, const BlockVector< Number > &W)
void equ(const Number a, const BlockVector< Number > &V)
void sadd(const Number s, const BlockVector< Number > &V)
void copy_locally_owned_data_from(const BlockVector< Number2 > &src)
BlockVector(const std::vector< IndexSet > &local_ranges, const std::vector< IndexSet > &ghost_indices, const MPI_Comm communicator)
real_type linfty_norm() const
BlockVector(const std::vector< std::shared_ptr< const Utilities::MPI::Partitioner > > &partitioners, const MPI_Comm &comm_sm=MPI_COMM_SELF)
typename BaseClass::const_pointer const_pointer
typename BaseClass::reference reference
typename BaseClass::const_iterator const_iterator
void multivector_inner_product(FullMatrixType &matrix, const BlockVector< Number > &V, const bool symmetric=false) const
real_type l1_norm() const
void update_ghost_values() const
void mmult(BlockVector< Number > &V, const FullMatrixType &matrix, const Number s=Number(0.), const Number b=Number(1.)) const
void reinit(const std::vector< size_type > &block_sizes, const bool omit_zeroing_entries=false)
void compress(VectorOperation::values operation)
void import_elements(const LinearAlgebra::ReadWriteVector< Number > &V, const VectorOperation::values operation, const std::shared_ptr< const Utilities::MPI::CommunicationPatternBase > &communication_pattern={})
BlockVector< Number > & operator+=(const BlockVector< Number > &V)
BlockVector & operator=(const value_type s)
virtual size_type size() const override
typename BaseClass::pointer pointer
::IndexSet locally_owned_elements() const
#define DEAL_II_DEPRECATED
#define DEAL_II_NAMESPACE_OPEN
#define DEAL_II_NAMESPACE_CLOSE
#define DeclException0(Exception0)
static ::ExceptionBase & ExcVectorTypeNotCompatible()
static ::ExceptionBase & ExcIteratorRangeDoesNotMatchVectorSize()