DiFfRG
Loading...
Searching...
No Matches
DiFfRG::HAdaptivity< Assembler > Class Template Reference

Implement a simple interface to do all adaptivity tasks, i.e. solution transfer, reinit of dofHandlers, etc. More...

#include <h_adaptivity.hh>

Inheritance diagram for DiFfRG::HAdaptivity< Assembler >:
DiFfRG::AbstractAdaptor< Assembler::Discretization::VectorType >

Public Member Functions

 HAdaptivity (Assembler &assembler, const JSONValue &json)
 
virtual bool operator() (const double t, VectorType &sol) override
 Check if an adaptation step should be done and tranfer the given solution to the new mesh.
 
virtual bool adapt (VectorType &solution) override
 Force an adaptation and transfer the solution sol to the new mes.
 
- Public Member Functions inherited from DiFfRG::AbstractAdaptor< Assembler::Discretization::VectorType >
virtual bool operator() (const double t, VectorType &sol)=0
 Check if an adaptation step should be done and tranfer the given solution to the new mesh.
 
virtual bool adapt (VectorType &solution)=0
 Force an adaptation and transfer the solution sol to the new mes.
 

Protected Attributes

Assembler & assembler
 
Discretizationdiscretization
 
VectorType indicator
 
double last_adapt
 
double adapt_t
 
double adapt_dt
 
double adapt_upper
 
double adapt_lower
 
uint adapt_level
 

Private Types

using Discretization = typename Assembler::Discretization
 
using VectorType = typename Discretization::VectorType
 

Static Private Attributes

static constexpr uint dim = Discretization::dim
 

Detailed Description

template<typename Assembler>
class DiFfRG::HAdaptivity< Assembler >

Implement a simple interface to do all adaptivity tasks, i.e. solution transfer, reinit of dofHandlers, etc.

Template Parameters
AssemblerThe used assembler should implement the methods refinement_indicator and reinit

Member Typedef Documentation

◆ Discretization

template<typename Assembler >
using DiFfRG::HAdaptivity< Assembler >::Discretization = typename Assembler::Discretization
private

◆ VectorType

template<typename Assembler >
using DiFfRG::HAdaptivity< Assembler >::VectorType = typename Discretization::VectorType
private

Constructor & Destructor Documentation

◆ HAdaptivity()

template<typename Assembler >
DiFfRG::HAdaptivity< Assembler >::HAdaptivity ( Assembler & assembler,
const JSONValue & json )
inline

Member Function Documentation

◆ adapt()

template<typename Assembler >
virtual bool DiFfRG::HAdaptivity< Assembler >::adapt ( VectorType & solution)
inlineoverridevirtual

Force an adaptation and transfer the solution sol to the new mes.

Parameters
solutionto be transferred

◆ operator()()

template<typename Assembler >
virtual bool DiFfRG::HAdaptivity< Assembler >::operator() ( const double t,
VectorType & sol )
inlineoverridevirtual

Check if an adaptation step should be done and tranfer the given solution to the new mesh.

Parameters
tCurrent time; at adapt_dt time distances we perform an adaptation
solCurrent solution
Returns
true if adapation has happened, false otherwise

Member Data Documentation

◆ adapt_dt

template<typename Assembler >
double DiFfRG::HAdaptivity< Assembler >::adapt_dt
protected

◆ adapt_level

template<typename Assembler >
uint DiFfRG::HAdaptivity< Assembler >::adapt_level
protected

◆ adapt_lower

template<typename Assembler >
double DiFfRG::HAdaptivity< Assembler >::adapt_lower
protected

◆ adapt_t

template<typename Assembler >
double DiFfRG::HAdaptivity< Assembler >::adapt_t
protected

◆ adapt_upper

template<typename Assembler >
double DiFfRG::HAdaptivity< Assembler >::adapt_upper
protected

◆ assembler

template<typename Assembler >
Assembler& DiFfRG::HAdaptivity< Assembler >::assembler
protected

◆ dim

template<typename Assembler >
uint DiFfRG::HAdaptivity< Assembler >::dim = Discretization::dim
staticconstexprprivate

◆ discretization

template<typename Assembler >
Discretization& DiFfRG::HAdaptivity< Assembler >::discretization
protected

◆ indicator

template<typename Assembler >
VectorType DiFfRG::HAdaptivity< Assembler >::indicator
protected

◆ last_adapt

template<typename Assembler >
double DiFfRG::HAdaptivity< Assembler >::last_adapt
protected

The documentation for this class was generated from the following file: