SPH 1D Sod Shock Tube
What you are seeing: a one-dimensional smoothed-particle hydrodynamics (SPH) simulation of the Sod shock tube. The membrane at separates a high-pressure left state (, , ) from a low-pressure right state (, , ). At the membrane is removed.
The exact Riemann solution has three waves: a left-moving rarefaction fan (where the gas accelerates and rarefies), a contact discontinuity in the middle (where density jumps but pressure and velocity are smooth), and a right-moving shock (where density, pressure, and velocity all jump). The SPH method represents the fluid as 360 Lagrangian particles smoothed by a cubic-spline kernel; the artificial viscosity is what allows it to capture the shock.
speed2
fieldrho
WHAT TO TRY
- Let the membrane burst and watch the three waves separate: a rarefaction fan runs left into the high-pressure gas, a contact discontinuity drifts right, and a shock runs furthest right. The density, velocity and pressure panels show all three.
- Read the conserved quantities: the SPH particles carry mass exactly and the total energy drifts by only a percent, the honest accuracy check for the scheme on this classic Riemann test.
- Switch the coloured field: the same particles re-coloured by density, velocity or pressure reveal which wave each feature belongs to, the contact shows in density but not pressure.