SpECTRE  2021.08.02
NewtonianEuler::subcell::TciOnDgGrid< Dim > Class Template Reference

Troubled-cell indicator applied to the DG solution. More...

#include <TciOnDgGrid.hpp>

Public Types

using return_tags = tmpl::list<::Tags::Variables< tmpl::list< MassDensity, Velocity, SpecificInternalEnergy, Pressure > > >
 
using argument_tags = tmpl::list< MassDensityCons, MomentumDensity, EnergyDensity, hydro::Tags::EquationOfStateBase, domain::Tags::Mesh< Dim > >
 

Static Public Member Functions

template<size_t ThermodynamicDim>
static bool apply (const gsl::not_null< Variables< tmpl::list< MassDensity, Velocity, SpecificInternalEnergy, Pressure > > * > dg_prim_vars, const Scalar< DataVector > &mass_density, const tnsr::I< DataVector, Dim, Frame::Inertial > &momentum_density, const Scalar< DataVector > &energy_density, const EquationsOfState::EquationOfState< false, ThermodynamicDim > &eos, const Mesh< Dim > &dg_mesh, const double persson_exponent) noexcept
 

Detailed Description

template<size_t Dim>
class NewtonianEuler::subcell::TciOnDgGrid< Dim >

Troubled-cell indicator applied to the DG solution.

Computes the primitive variables on the DG grid, mutating them in the DataBox. Then,

  • if the minimum density or pressure are below \(10^{-18}\) (the arbitrary threshold used to signal "negative" density and pressure), marks the element as troubled and returns
  • runs the Persson TCI on the density and pressure. The reason for applying the Persson TCI to both the density and pressure is to flag cells at contact discontinuities.