JumpIndicator< dim, number, n_mf_components, n_relevant_components > Class Template Reference
|
Developer Documentation
|
#include <amr_indicators.hpp>
Public Types | |
| using | VectorizedArrayType = dealii::VectorizedArray< number > |
| using | VectorType = dealii::LinearAlgebra::distributed::Vector< number > |
| using | ExtractIndicatorDofValuesFunction = std::function< dealii::Tensor< 1, n_relevant_components, VectorizedArrayType >(const dealii::Tensor< 1, n_mf_components, VectorizedArrayType > &)> |
Public Member Functions | |
| JumpIndicator (const MatrixFreeContext< dim, number > matrix_free_context, const VectorType &solution, const ExtractIndicatorDofValuesFunction extract_indicator_dof_values, const unsigned fe_index=0) | |
| dealii::Vector< number > | compute_indicator (const dealii::Triangulation< dim > &tria) override |
Public Member Functions inherited from MeltPoolDG::AMR::AMRIndicatorBase< dim, number > | |
| virtual | ~AMRIndicatorBase ()=default |
Protected Member Functions | |
| void | local_apply_face (const dealii::MatrixFree< dim, number > &, dealii::AlignedVector< VectorizedArrayType > &dst, const VectorType &src, const std::pair< unsigned, unsigned > &face_range) const |
Private Attributes | |
| const MatrixFreeContext< dim, number > | matrix_free_context |
| Matrix free object used to compute the solution. | |
| const VectorType & | solution |
| Reference to the solution of the field of interest. | |
| ExtractIndicatorDofValuesFunction | extract_indicator_dof_values |
| const unsigned | fe_index |
| Relevant fe index for the fe object of the dof handler in the matrix free object. | |
Detailed Description
class MeltPoolDG::AMR::JumpIndicator< dim, number, n_mf_components, n_relevant_components >
Jump indicator based on the description in
F. Basile et al, A high-order h-adaptive discontinuous Galerkin method for unstructured grids based on a posteriori error estimation. https://arc.aiaa.org/doi/10.2514/6.2021-1696
Assuming a continuous exact solution, the idea is to express the error in terms of the jump between elements normalized by the corresponding face area.
- Template Parameters
-
dim Spatial dimension of the problem. number Scalar type of the solution vector and underlying matrix-free data structures (e.g., float, double). n_dof_components Number of field components provided by the finite element at each point. This must match the number of components returned by dealii::FEEvaluation::get_value() for the matrix-free object passed to the constructor. n_indicator_components Number of components (out of the n_dof_componentsavailable) that are used in the indicator computation. A custom extraction function maps the full set of DoF values to these selected components.
- Note
- Indicator can only be used for DG.
Member Typedef Documentation
◆ ExtractIndicatorDofValuesFunction
| using MeltPoolDG::AMR::JumpIndicator< dim, number, n_mf_components, n_relevant_components >::ExtractIndicatorDofValuesFunction = std::function<dealii::Tensor<1, n_relevant_components, VectorizedArrayType>( const dealii::Tensor<1, n_mf_components, VectorizedArrayType> &)> |
◆ VectorizedArrayType
| using MeltPoolDG::AMR::JumpIndicator< dim, number, n_mf_components, n_relevant_components >::VectorizedArrayType = dealii::VectorizedArray<number> |
◆ VectorType
| using MeltPoolDG::AMR::JumpIndicator< dim, number, n_mf_components, n_relevant_components >::VectorType = dealii::LinearAlgebra::distributed::Vector<number> |
Constructor & Destructor Documentation
◆ JumpIndicator()
| MeltPoolDG::AMR::JumpIndicator< dim, number, n_dof_components, n_indicator_components >::JumpIndicator | ( | const MatrixFreeContext< dim, number > | matrix_free_context, |
| const VectorType & | solution, | ||
| const ExtractIndicatorDofValuesFunction | extract_indicator_dof_values, | ||
| const unsigned | fe_index = 0 |
||
| ) |
Constructor.
Initializes the indicator by storing references to the provided data.
- Parameters
-
matrix_free_context Matrix-free context associated with the provided solution vector. solution Solution vector from which the indicator is computed. extract_indicator_dof_values A function object used to extract the subset of DoF values relevant for the indicator. The function receives, for each vectorized set of quadrature points, the full n_dof_componentstensor of values from dealii::FEEvaluation::get_value(), and must return then_indicator_componentsvalues to be used by the indicator. The function may also modify or combine the values if needed.fe_index Index of the finite element associated with the matrix-free context. fe_degree Polynomial degree of the finite element shape functions.
Member Function Documentation
◆ compute_indicator()
|
overridevirtual |
Computes the indicator as discussed in the class description.
- Parameters
-
tria Triangulation for which the indicator is computed.
Implements MeltPoolDG::AMR::AMRIndicatorBase< dim, number >.
◆ local_apply_face()
|
protected |
The actual logic of the jump indicator performed in each cell in a matrix free loop.
- Note
- This is protected such that a combined indicator with additional cell or boundary face loop can be directly derived from this class.
Member Data Documentation
◆ extract_indicator_dof_values
|
private |
Function type used to extract or manipulate the subset of DoF values needed by the indicator. This function needs to be provided by the user.
◆ fe_index
|
private |
Relevant fe index for the fe object of the dof handler in the matrix free object.
◆ matrix_free_context
|
private |
Matrix free object used to compute the solution.
◆ solution
|
private |
Reference to the solution of the field of interest.
The documentation for this class was generated from the following files:
- include/meltpooldg/utilities/amr_indicators.hpp
- include/meltpooldg/utilities/amr_indicators.templates.hpp
Generated by
Public Member Functions inherited from