![]() |
Dune-Fufem 2.11-git
|
Loading...
Searching...
No Matches
affineconstraints.hh
Go to the documentation of this file.
220 static_assert(Dune::AlwaysFalse<OtherMultiIndex>::value, "Value cannot be converted to MultiIndex type");
286 using LinearTerm = std::unordered_map<MultiIndex, LinearTermRow, MultiIndexHash, MultiIndexEquals>;
834 return Dune::Functions::makeContainer<char>(basis.rootBasis().preBasis().containerDescriptor(), false);
836 if constexpr(std::is_same_v<typename Basis::MultiIndex, Dune::Functions::StaticMultiIndex<std::size_t, 1>>)
854 return Dune::Functions::makeISTLVector<Coefficient>(basis.rootBasis().preBasis().containerDescriptor());
856 if constexpr(std::is_same_v<typename Basis::MultiIndex, Dune::Functions::StaticMultiIndex<std::size_t, 1>>)
872 static_assert(not std::is_same_v<GeneratedBitVector, std::monostate>, "Deducing a BitVector-type for non-flat indices in makeAffineConstraints requires dune-functions>=2.11.");
873 static_assert(not std::is_same_v<GeneratedVector, std::monostate>, "Deducing a Vector-type for non-flat indices in makeAffineConstraints requires dune-functions>=2.11.");
874 return AffineConstraints<GeneratedBitVector, GeneratedVector, MultiIndex, Coefficient>(generateBitVector(), generateVector());
Col col
void seed(const Vertex &vertex)
auto istlVectorBackend(Vector &v)
int size() const
void clear()
bool equals(const SLListConstIterator< T, A > &other) const
auto transformedRangeView(R &&range, F &&f)
static constexpr IntegralRange< std::decay_t< T > > range(T &&from, U &&to) noexcept
std::ptrdiff_t index() const
virtual void operator()()=0
void hash_combine(std::size_t &seed, const T &arg)
auto makeAffineConstraints(const Basis &basis)
Create and initialize an AffineConstraints object for a basis.
Definition affineconstraints.hh:825
STL namespace.
Definition dunefunctionsboundaryfunctionalassembler.hh:29
void mmv(const X &x, Y &y) const
Class to handle affine constraints on a subset of DOFs.
Definition affineconstraints.hh:201
void constrainVectorHomogeneously(Vector &b) const
Constrain vector to a constrained basis.
Definition affineconstraints.hh:658
AffineConstraints(const BitVector &isConstrained, const Vector &constantTerm)
Construct from bit vector and vector.
Definition affineconstraints.hh:306
AffineConstraints(const AffineConstraints &)=default
LinearTerm & linearTerm()
Mutable access to linear part of affine map.
Definition affineconstraints.hh:357
void resolveDependencies()
Resolve dependencies of constrained DOFs on other constrained DOFs.
Definition affineconstraints.hh:756
void constrainMatrix(Matrix &A) const
Constrain matrix to a constrained basis.
Definition affineconstraints.hh:597
const auto & constantTerm(const MultiIndexType &i) const
Const access to i-th row of constant part of affine map.
Definition affineconstraints.hh:412
void report() const
Report the constraints to std::cout.
Definition affineconstraints.hh:708
AffineConstraints(BitVector &&isConstrained, Vector &&constantTerm)
Construct from bit vector and vector.
Definition affineconstraints.hh:298
std::map< MI, Coefficient > LinearTermRow
Definition affineconstraints.hh:285
AffineConstraints()=default
const LinearTermRow & linearTerm(const MultiIndexType &i) const
Const access to i-th row of linear part of affine map.
Definition affineconstraints.hh:374
const LinearTerm & linearTerm() const
Const access to linear part of affine map.
Definition affineconstraints.hh:344
void extendMatrixPattern(MatrixPatternBackend &patternBackend, const Basis &basis) const
Extend matrix pattern for a constrained basis.
Definition affineconstraints.hh:491
void constrainVector(Vector &b) const
Constrain vector to a constrained basis.
Definition affineconstraints.hh:635
bool check() const
Check constraints for consistency.
Definition affineconstraints.hh:728
bool isConstrained(const MultiIndexType &i) const
Check if i-th DOF is constrained.
Definition affineconstraints.hh:315
const BitVector & isConstrained() const
Const access to bit-vector marking constrained DOFs.
Definition affineconstraints.hh:323
const ConstantTerm & constantTerm() const
Const access to constant part of affine map.
Definition affineconstraints.hh:389
BitVector & isConstrained()
Mutable access to bit-vector marking constrained DOFs.
Definition affineconstraints.hh:331
void interpolate(Vector &v) const
Interpolate vector according to affine constraints.
Definition affineconstraints.hh:441
void constrainLinearSystem(Matrix &A, Vector &b) const
Constrain linear system affine subspace satisfying the constraints.
Definition affineconstraints.hh:681
void interpolateHomogeneously(Vector &v) const
Interpolate vector according to affine constraints.
Definition affineconstraints.hh:469
std::unordered_map< MultiIndex, LinearTermRow, MultiIndexHash, MultiIndexEquals > LinearTerm
Definition affineconstraints.hh:286
void constrainLinearSystemHomogeneously(Matrix &A, Vector &b) const
Constrain linear system affine subspace satisfying the constraints.
Definition affineconstraints.hh:699
ConstantTerm & constantTerm()
Mutable access to constant part of affine map.
Definition affineconstraints.hh:400
AffineConstraints(AffineConstraints &&)=default
auto & constantTerm(const MultiIndexType &i)
Mutable access to i-th row of constant part of affine map.
Definition affineconstraints.hh:424
T copy(T... args)
T end(T... args)
T endl(T... args)
T find(T... args)
T forward(T... args)
T is_same_v
T size(T... args)
T swap(T... args)
