ryujin 2.5.0 revision c64172211cf21344cb9b9b0f3a1266aa6400d392
Loading...
Searching...
No Matches
Classes | List of all members
ryujin::Discretization< dim > Class Template Referencefinal

#include <include/ryujin/discretization/discretization.h>

Inheritance diagram for ryujin::Discretization< dim >:
Inheritance graph
[legend]
Collaboration diagram for ryujin::Discretization< dim >:
Collaboration graph
[legend]

Classes

struct  Collection
 

Public Types

Typedefs and constexpr constants
using Transformation = std::function< dealii::Point< dim >(const typename dealii::Triangulation< dim >::cell_iterator &, const dealii::Point< dim > &)>
 

Public Member Functions

Constructor and setup
 Discretization (const MPIEnsemble &mpi_ensemble, const std::string &subsection="/Discretization")
 
void prepare (const std::string &base_name)
 
void update_mapping ()
 
Information and statistics
bool have_discontinuous_ansatz () const
 
unsigned int polynomial_degree () const
 
bool has_triangulation () const
 
const dealii::hp::FECollection< dim > & finite_element () const
 

Detailed Description

template<int dim>
class ryujin::Discretization< dim >

This class is as a container for data related to the discretization, this includes the triangulation, finite element, mapping, and quadrature. After prepare() is called, the getter functions Discretization::triangulation(), Discretization::finite_element(), Discretization::mapping(), and Discretization::quadrature() return valid const references to the mentioned objects.

The class uses dealii::ParameterAcceptor to handle a multitude of parameters to control the creation of meshes for a variety of benchmark configurations and to read in meshes in one of the formats supported by the deal.II library.

Definition at line 243 of file discretization.h.

Member Typedef Documentation

◆ Transformation

template<int dim>
using ryujin::Discretization< dim >::Transformation = std::function<dealii::Point<dim>( const typename dealii::Triangulation<dim>::cell_iterator &, const dealii::Point<dim> &)>

A forward transformation that maps points of the triangulation to the actual geometry, see Geometry::transformation().

Definition at line 276 of file discretization.h.

Constructor & Destructor Documentation

◆ Discretization()

template<int dim>
ryujin::Discretization< dim >::Discretization ( const MPIEnsemble &  mpi_ensemble,
const std::string &  subsection = "/Discretization< dim >" 
)

Constructor.

Member Function Documentation

◆ prepare()

template<int dim>
void ryujin::Discretization< dim >::prepare ( const std::string &  base_name)

Create the triangulation and set up the finite element, mapping and quadrature objects.

◆ update_mapping()

template<int dim>
void ryujin::Discretization< dim >::update_mapping ( )

Recompute the cached mapping after the triangulation, or the transformation(), has changed.

The mapping is a MappingQCache if the selected geometry provides a Geometry::transformation(), or once a transformation has been set.

◆ have_discontinuous_ansatz()

template<int dim>
bool ryujin::Discretization< dim >::have_discontinuous_ansatz ( ) const
inline

Return a read-only const reference to the selected geometry. Return a read-only const reference to the finite element ansatz. Return a boolean indicating whether the chosen Ansatz space is discontinuous.

Definition at line 327 of file discretization.h.

References ryujin::cg_q1, ryujin::cg_q2, ryujin::cg_q3, ryujin::dg_q1, ryujin::dg_q2, and ryujin::dg_q3.

Referenced by ryujin::Discretization< dim >::finite_element().

◆ polynomial_degree()

template<int dim>
unsigned int ryujin::Discretization< dim >::polynomial_degree ( ) const
inline

Return the polynomial degree of the chosen finite element ansatz.

Definition at line 354 of file discretization.h.

References ryujin::cg_q1, ryujin::cg_q2, ryujin::cg_q3, ryujin::dg_q1, ryujin::dg_q2, and ryujin::dg_q3.

◆ has_triangulation()

template<int dim>
bool ryujin::Discretization< dim >::has_triangulation ( ) const
inline

Return a mutable reference to the refinement variable. Return whether prepare() has created the triangulation.

Definition at line 383 of file discretization.h.

◆ finite_element()

template<int dim>
const dealii::hp::FECollection< dim > & ryujin::Discretization< dim >::finite_element ( ) const
inline

Return a mutable reference to the triangulation. Return a read-only const reference to the triangulation. Return a mutable reference to the transformation used for the MappingQCache object.

Note
The transformation will be set initially during the prepare() call provided the selected geometry sets Geometry::transformation(). An empty transformation is treated as the identity.
After updating the transformation a call to update_mapping() is required to reinitialize the underlying MappingQCache. Return a read-only const reference to the transformation. Return a read-only const reference to the mapping.
The accessor returns an MappingCollection object. Return a read-only const reference to a continuous ("cG") variant of the selected finite element space.
If the selected finite element space is continuous then this method simply returns the same object as finite_element().
The accessor returns an FECollection object. Return a read-only const reference to a discontinuous ("dG") variant of the selected finite element space.
If the selected finite element space is discontinuous then this method simply returns the same object as finite_element().
The accessor returns an FECollection object. Return a read-only const reference to the selected finite element.
The accessor returns an FECollection object.

Definition at line 451 of file discretization.h.

References ryujin::Discretization< dim >::Collection::finite_element_cg, ryujin::Discretization< dim >::Collection::finite_element_dg, and ryujin::Discretization< dim >::have_discontinuous_ansatz().


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