Solution (source code)

= Solution

Let $e=c_vT$ be the <specific internal energy> of a calorically <perfect gas> and define its <specific gas constant> $\mathcal R=R^*/\mu$, so $p=\mathcal R\rho T$. A reversible adiabatic change has no heat input and obeys
$$
de+p\,d(1/\rho)=0\quad\Longrightarrow\quad c_v\,dT-\frac{\mathcal RT}{\rho}\,d\rho=0.
$$
Using $c_p-c_v=\mathcal R$ and $\gamma=c_p/c_v$ gives
$$
\frac{dT}{T}=(\gamma-1)\frac{d\rho}{\rho},\qquad d\ln p=d\ln\rho+d\ln T=\gamma\,d\ln\rho.
$$
Integration yields \b[$p/\rho^\gamma=K$, or $\boxed{p=K\rho^\gamma}$], with $K$ fixed on that isentrope. Equivalently $s-s_{\rm ref}=c_v\ln[(p/\rho^\gamma)/K_{\rm ref}]$, so $K$ specifies <entropy> as well as composition. In a smooth nondissipative flow this means $D(p\rho^{-\gamma})/Dt=0$ along each parcel. A single common $K$ throughout the fluid additionally requires a <homentropic flow>. No heat transfer alone does not forbid <entropy> production: different sides of an adiabatic shock generally have different $K$ values. Constant composition and heat capacities are needed for the fixed exponent used here.