The entropy equation
\section{The Entropy Equation}
\noindent From the second law of thermodynamics\\
\begin{equation} \frac{De}{Dt}=T\frac{Ds}{Dt}-p\frac{D}{Dt}\left(\frac{1}{\rho}\right) \label{eq:second:law} \end{equation}\\
\noindent From the energy equation on differential non-conservation form internal energy formulation\\
\[\frac{De}{Dt} = \dot{q} - \frac{p}{\rho}(\nabla\cdot\mathbf{v})\]\\
\noindent The continuity equation on differential non-conservation form
\[\frac{D\rho}{Dt}+\rho(\nabla\cdot\mathbf{v})=0 \Rightarrow \nabla\cdot\mathbf{v}=-\frac{1}{\rho}\frac{D\rho}{Dt}\]
\noindent and thus\\
\[\frac{De}{Dt} = \dot{q} +\frac{p}{\rho^2}\frac{D\rho}{Dt}\]\\
\[\frac{D\rho}{Dt}=-\frac{1}{\nu^2}\frac{D\nu}{Dt}\]\\
\[\rho\frac{De}{Dt} = \rho\dot{q} -\frac{p}{\rho\nu^2}\frac{D\nu}{Dt} = \rho\dot{q} -\rho p\frac{D\nu}{Dt} \]\\
\[\rho\left[\frac{De}{Dt}+p\frac{D\nu}{Dt}-\dot{q}\right]=0\Rightarrow\frac{De}{Dt}=\dot{q}-p\frac{D\nu}{Dt}\]\\
\noindent Insert $De/Dt$ in Eqn. \ref{eq:second:law} \\
\[\dot{q}-p\frac{D}{Dt}\left(\frac{1}{\rho}\right)=T\frac{Ds}{Dt}-p\frac{D}{Dt}\left(\frac{1}{\rho}\right)\Rightarrow\]\\
\begin{equation} T\frac{Ds}{Dt}=-\dot{q} \label{eq:second:law:b} \end{equation}\\
\noindent Adiabatic flow:\\
\begin{equation} T\frac{Ds}{Dt}=0 \label{eq:second:law:b} \end{equation}\\
\noindent In an adiabatic, steady-state, inviscid flow, entropy is constant along a streamline.