[P]arallel [Hi]gh-order [Li]brary for [P]DEs  Latest
Parallel High-Order Library for PDEs through hp-adaptive Discontinuous Galerkin methods
positivity_preserving_tests.h
1 #ifndef __POSITIVITY_TESTS_H__
2 #define __POSITIVITY_TESTS_H__
3 
4 #include "flow_solver_case_base.h"
5 #include "cube_flow_uniform_grid.h"
6 #include "dg/dg_base.hpp"
7 
8 namespace PHiLiP {
9 namespace FlowSolver {
10 
11 template <int dim, int nstate>
13 {
14 #if PHILIP_DIM==1
15  using Triangulation = dealii::Triangulation<PHILIP_DIM>;
16  #else
17  using Triangulation = dealii::parallel::distributed::Triangulation<PHILIP_DIM>;
18  #endif
19 
20  public:
22  explicit PositivityPreservingTests(const Parameters::AllParameters *const parameters_input);
23 
25  std::shared_ptr<Triangulation> generate_grid() const override;
26 
29 
30  protected:
33 
36 
39 
42 
45 
48 
52  const std::shared_ptr<ODE::ODESolverBase<dim, double>> ode_solver,
53  const std::shared_ptr <DGBase<dim, double>> dg,
54  const std::shared_ptr<dealii::TableHandler> unsteady_data_table) override;
55 
56  private:
59 
62 
65 
66  // euler physics pointer for computing physical quantities.
67  std::shared_ptr < Physics::Euler<dim, nstate, double > > euler_physics;
68 
69 };
70 
71 } // FlowSolver namespace
72 } // PHiLiP namespace
73 
74 #endif
void check_positivity_density(DGBase< dim, double > &dg)
Check positivity of density and total energy + verify that density is not NaN.
void compute_unsteady_data_and_write_to_table(const std::shared_ptr< ODE::ODESolverBase< dim, double >> ode_solver, const std::shared_ptr< DGBase< dim, double >> dg, const std::shared_ptr< dealii::TableHandler > unsteady_data_table) override
Compute the desired unsteady data and write it to a table.
double initial_entropy
Storing entropy at first step.
Files for the baseline physics.
Definition: ADTypes.hpp:10
Base class ODE solver.
double compute_integrated_entropy(DGBase< dim, double > &dg) const
Updates the maximum local wave speed.
Main parameter class that contains the various other sub-parameter classes.
PositivityPreservingTests(const Parameters::AllParameters *const parameters_input)
Constructor.
double maximum_local_wave_speed
Maximum local wave speed (i.e. convective eigenvalue)
const std::string unsteady_data_table_filename_with_extension
Filename (with extension) for the unsteady data table.
DGBase is independent of the number of state variables.
Definition: dg_base.hpp:82
void display_additional_flow_case_specific_parameters() const override
Display additional more specific flow case parameters.
std::shared_ptr< Triangulation > generate_grid() const override
Function to generate the grid.