3 #include <dune/istl/bvector.hh> 4 #include <dune/functions/backends/istlvectorbackend.hh> 6 #include <amdis/Output.hpp> 7 #include <amdis/common/FakeContainer.hpp> 8 #include <amdis/linearalgebra/VectorBase.hpp> 9 #include <amdis/typetree/MultiIndex.hpp> 13 template <
class T,
class =
void>
16 using type = Dune::FieldVector<T,1>;
31 using BaseVector = Dune::BlockVector<typename BlockVectorType<T>::type>;
47 template <
class Basis,
48 Dune::disableCopyMove<ISTLBlockVector,Basis> = 0>
68 return vector_.size();
73 template <
class SizeInfo>
74 void init(SizeInfo
const& sizeInfo,
bool clear)
76 Dune::Functions::istlVectorBackend(vector_).resize(sizeInfo);
82 template <
class MultiIndex>
85 return Dune::Functions::istlVectorBackend(vector_)[idx];
89 template <
class MultiIndex>
92 return Dune::Functions::istlVectorBackend(vector_)[idx];
constexpr bool MultiIndex
A multi-index type.
Definition: Concepts.hpp:150
ISTLBlockVector(Basis const &)
Constructor. Constructs new BaseVector.
Definition: VectorBackend.hpp:49
T value_type
The type of the elements of the DOFVector.
Definition: VectorBackend.hpp:37
BaseVector & vector()
Return the data-vector vector.
Definition: VectorBackend.hpp:60
Contains all classes needed for solving linear and non linear equation systems.
Definition: AdaptBase.hpp:6
BaseVector const & vector() const
Return the data-vector vector.
Definition: VectorBackend.hpp:54
std::size_t size() const
Return the current size of the vector_.
Definition: VectorBackend.hpp:66
value_type & at(MultiIndex const &idx)
Access the entry idx of the vector_ with write-access.
Definition: VectorBackend.hpp:83
typename block_type::field_type field_type
The underlying field type.
Definition: VectorBackend.hpp:40
Dune::BlockVector< typename BlockVectorType< T >::type > BaseVector
The vector type of the underlying base vector.
Definition: VectorBackend.hpp:31
CRTP base class for flat vector backends.
Definition: VectorBase.hpp:15
typename BaseVector::block_type block_type
The type of the elements of the DOFVector.
Definition: VectorBackend.hpp:34
void init(SizeInfo const &sizeInfo, bool clear)
Resize the vector_ to the size given by the sizeProvider.
Definition: VectorBackend.hpp:74
Definition: VectorBackend.hpp:14
typename BaseVector::size_type size_type
The index/size - type.
Definition: VectorBackend.hpp:43
value_type const & at(MultiIndex const &idx) const
Access the entry idx of the vector_ with read-access.
Definition: VectorBackend.hpp:90
Definition: VectorBackend.hpp:26