Solution (source code)

= Solution

The second law requires the <specific entropy> to increase along the fluid's passage through a nontrivial physical <shock>: $s_1>s_0$. For a <perfect gas> this selects a compressive <shock>, whose upstream <shock>-frame <Mach number> is greater than one and whose downstream <shock>-frame flow is subsonic.

Here the upstream <Mach number> is $M_0=V/c_0$. The quadratic gives $V^2-c_0^2=(\gamma+1)UV/2>0$, so $\boxed{M_0>1}$. <Density> and <pressure> both rise. With $c_1^2=\gamma p_1/\rho_1$, one also has $V-U<c_1$. For example, put $M=V/c_0$ and use the normal-<shock> identity
$$
\frac{(V-U)^2}{c_1^2}=\frac{(\gamma-1)M^2+2}{2\gamma M^2-(\gamma-1)}<1\quad(M>1).
$$
The characteristic geometry is therefore $c_0<V<U+c_1$. The plus-family characteristics from the gas ahead are overtaken by the <shock>, while those behind catch up with it; they converge into the discontinuity. The minus-family speeds are $-c_0$ ahead and $U-c_1$ behind. The piston is the line $x=Ut$ and the <shock> is the steeper-in-$x/t$ line $x=Vt$.

\Image[/past-exam-of-the-theoretical-mechanics-course-of-the-university-of-oxford/2009-piston-characteristics.png]
{title=Compressive shock for an advancing piston and expansion fan for a receding piston}