Algorithm Search⌘K

Problemcore

Euler equations of gas dynamics

Also called compressible Euler equations.

The conservation laws of mass, momentum and energy of an inviscid compressible gas, closed by an equation of state.

The Euler equations of gas dynamics are the conservation laws of mass, momentum and energy for a compressible gas with no viscosity and no heat conduction. With an equation of state, usually the ideal gas law, they form a hyperbolic conservation law with three wave speeds u−cu - c, uu and u+cu + c in one space dimension. The problem is to compute their solution from given initial and boundary data, including shocks and contact discontinuities. They are the standard test system for shock capturing methods: the exact Riemann solver solves them for two constant states, the Godunov method builds a scheme on that solution, and the Sod shock tube is the first test of nearly every code. They are the limit of the Navier-Stokes equations when viscosity and heat conduction go to zero. They should not be confused with the incompressible Euler equations, where the density is constant and there is no sound speed.

In plain words

A gas has a density, a velocity and an energy at every point. The Euler equations say three things. Mass is not created. Momentum changes only by the pressure push of the gas around it. Energy changes only by the work the pressure does. A rule that gives the pressure from the density and the energy closes the system.

Disturbances in the gas travel as sound waves, which move at the speed of sound relative to the gas, and as contact surfaces, which move with the gas. Strong sound waves steepen into shocks, which are thin layers where the pressure and the density jump.

Definition

Unknowns. The density ρ\rho, the velocity uu, the pressure pp, and the total energy per unit volume E=ρe+12ρu2E = \rho e + \frac12\rho u^2, with ee the specific internal energy.

One space dimension. With U=(ρ,ρu,E)U = (\rho, \rho u, E),

Ut+F(U)x=0,F(U)=(ρuρu2+pu(E+p)).U_t + F(U)_x = 0, \qquad F(U) = \begin{pmatrix} \rho u \\ \rho u^2 + p \\ u(E + p) \end{pmatrix}.

Equation of state. For a polytropic ideal gas with ratio of specific heats γ>1\gamma > 1, p=(γ−1)ρep = (\gamma - 1)\rho e, so

E=pγ−1+12ρu2,c=γp/ρ.E = \frac{p}{\gamma - 1} + \frac12\rho u^2, \qquad c = \sqrt{\gamma p/\rho}.

For air, γ=1.4\gamma = 1.4. The specific entropy is S=cvlog⁡(p/ργ)S = c_v\log(p/\rho^\gamma) up to a constant.

Characteristic structure. Where ρ>0\rho > 0 and p>0p > 0, the Jacobian F′(U)F'(U) has the eigenvalues λ1=u−c\lambda_1 = u - c, λ2=u\lambda_2 = u, λ3=u+c\lambda_3 = u + c with right eigenvectors

r1=(1u−cH−uc),r2=(1u12u2),r3=(1u+cH+uc),r_1 = \begin{pmatrix} 1 \\ u - c \\ H - uc \end{pmatrix}, \quad r_2 = \begin{pmatrix} 1 \\ u \\ \frac12u^2 \end{pmatrix}, \quad r_3 = \begin{pmatrix} 1 \\ u + c \\ H + uc \end{pmatrix},

where H=(E+p)/ρH = (E + p)/\rho is the specific enthalpy. The system is strictly hyperbolic. Fields 1 and 3 are genuinely nonlinear: they give shocks and rarefactions. Field 2 is linearly degenerate: it gives contact discontinuities, across which uu and pp are continuous and ρ\rho jumps (LeVeque 2002, Sections 14.3 to 14.8).

Several dimensions. With velocity u∈Rd\mathbf u \in \mathbb{R}^d, U=(ρ,ρu,E)U = (\rho, \rho\mathbf u, E) and

ρt+∇⋅(ρu)=0,(ρu)t+∇⋅(ρu⊗u+pI)=0,Et+∇⋅((E+p)u)=0.\rho_t + \nabla\cdot(\rho\mathbf u) = 0, \quad (\rho\mathbf u)_t + \nabla\cdot(\rho\mathbf u \otimes \mathbf u + pI) = 0, \quad E_t + \nabla\cdot\big((E + p)\mathbf u\big) = 0.

In direction nn the speeds are u⋅n±c\mathbf u\cdot n \pm c and u⋅n\mathbf u\cdot n, the last with multiplicity dd.

The computational problem. Given γ\gamma, initial data U0U_0 with ρ0>0\rho_0 > 0, p0>0p_0 > 0, boundary conditions and a final time TT, compute the admissible weak solution: a weak solution whose shocks satisfy the Rankine-Hugoniot conditions and the Lax entropy condition, which here means that the physical entropy SS increases across every shock.

Variants

  • Other equations of state. Stiffened gas p=(γ−1)ρe−γp∞p = (\gamma - 1)\rho e - \gamma p_\infty for liquids, van der Waals gases, and tabulated equations of state. They change cc and the Riemann solution, but not the conservation form.
  • Isentropic and isothermal Euler. If p=κργp = \kappa\rho^\gamma is imposed, the energy equation is dropped and the system has two equations. It has the same form as the shallow water equations, which are isentropic Euler with γ=2\gamma = 2 and κ=g/2\kappa = g/2.
  • Primitive variables. W=(ρ,u,p)W = (\rho, u, p) with Wt+A(W)Wx=0W_t + A(W)W_x = 0. This form is equivalent only for smooth solutions; a scheme for it does not give the right shocks (Toro 2009, Section 3.3).
  • With source terms. Gravity, chemical reactions (reactive Euler), and the quasi one dimensional nozzle equations with a variable area.
  • Relativistic and magnetohydrodynamic extensions. More equations and more waves, with the same structure of a hyperbolic system.

Examples

The Sod shock tube. γ=1.4\gamma = 1.4, (ρ,u,p)=(1,0,1)(\rho, u, p) = (1, 0, 1) for x<0x < 0 and (0.125,0,0.1)(0.125, 0, 0.1) for x>0x > 0 (Sod 1978). The exact Riemann solver gives the star state p∗=0.30313p_* = 0.30313, u∗=0.92745u_* = 0.92745, with ρ∗L=0.42632\rho_{*L} = 0.42632 to the left of the contact and ρ∗R=0.26557\rho_{*R} = 0.26557 to the right. The waves are:

  • a left rarefaction from x/t=−cL=−1.18322x/t = -c_L = -1.18322 to x/t=u∗−c∗L=−0.07027x/t = u_* - c_{*L} = -0.07027, where c∗L=1.4⋅0.30313/0.42632=0.99772c_{*L} = \sqrt{1.4 \cdot 0.30313/0.42632} = 0.99772;
  • a contact at x/t=u∗=0.92745x/t = u_* = 0.92745;
  • a right shock at x/t=1.75216x/t = 1.75216.

The entropy check: p/ργp/\rho^\gamma is 1.01.0 on the left and in the rarefaction, 1.939901.93990 just right of the contact, and 1.837921.83792 in the undisturbed right state. So it is constant through the rarefaction, jumps at the contact, and increases from 1.837921.83792 to 1.939901.93990 across the shock. These values come from the reference code of the exact Riemann solver page; they are a measurement to five digits. The page on the Rankine-Hugoniot conditions checks the three jump conditions at this shock.

A contact alone. ρL=1\rho_L = 1, ρR=0.5\rho_R = 0.5, u=0.3u = 0.3 and p=1p = 1 everywhere. The exact solution is the jump in ρ\rho moving at speed 0.30.3. Any consistent conservative scheme with a positive diffusion smears this jump, and the smearing grows with time, because a contact is not self steepening.

Vacuum generation. Two gases moving apart fast enough leave a vacuum between them. For the Sod sound speeds, this happens when uR−uL≥2γ−1(cL+cR)=11.20758u_R - u_L \ge \frac{2}{\gamma - 1}(c_L + c_R) = 11.20758 (Toro 2009, Chapter 4).

Known algorithms

AlgorithmTimeSpacePropertiesCode
AUSM schemeO(m M K) worstO(m M) extraconservativedeterministicexplicitnot keeps moving contactkeeps stationary contact1 language
Berger-Colella adaptive mesh refinementΘ(W) worstΘ(M) extraadaptiveconservativedeterministicexplicitsubcycling1 language
ENO schemesO(r^3 m M K) worstO(m M) extraconservativedeterministicexplicit1 language
Flux vector splittingO(m M K) worstO(m M) extraconservativedeterministicexplicitnot keeps stationary contact1 language
Ghost fluid methodΘ(N M) worstΘ(M) extranot conservativedeterministicexplicitsharp interface1 language
HLL Riemann solverO(m M K) worstO(m M) extraconservativedeterministicexplicitnot keeps stationary contact1 language
HLLC Riemann solverO(m M K) worstO(m M) extraconservativedeterministicexact isolated contactexplicitkeeps stationary contact1 language
Kurganov-Tadmor schemeO(s m M K) worstO(s m M) extraconservativedeterministicexplicitriemann-solver-free1 language
MacCormack methodO(K M) worstO(M) extraconservativedeterministicexplicitnot monotonenot tvd1 language
MUSCL schemeO(m M K) worstO(m M) extraconservativedeterministicexplicit1 language
Nessyahu-Tadmor central schemeO(m M K) worstO(m M) extraconservativedeterministicexplicitriemann-solver-free1 language
Piecewise parabolic methodO(m M K) worstO(m M) extraconservativedeterministicexplicit1 language
Roe solverO(m^2 M K) worstO(m M) extraconservativedeterministicnot entropy satisfyingexact single discontinuityexplicitkeeps stationary contactnot positive1 language
Runge-Kutta discontinuous Galerkin methodΘ(N M (k+1)^2) worstΘ(M (k+1)) extraconservativedeterministicexplicit1 language
Rusanov fluxO(m M K) worstO(m M) extraconservativedeterministicexplicitnot keeps stationary contact1 language

Bounds

  • Cost of an explicit scheme. On a grid of MM cells, one step of a Godunov type scheme costs O(M)O(M) operations, with a constant set by the Riemann solver. The time step is bounded by the CFL condition Δt≤νΔx/max⁡j(∣uj∣+cj)\Delta t \le \nu\Delta x/\max_j(|u_j| + c_j) with ν≤1\nu \le 1, so reaching time TT takes O(Tmax⁡(∣u∣+c)/Δx)O(T\max(|u| + c)/\Delta x) steps. In one dimension the total is O(M2)O(M^2) for a fixed TT; in dd dimensions with MM cells it is O(M1+1/d)O(M^{1 + 1/d}).
  • Accuracy at shocks. For a solution with shocks, the L1L^1 error of a scheme of any formal order is at best O(Δx)O(\Delta x), and at contacts first order schemes give O(Δx1/2)O(\Delta x^{1/2}) errors because the smearing spreads over O(tΔx)O(\sqrt{t\Delta x}). This is the rule of thumb in the literature and is what measurements show; the rates for systems are not proved in general.
  • Well posedness (theorem). In one dimension, for data with small total variation near a state with ρ,p>0\rho, p > 0, an admissible weak solution exists for all time (Glimm 1965). In two dimensions, Chiodaroli, De Lellis and Kreml (2015) proved that the isentropic system has Lipschitz initial data with infinitely many admissible weak solutions. So the entropy condition alone does not give uniqueness in several dimensions.
  • Riemann problem (theorem). For an ideal gas, the one dimensional Riemann problem has a unique solution of the shock, rarefaction and contact type for every pair of states, and it contains a vacuum exactly when uR−uL≥2γ−1(cL+cR)u_R - u_L \ge \frac{2}{\gamma - 1}(c_L + c_R) (Toro 2009, Chapter 4).
  • Positivity. A scheme can produce ρ<0\rho < 0 or p<0p < 0 even from positive data. Measurement: the MacCormack method without added viscosity on the Sod problem with Δt/Δx=0.2\Delta t/\Delta x = 0.2 gives negative pressure within ten steps, see the MacCormack method.

Reductions

  • To Riemann problems. A Godunov type scheme reduces each step to one Riemann problem per cell face. The exact solver reduces each Riemann problem to one scalar equation for p∗p_*.
  • To linear acoustics. Linearization about a constant state (ρ0,u0,p0)(\rho_0, u_0, p_0) gives the acoustics system with speeds u0±c0u_0 \pm c_0 and u0u_0, which is the wave equation for small pressure perturbations.
  • From Navier-Stokes. The compressible Navier-Stokes equations reduce to the Euler equations when viscosity and heat conduction are dropped. The vanishing viscosity limit is how the entropy condition is justified.
  • To shallow water. The isentropic system with γ=2\gamma = 2 has the same mathematical form as the shallow water equations, with ρ\rho in the place of hh.

Applications

  • Aerodynamics of transonic and supersonic flight: wings, inlets, nozzles, where the boundary layer is thin and the shocks are the main feature.
  • Astrophysics: supernova blast waves, accretion flows, jets and the gas in galaxy simulations.
  • Detonations and explosions, with reactive source terms.
  • Inertial confinement fusion and high speed impact.
  • A standard test bed for numerical methods for hyperbolic systems: the Sod, Lax, Shu-Osher and Woodward-Colella blast wave problems.

References

  1. Randall J. LeVeque, Finite Volume Methods for Hyperbolic Problems, Cambridge University Press, 2002, Section 14.3 (the Euler equations), Section 14.4 (polytropic ideal gas), Section 14.5 (entropy), Sections 14.8 to 14.13 (the Riemann problem for the Euler equations), Section 15.1 (Godunov's method), Section 15.3 (approximate Riemann solvers)
  2. Eleuterio F. Toro, Riemann Solvers and Numerical Methods for Fluid Dynamics, third edition, Springer, 2009, Section 1.1 (the Euler equations), Section 3.1 (the one dimensional Euler equations; 3.1.3 elementary waves), Section 3.3 (conservative and non-conservative formulations), Chapter 4 (the exact Riemann solver)
  3. G. A. Sod, A survey of several finite difference methods for systems of nonlinear hyperbolic conservation laws, Journal of Computational Physics 27 (1978) 1-31, the shock tube test problem
  4. E. Chiodaroli, C. De Lellis and O. Kreml, Global ill-posedness of the isentropic system of gas dynamics, Communications on Pure and Applied Mathematics 68 (2015) 1157-1190, infinitely many admissible weak solutions in two space dimensions

Where this leads

About this page

The build computes these levels from the evidence in the repository. Each row says what the next level needs. Read what the levels mean.

LadderLevelWhat the next level needs
Human proofH0 no proof
  • add a proof in proofs/ (06.5)
LeanL0 no Lean part
  • name a Lean module in the lean field (07)
VisualV0 none
  • add viz/scene.ts or a figure (10)
WritingW2 basic
  • a contract.yaml