DUNE-ACFEM (2.5.1)

Dune::ACFem::BulkBlockConstraints< JacobianOperator, Traits > Class Template Reference

A default implementation for bulk block constraints. More...

#include <dune/acfem/operators/constraints/bulkblockconstraints.hh>

+ Collaboration diagram for Dune::ACFem::BulkBlockConstraints< JacobianOperator, Traits >:

Public Member Functions

 BulkBlockConstraints (const DiscreteFunctionType &values, const std::vector< unsigned > &mask)
 Explicitly set the constraints to defined values.
 
 BulkBlockConstraints (const DiscreteFunctionSpaceType &space)
 Construct an empty operator.
 
void rebuild () const
 An update method which has to be called initially or after mesh-adaptation, or for time-dependent constraint values to recompute the affine offset when moving to the next time-step.
 
void operator() (const DiscreteFunctionType &u, DiscreteFunctionType &w) const
 Apply the operator to the given argument. More...
 
void jacobian (const DiscreteFunctionType &u, JacobianOperatorType &jOp) const
 The Jacobian of the operator. More...
 
void constrain (DiscreteFunctionType &w) const
 The solution operator; unconditionally install the given constraints into the argument. More...
 
void zeroConstrain (DiscreteFunctionType &w) const
 Unconditionally set the values of all masked DoFs to zero.
 
void jacobian (const DiscreteFunctionType &u, JacobianOperatorType &jOp) const
 The Jacobian of the operator. More...
 
void constrain (DiscreteFunctionType &w) const
 The solution operator; unconditionally install the given constraints into the argument. More...
 
void zeroConstrain (DiscreteFunctionType &w) const
 Unconditionally set the values of all masked DoFs to zero.
 
void operator() (const DiscreteFunctionType &arg, DiscreteFunctionType &w) const
 Apply the operator to the given argument. More...
 

Detailed Description

template<class JacobianOperator, class Traits = BulkBlockConstraintsDefaultTraits<JacobianOperator>>
class Dune::ACFem::BulkBlockConstraints< JacobianOperator, Traits >

A default implementation for bulk block constraints.

BulkBlockConstraints maintain a flag vector of masked-out DoFs and a DiscreteFunction which contains the values the masked-out DoFs are constrained to. Despite their name currently this class also serves as base for the DirichletBlockConstraints class. The implementation should be fairly efficient, but at the cost of the memory overhead caused by storing the constaint-values in an ordinary Dune::Fem::DiscreteFunction. We only implement the differentiable variant which needs a JacobianOperator (typically a matrix-class) as template argument.

Member Function Documentation

◆ constrain() [1/2]

void Dune::ACFem::BlockConstraintsOperatorInterface< DiscreteFunction, BulkBlockConstraintsDefaultTraits< JacobianOperator > >::constrain ( DiscreteFunctionType &  w) const
inlineinherited

The solution operator; unconditionally install the given constraints into the argument.

This "solves"

\[ w - g = 0 \]

for w.

◆ constrain() [2/2]

template<class JacobianOperator , class Traits = BulkBlockConstraintsDefaultTraits<JacobianOperator>>
void Dune::ACFem::BulkBlockConstraints< JacobianOperator, Traits >::constrain ( DiscreteFunctionType &  w) const
inline

The solution operator; unconditionally install the given constraints into the argument.

This "solves"

\[ w - g = 0 \]

for w.

References Dune::ACFem::DifferentiableBlockConstraintsOperatorInterface< JacobianOperator, Traits >::rebuild().

◆ jacobian() [1/2]

void Dune::ACFem::DifferentiableBlockConstraintsOperatorInterface< JacobianOperator, BulkBlockConstraintsDefaultTraits< JacobianOperator > >::jacobian ( const DiscreteFunctionType &  u,
JacobianOperatorType &  jOp 
) const
inlineinherited

The Jacobian of the operator.

As the operator acts as identity minus affine offset, the Jacobian acts as identity. The methods does not alter any lines of jOp except for the "active" DoFs. The method handles slave-DoFs correctly in parallel runs.

◆ jacobian() [2/2]

template<class JacobianOperator , class Traits = BulkBlockConstraintsDefaultTraits<JacobianOperator>>
void Dune::ACFem::BulkBlockConstraints< JacobianOperator, Traits >::jacobian ( const DiscreteFunctionType &  u,
JacobianOperatorType &  jOp 
) const
inline

The Jacobian of the operator.

As the operator acts as identity minus affine offset, the Jacobian acts as identity. The methods does not alter any lines of jOp except for the "active" DoFs. The method handles slave-DoFs correctly in parallel runs.

References Dune::ACFem::DifferentiableBlockConstraintsOperatorInterface< JacobianOperator, Traits >::rebuild().

◆ operator()() [1/2]

void Dune::ACFem::BlockConstraintsOperatorInterface< JacobianOperator::RangeFunctionType , BulkBlockConstraintsDefaultTraits< JacobianOperator > >::operator() ( const DiscreteFunctionType &  arg,
DiscreteFunctionType &  w 
) const
inlineinherited

Apply the operator to the given argument.

This operates as as an affine linear operator which computes

\[ \Gamma(x) = x - g \]

where g defines the affine offet. TZhe operator acts only on the given subset of "active" DoFs (e.g. the boundary DoFs) and leaves all other values of w alone.

◆ operator()() [2/2]

template<class JacobianOperator , class Traits = BulkBlockConstraintsDefaultTraits<JacobianOperator>>
void Dune::ACFem::BulkBlockConstraints< JacobianOperator, Traits >::operator() ( const DiscreteFunctionType &  u,
DiscreteFunctionType &  w 
) const
inline

Apply the operator to the given argument.

This operates as as an affine linear operator which computes

\[ \Gamma(x) = x - g \]

where g defines the affine offet. TZhe operator acts only on the given subset of "active" DoFs (e.g. the boundary DoFs) and leaves all other values of w alone.

References Dune::ACFem::DifferentiableBlockConstraintsOperatorInterface< JacobianOperator, Traits >::rebuild().


The documentation for this class was generated from the following file:
Creative Commons License   |  Legal Statements / Impressum  |  Hosted by TU Dresden  |  generated with Hugo v0.111.3 (Nov 12, 23:30, 2024)