Compressible flow

The jump does not ask what made it

Seven different dissipation mechanisms are made to smear the same shock. Their interiors are a factor of two and a third apart in thickness, their entropies overshoot the final value by between a quarter and a doubling, and the state they all arrive at agrees to seven parts in ten billion — because the end states are conservation and the interior is transport.

Worth reading first: The jump the equations allow · The discontinuity that has a thickness.

The Rankine–Hugoniot relations follow from three conservation statements across a discontinuity and from nothing else. No viscosity appears in them, no conductivity, no relaxation time, no model of any kind. This collection has an essay about the jump the equations allow and another about the thickness the discontinuity turns out to have.

This one is about the relation between them: the interior is a whole family and the endpoints are a point.

The Hugoniot and the Rayleigh line, whose crossing is the whole answer. The locus of states reachable from the upstream one by conservation of mass, momentum and energy, and the line the mass and momentum fluxes alone allow. They cross twice: once at the upstream state and once at the downstream one. Everything about the interior of the shock is a path between those two crossings, and none of it moves them.
Fig. 1 The Hugoniot and the Rayleigh line, whose crossing is the whole answer.

What is fixed before anything is modelled

Mass, momentum and energy across a steady one-dimensional discontinuity give three equations. Two of them — mass and momentum — say the state must lie on a straight line in the pressure–volume plane, the Rayleigh line, whose slope is minus the square of the mass flux. The third puts it on the Hugoniot, the locus of states reachable from the upstream one with the energy conserved.

Two curves cross twice: once at the upstream state, once at the downstream one. That second crossing is the whole of what a shock does, and it is determined before any statement about what the fluid is made of has been made.

The end state solved from the conservation equations here agrees with the textbook formulas to a part in a billion at Mach 1.5, 2, 3 and 6, which is the check that the three statements are being used and not the answer.

It is worth pausing on how little that requires. The three statements are that mass, momentum and energy fluxes are the same on both sides of whatever is in between. They do not require the thing in between to be thin, or smooth, or steady in any frame but this one, or describable by any equation. They require only that it not be creating or destroying the three quantities — which is what makes them apply to a shock, to a detonation, to a relaxation zone, and to a numerical scheme’s two or three smeared cells alike.

That generality has a price, and it is worth naming before the demonstration rather than after. The conservation statements are satisfied by two states on the Rayleigh line, and by themselves they do not say which one a flow reaches — the compression and the expansion are both solutions. Only the second law forbids one of them, and it does so by an argument about the interior rather than about the endpoints. So the interior is not irrelevant; it is irrelevant to which state a given branch reaches, having already selected the branch.

Seven mechanisms, one destination

The interior is a different matter, and it is where every transport property lives. The steady Navier–Stokes equations in one dimension, with the mass flux mm and the momentum and energy fluxes PP and EE fixed by the upstream state, reduce to

43μdudx=mu+mTuP,kdTdx=m(cpT+u22)(mu+mTuP)uE,\tfrac{4}{3}\mu\,\frac{du}{dx} = mu + \frac{mT}{u} - P, \qquad k\,\frac{dT}{dx} = m\left(c_pT + \tfrac{u^2}{2}\right) - \left(mu + \frac{mT}{u} - P\right)u - E,

a two-dimensional autonomous system whose fixed points are the two states above.

Seven shock structures, and the two states they all connect. The velocity through the shock for seven dissipation models — Prandtl numbers from a quarter to two, viscosities from constant to linear in temperature. Each curve is shifted so its midpoint sits at the origin. They start at the same speed, end at the same speed, and are nothing alike in between.
Fig. 2 Seven shock structures, and the two states they all connect.

Seven dissipation models are run through it: Prandtl numbers of 0.25, 0.72, 0.75, 1.5 and 2, and viscosities constant, as T0.75T^{0.75} and as TT. Those cover what a gas can plausibly have and rather more.

Where each of them ends. Every structure is integrated back from the Rankine-Hugoniot state and required to arrive at the upstream one. It does, to a part in a billion, for every dissipation model — which is the demonstration that the end states are decided by the conservation laws and by nothing in the mechanism that smears the jump.
Fig. 3 Where each of them ends.

Every one arrives at the Rankine–Hugoniot state to a part in a billion, and the seven arrivals agree with each other to seven parts in ten billion.

The thicknesses, which differ by a factor of two and a third. The velocity change divided by its steepest gradient, for each model. The Prandtl number and the viscosity law together move it by a factor of 2.3, so a measurement of a shock's thickness is a measurement of the gas's transport properties — while a measurement of the states on either side is not.
Fig. 4 The thicknesses, which differ by a factor of two and a third.

Their thicknesses do not agree at all: 2.32 for a Prandtl number of 2 and 5.38 for 0.25 with a temperature-dependent viscosity, a factor of 2.3 across the set. So a measurement of a shock’s thickness is a measurement of the gas’s transport properties, and a measurement of the states on either side is not.

The way that is checked deserves a word, because “they all arrive at the same place” could be an artefact of how the arrival is defined. It is not defined at all here: each structure is started at the downstream state and integrated backwards, and what is compared is where it lands upstream. So the downstream state is an input and the upstream one is the measurement, and the seven measurements agree with the analytic upstream state and with each other.

Reversing the roles makes the test sharper rather than weaker. There is one downstream state and seven paths leaving it, and if the conservation statement were doing less than it claims, the seven would arrive at seven slightly different upstream conditions — a spread that would grow with the strength of the dissipation. The spread is seven parts in ten billion and shows no dependence on the model at all.

The phase plane, and why the calculation runs backwards

There is a detail in how the structures are computed that is worth recording, because the obvious approach fails and fails informatively.

The phase plane the structure lives in. Velocity against temperature. The upstream state is an unstable node — both eigenvalues positive — and the downstream state is a saddle, so the structure is the one trajectory that lands on the saddle's stable manifold. Integrating forward from upstream cannot find it; integrating back from downstream cannot miss it.
Fig. 5 The phase plane the structure lives in.

Linearising at each end gives, at Mach 2 with a Prandtl number of three quarters, an upstream Jacobian with trace +2.73+2.73 and determinant +1.69+1.69 — an unstable node, both eigenvalues positive — and a downstream one with determinant 4.50-4.50, a saddle.

So the structure is the one trajectory out of the node’s two-parameter fan that lands on the saddle’s one-dimensional stable manifold. Starting at the upstream state along its slow eigenvector cannot find it: the fast direction grows faster, every rounding error feeds it, and the trajectory leaves. Which is exactly what happened — the integration ran sixty thousand steps past the shock and left the physical region through a negative temperature.

Backwards from the saddle there is no such problem. The stable manifold is unique, reversing time makes it attracting, and the upstream node is attracting in reverse. The trajectory is found rather than shot for, and the arrival at the upstream state is then the check rather than the construction.

There is a general lesson in that failure which is worth extracting from the gas dynamics. A heteroclinic orbit — a trajectory joining two fixed points — is generic in one direction and delicate in the other, and which direction is which is decided by the types of the two points rather than by anything physical. Integrating away from a node is easy and integrating towards a saddle is not, so the arithmetic wants to run from the node to the saddle in reverse time.

The consequence for anybody computing a structure of this kind is short: linearise at both ends before choosing a direction. The eigenvalues take a minute to compute and they say which way the calculation is stable. Choosing by physical intuition — start where the flow starts — got the direction wrong here, and the failure looked like a step-size problem for some time before it was recognised as a topological one.

Two things that fall out

The demonstration is the point, and two results emerged from it that are worth more than the demonstration.

The total enthalpy through the shock, at three Prandtl numbers. At a Prandtl number of exactly three quarters the conduction term is exactly what the viscous stress's work needs, and the total enthalpy is a constant of the motion — Becker's result, recovered here to fourteen figures. Above and below it the total enthalpy dips or bulges by up to eight per cent inside the shock and returns to the same value at the far side.
Fig. 6 The total enthalpy through the shock, at three Prandtl numbers.

The total enthalpy is exactly constant through a shock if and only if the Prandtl number is three quarters. At that value the conduction term is exactly what the viscous stress’s work needs, so cpT+u2/2c_pT + u^2/2 is a constant of the motion. Becker found it in 1922 and it comes back here to fourteen figures — and to fourteen figures at a temperature-dependent viscosity as well, which confirms that the condition is on the Prandtl number alone rather than on the viscosity law.

Away from three quarters the total enthalpy dips or bulges by up to eight per cent inside the shock and returns to exactly the same value at the far side. So the quantity everybody uses to characterise a compressible flow is not constant through the structure, and is constant across it.

The path in the pressure-volume plane, against the Rayleigh line. The Rayleigh line is the momentum equation without the viscous stress; the structure is the momentum equation with it. So the gap between them is a measurement of the stress rather than an approximation to anything, it reaches sixteen per cent of the downstream pressure in the middle, and it closes at both ends because the stress vanishes there.
Fig. 7 The path in the pressure–volume plane, against the Rayleigh line.

And the path’s departure from the Rayleigh line is the viscous stress. The Rayleigh line is the momentum equation without the stress; the structure is the momentum equation with it. So the gap between them is a measurement of the stress rather than an approximation to anything, it reaches sixteen per cent of the downstream pressure in the middle of the shock, and it closes at both ends because the stress vanishes there.

That last point is worth keeping, because it says what the Rayleigh line means physically. It is not an approximation to the path. It is the path the flow would follow if there were no viscosity, and the amount by which the real path bulges off it is exactly how much stress the flow is carrying at each point.

Becker’s condition also explains something about the models that would otherwise look arbitrary. Three quarters is close to the Prandtl number of most gases: 0.72 for air, 0.71 for nitrogen, 0.67 for helium, 0.75 for carbon dioxide. So real gases sit near the value at which the total enthalpy is exactly conserved through a shock, and the very small departures a real structure shows are a measure of how far the gas is from 3/4 rather than of anything else.

That is why the constant-total-enthalpy assumption is made so freely in this subject and so rarely justified. It is not an approximation that happens to be good; it is an identity that holds at one Prandtl number and nearly holds at the ones nature supplies. The figure above prices the approximation directly: 2.7 parts in a thousand for air’s 0.72, which is negligible, against 7.8 per cent at 0.25, which is not.

The entropy does something alarming

The entropy inside the shock, which overshoots and comes back. The entropy rises above its downstream value inside the structure — by sixty per cent at a Prandtl number of three quarters and by a hundred and fourteen at a quarter — and falls back to the Rankine-Hugoniot value. It looks like a violation and is not: a particle's entropy changes by its own production plus the divergence of the conduction flux, and the second term carries entropy forward into the cold gas ahead.
Fig. 8 The entropy inside the shock, which overshoots and comes back.

The entropy rises above its downstream value inside the structure — by sixty per cent at a Prandtl number of three quarters and by a hundred and fourteen at a quarter — and then falls back to the Rankine–Hugoniot value.

Read carelessly that is a violation of the second law: a fluid particle passing through the shock has its entropy rise and then fall. It is not one, and the reason is the same distinction that runs through this whole subject.

And the production, which never is negative. The local entropy production — the viscous term plus the conduction term, both quadratic — along the same structures. It is positive at every point of every model, which is the statement the second law actually makes. The entropy being non-monotone is a statement about transport rather than about production, and the check requires both.
Fig. 9 And the production, which never is negative.

A particle’s entropy changes by its own production plus the divergence of the conduction flux. The production is the viscous term plus the conduction term, both quadratic and both positive, and it is positive at every point of every structure computed here. The second term is a transport: it carries entropy out of the hot middle of the shock and into the cold gas ahead, which is why the entropy peaks inside and settles lower.

So the second law constrains the production and not the entropy of a particle, and a check that tested monotonicity would have failed on a correct calculation. Both halves are required here for exactly that reason: a production test alone would not have noticed that the entropy is non-monotone at all.

There is one more reading of the overshoot worth having, because it makes the number less alarming and more informative.

The entropy peak sits where the temperature gradient is steepest, which is where the conduction flux is largest and its divergence changes sign. Upstream of that point conduction is adding entropy to a particle by carrying heat into it from the hot side; downstream it is removing entropy by carrying heat out. Integrated across the whole structure the two cancel exactly — conduction moves entropy about and does not create it — and what is left is the production, which is the Rankine–Hugoniot rise.

So the overshoot is not a fluctuation or a numerical artefact and it is not small. It is the signature of a transport term doing what a transport term does, and it is largest at low Prandtl number because that is where conduction is strong relative to viscosity. At a Prandtl number of two it is a quarter; at a quarter it is a doubling.

Why this matters beyond shocks

What the dissipation decides, and what it does not. The thickness of the shock varies by a factor of 2.3 across the models and the state behind it does not vary at all — the seven arrivals agree to seven parts in ten billion. The first is a transport property of the gas; the second is a conservation law.
Fig. 10 What the dissipation decides, and what it does not.

The separation on this page is the reason a great deal of computational gas dynamics works.

A shock-capturing scheme does not resolve a shock. It smears it over two or three cells with an artificial dissipation that is nothing like a real gas’s viscosity — often deliberately so, chosen for stability rather than for physics. What justifies that is exactly the result above: the end states do not depend on the mechanism, so a scheme that conserves mass, momentum and energy discretely arrives at the right state behind the shock even though its interior is fictional.

The corollary is equally important and less often said. Anything that depends on the interior — the shock’s thickness, the peak temperature inside it, the rate at which a chemical reaction proceeds there, the entropy at a station within the structure — is not computed correctly by such a scheme and cannot be recovered by refining the grid, because the dissipation is the scheme’s rather than the gas’s.

This is the same statement about totals and interiors that appears throughout this collection, and it is unusually consequential here: the constraint is three conservation laws, the freedom is the entire transport model, and the answer people want is on the constrained side.

What a measurement of a shock can and cannot be

Putting the two halves together gives a short account of what is worth measuring about a shock, and of what a measurement of each thing tells.

The states on either side are the jump conditions and can be predicted exactly from the upstream Mach number and the ratio of specific heats. Measuring them tests the gas model — whether the specific heats are constant, whether the gas is in equilibrium, whether gamma is still a number — and tests nothing about transport.

The thickness is the reverse. It is a factor of 2.3 different across plausible transport models and identical across gas models with the same jump, so measuring it tests viscosity and conductivity at the temperatures inside the shock, which is where they are hardest to measure by any other means. That is why shock structure was used as a transport experiment for decades.

And a quantity taken at a station inside the structure — a temperature, a density, a species concentration — belongs to neither category cleanly, because it depends on both the transport model and where the station is measured from. Those are the measurements that need a stated model to be interpretable at all.

The same three-way split is worth applying to anything computed as well as to anything measured. A result that depends only on the end states is robust to almost every modelling choice; a result that depends on the interior is a result about the model; and a result that depends on both is a result whose error budget has to name which part came from where.

Where else a total is fixed and an interior is not

The separation on this page is the clearest instance in the collection of something that recurs, and it is worth putting three others beside it.

A hydraulic jump’s conjugate depths follow from momentum alone, with no model of the white water inside it — the same structure, in a liquid, with the Froude number in place of the Mach number.

A wake survey’s drag is the deficit integral and the wake’s shape is free, which is the same statement with a body in place of a discontinuity.

A shock’s thickness is the quantity on the other side of the divide here, and this collection computed it before asking what it was independent of.

And the entropy a shock produces sits exactly on the boundary: it is fixed by the end states, so it belongs with the conservation half, even though every account of why it is produced is an account of the interior.

The general question to ask of a computed or measured quantity is which side of the line it is on. Does it follow from the fluxes on either side, or does it require the path between them? The first kind is robust to almost every modelling choice and the second is a measurement of the model, and knowing which is which decides how much a result is worth.

What the calculation cost, and what that says

A short note on the arithmetic, because the effort involved is itself informative about the two halves.

The end states take three algebraic equations and are available in closed form. They were computed here twice — once from the standard formulas and once by solving the conservation statements numerically — and the two agree to a part in a billion at four Mach numbers. That is a few lines of code and a few milliseconds.

The interiors take a two-dimensional stiff ordinary differential equation, a linearisation at both ends to determine which direction is stable, a reverse integration with a small step, and a stopping criterion that does not walk off the fixed point. Getting that right took a rewrite, and the first version failed in a way that looked like a step-size problem and was a topological one.

The disproportion is the point. The quantity that everybody quotes is the cheap one, and it is cheap because it is a conservation statement. The quantity that requires the model is expensive, requires care, and is what the model is a model of.

That ratio recurs. Totals are algebra and interiors are differential equations, throughout this subject, and a result that comes out of algebra is worth trusting in proportion.

What is not claimed

A Mach 2 shock in air is not thin enough for Navier–Stokes to be trusted in its interior. The structure computed here is a few mean free paths across, which is exactly where a continuum description with linear transport laws stops being reliable — the density profile from a Boltzmann solution is measurably different, and the measured thicknesses of real shocks are wider than Navier–Stokes predicts. The end states are unaffected, which is the point.

The seven models are not seven gases. They are seven parameter choices in one constitutive form. A gas with rotational or vibrational relaxation has a structure of a different kind again — with a thin front and a long relaxation tail — and its end state is still the Rankine–Hugoniot one, provided the relaxation completes.

The entropy overshoot’s size depends on the model. Sixty per cent at a Prandtl number of three quarters is for a Mach 2 shock in a perfect gas with these transport laws, and it grows with the shock strength. What is general is its existence and the positivity of the production.

And the phase-plane structure is stated at one Mach number. The character of the two fixed points is the same for every supersonic upstream state in this system, but the eigenvalues, and therefore how badly a forward integration fails, are not.

What links here

Computed from the collection rather than written here: the essays that point at this one.

Shares its objects with

Essays naming at least two of the same things, that neither author linked.

Named objects

A dashed tag is an object no other essay names yet.

ConservationDiscontinuityDissipationEntropyIrreversibilityNavier–Stokes equationsNormal shockPrandtl numberRankine–Hugoniot conditionsThe second law of thermodynamicsShock structureViscosity