ryujin 2.1.1 revision 46bf70e400e423a8ffffe8300887eeb35b8dfb2c
Classes | Public Member Functions | List of all members
ryujin::Discretization< dim > Class Template Reference

#include <source/discretization.h>

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

Classes

struct  Collection
 

Public Member Functions

 Discretization (const MPIEnsemble &mpi_ensemble, const std::string &subsection="/Discretization")
 
void prepare (const std::string &base_name)
 
Accessors to data structures managed by this class.
const auto & selected_geometry () const
 
const auto & ansatz () const
 
bool have_discontinuous_ansatz () const
 
unsigned int polynomial_degree () const
 
const auto & triangulation () const
 

Internal data:

template<typename Discretization , int dim_, typename Number_ >
class SolutionTransfer
 
template<int dim_>
class Geometry
 

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 220 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.

Definition at line 31 of file discretization.template.h.

References ryujin::cg_q1, ryujin::parallel_distributed, and ryujin::parallel_shared.

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.

Definition at line 81 of file discretization.template.h.

References ryujin::parallel_distributed, ryujin::parallel_fullydistributed, ryujin::parallel_shared, and ryujin::serial.

◆ selected_geometry()

template<int dim>
const auto & ryujin::Discretization< dim >::selected_geometry ( ) const
inline

Return a read-only const reference to the selected geometry.

Definition at line 262 of file discretization.h.

◆ ansatz()

template<int dim>
const auto & ryujin::Discretization< dim >::ansatz ( ) const
inline

Return a read-only const reference to the finite element ansatz.

Definition at line 267 of file discretization.h.

◆ have_discontinuous_ansatz()

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

Return a boolean indicating whether the chosen Ansatz space is discontinuous.

Definition at line 273 of file discretization.h.

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

◆ 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 300 of file discretization.h.

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

◆ triangulation()

template<int dim>
const auto & ryujin::Discretization< dim >::triangulation ( ) const
inline

Return a mutable reference to the refinement variable. Return a mutable reference to the triangulation. Return a read-only const reference to the triangulation.

Definition at line 334 of file discretization.h.

Friends And Related Function Documentation

◆ SolutionTransfer

template<int dim>
template<typename Discretization , int dim_, typename Number_ >
friend class SolutionTransfer
friend

In the SolutionTransfer class we need writable access to the triangulation object in order to prepare data for mesh adaptation and checkpointing / restart. Work around this issue by declaring the solution transfer class to be a friend rather than changing the constructor, or augmenting the methods in SolutionTransfer.

Definition at line 444 of file discretization.h.

◆ Geometry

template<int dim>
template<int dim_>
friend class Geometry
friend

For complex geometries with mixed finite elements (or when using FE_Nothing) we need to defer the setup of the hp::*Collection objects to the selected geometry. Thus, declare the Geometry class to be a friend so that it can set all the collection objects directly.

Definition at line 454 of file discretization.h.


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