Derivation of Kelvin's circulation theorem In the derivation of Kelvin's circulation theorem, I take the material derivative of circulation, or
\begin{align}
\dfrac{D\Gamma}{Dt} = \dfrac{D}{Dt}\oint_C \vec{u} \cdot d\vec{\ell}.
\end{align}
Moving the material derivative inside the integral gives
\begin{align}
\dfrac{D\Gamma}{Dt} = \oint_C \dfrac{D\vec{u}}{Dt} \cdot d\vec{\ell} + \oint_C \vec{u} \cdot \dfrac{D(d\vec{\ell})}{Dt}.
\end{align}
Given that $d\vec{\ell} = ds \hspace{1mm} \vec{t}$, the second integral of the equation above becomes
\begin{align}
\oint_C \vec{u} \cdot d\vec{u}.
\end{align}
How does one arrive at this equation? My attempt would be to use the chain rule so that
\begin{align}
\dfrac{D(ds \vec{t})}{Dt} = ds\dfrac{D\vec{t}}{Dt} + \vec{t}\dfrac{D(ds)}{Dt}.
\end{align}
From here, I expand each material derivative as
\begin{align}
\dfrac{D\vec{t}}{Dt} = \dfrac{\partial \vec{t}}{\partial t} + u_t\dfrac{\partial \vec{t}}{\partial s}+ u_n\dfrac{\partial \vec{t}}{\partial n}\\
\dfrac{D(ds)}{Dt} = \dfrac{\partial ds}{\partial t} + u_t\dfrac{\partial ds}{\partial s}+ u_n\dfrac{\partial ds}{\partial n}.
\end{align}
I am unsure how these two relations will simplify so that I get $$\dfrac{D(d\vec{\ell})}{Dt} = d\vec{u}.$$
 A: $\vec{l}$ is regarded as a position vector from an arbitrary origin to the contour.  So, following a material particle along the contour, $\frac{D\vec{l}}{Dt}=\vec{u}$.  The vector $d\vec{l}$ represents a differential position vector along the contour, and is given by $\vec{l}(s+ds)-\vec{l} (s)$.  So the material derivative of $d\vec{l}$ is equal to $\vec{u}(s+ds)-\vec{u}(s)=d\vec{u}$.
A: Let's continue from here:
Moving the material derivative inside the integral gives
\begin{align}
\dfrac{D\Gamma}{Dt} = \oint_C \dfrac{D\vec{u}}{Dt} \cdot d\vec{\ell} + \oint_C \vec{u} \cdot \dfrac{D(d\vec{\ell})}{Dt}.
\end{align}
Now, note that $d\vec{l}$ is a material line element. We might call it $\vec{s}$ and its evolution is given as: 
\begin{align}
\dfrac{D\vec{s}}{Dt} = (\vec{s}\cdot\nabla) \vec{u}
\end{align}
So, 
\begin{align}
 \oint_C \vec{u} \cdot \dfrac{D(d\vec{\ell})}{Dt} =  \oint_C \vec{u} \cdot(d \vec{s}\cdot \nabla) \vec{u} =  \oint_C  d\vec{s}\cdot \nabla(\frac{1}{2} u^{2}) = 0
\end{align}
Since $d\vec{s}$ and $\nabla(\frac{1}{2} u^{2})$ are everywhere orthogonal along the path. This is much better to see in indicial notation as $ \nabla_{\alpha}(u_{\beta}u_{\beta}) = 2u_{\beta}\nabla_{\alpha}u_{\beta}$.
So, that means everything depends on the first integral only, hence
\begin{align}
\dfrac{D\Gamma}{Dt} = \oint_C \dfrac{D\vec{u}}{Dt} \cdot d\vec{\ell} 
\end{align}
The change of the circulation is thus determined by the line integral of the acceleration and if the acceleration is derivable from a potential, we find that C remains constant; the circulation is materially conserved for frictionless, barotropic flow in case of no rotation (Kelvin’s theorem).
\begin{align}
\dfrac{D\Gamma}{Dt} = \oint_C \dfrac{D\vec{u}}{Dt} \cdot d\vec{\ell} = \oint_C -\nabla(\frac{p}{\rho} + \phi) \cdot d\vec{l}  
\end{align}
From Stokes theorem you have,
\begin{align}
\oint_C -\nabla(\frac{p}{\rho} + \phi) \cdot d\vec{l} = - \int_A \nabla \times \nabla(\frac{p}{\rho} + \phi) \cdot d\vec{A} =0
\end{align}
Since for barotropic fluid, isobars and isopycnals are parallel and therefore act at the center of mass of the water particles, creating no torque (vorticity) exactly as gravity, taken to be the corsevative field $\phi$. Therefore, 
$\dfrac{D\Gamma}{Dt} = 0$
Source: Ocean Dynamics. Olbers, Willebrand and Eden. Springer Verlag.
