2D Euler Double Mach Reflection#
This problem solves the 2D conservative Euler equations
where the pressure \(p\) is related to the conserved quantities through the equation of the state
By default, \(\gamma = 1.4\)
Initial condition is a Mach 10 shock tilted by an angle, see reference paper above.
Domain is \([0, 4]\times[0, 1]\). For BC see link above.
Typically, integration is performed for \(t \in (0, 0.25)\).
The problem is adopted from this paper
Warning
Currently, this problem only works for first order and Weno3 inviscid flux reconstruction.
Mesh#
python3 pressio-demoapps/meshing_scripts/create_full_mesh_for.py \
--problem doublemach2d_s<stencilSize> -n Nx Ny --outDir <destination-path>
where
Nx, Ny
is the number of cells you want along \(x\) and \(y\) respectively<stencilSize> = 3 or 5
: defines the neighboring connectivity of each cell<destination-path>
is where you want the mesh files to be generated. The script creates the directory if it does not exist.
Important
When you set the <stencilSize>
, keep in mind the following constraints (more on this below):
InviscidFluxReconstruction::FirstOrder
requires<stencilSize> >= 3
InviscidFluxReconstruction::Weno3
requires<stencilSize> >= 5
C++ synopsis#
#include "pressiodemoapps/euler2d.hpp"
int main(){
namespace pda = pressiodemoapps;
const auto meshObj = pda::load_cellcentered_uniform_mesh_eigen("path-to-mesh");
const auto probId = pda::Euler2d::DoubleMachReflection;
const auto scheme = pda::InviscidFluxReconstruction::FirstOrder; //or Weno3
auto problem = pda::create_problem_eigen(meshObj, probId, scheme);
auto state = problem.initialCondition();
}
Python synopsis#
import pressiodemoapps as pda
meshObj = pda.load_cellcentered_uniform_mesh("path-to-mesh")
probId = pda.Euler2d.DoubleMachReflection
scheme = pda.InviscidFluxReconstruction.FirstOrder # or Weno3
problem = pda.create_problem(meshObj, probId, scheme)
state = problem.initialCondition()
Sample Plot#
Representative density plot at \(t=0.25\) using a 600x150
mesh with Weno3
and SSPRK3 time integration: