# Eulerian mass conservation on a stream line to Lagrangian mass conservation

if the density of a fluid particle is conserved on a streamline, $$\frac{d\rho}{dt}=0.$$ Why does this mean $$\frac{\partial \rho}{\partial t}+(\mathbf{v}\cdot\nabla)\rho=0$$ is true everywhere? Why is this true from a mathematical and physical perspective?

Edit: $\rho$, is the density. $\mathbf{v}$, is the velocity vector of the fluid.

From the chain rule we have,

$\frac{d \rho}{dt} = \frac{\partial \rho}{\partial t} + \frac{\partial \rho}{\partial x}\frac{dx}{dt} + \frac{\partial \rho}{\partial y}\frac{dy}{dt} + \frac{\partial \rho}{\partial z}\frac{dz}{dt}$

$\therefore \frac{d \rho}{dt} = \frac{\partial \rho}{\partial t} + \frac{\partial \rho}{\partial x} v_x + \frac{\partial \rho}{\partial y} v_y + \frac{\partial \rho}{\partial z} v_z$

$\therefore \frac{d \rho}{dt} = \frac{\partial \rho}{\partial t} + (v\cdot\nabla) \rho$

Actually here $\rho$ and ${\bf v}$ are function of $(t,\vec{x}) \in \mathbb R \times \mathbb R^3$, as it is usual in the so-called Eulerian description of a continuous body. There is no reference to the curves describing the evolutions of the particles of the fluid $\vec{x}_{\vec{x_0}}= \vec{x}_{\vec{x_0}}(t)$ as instead, it is the standard in the so-called Lagrangian description. Here $\vec{x}_0$ is the initial ($t=0$) position of a particle and so $\vec{x}_0$ completely determines the considered particle. By definition, at time $t$, the Eulerian field of velocity ${\bf v}(t, \cdot)$ is: $${\bf v}(t,\vec{x}) = \frac{d}{dt}\vec{x}_{\vec{x_0}}(t)$$
where $\vec{x}_{\vec{x_0}}$ is the trajectory of the unique particle $\vec{x_0}$ which passes through $\vec{x}$ at time $t$, so the definition is well-posed.

Identities as the one introduced by the OP, relating Eulerian and Lagrangian pictures, have to be interpreted.

If you compose $\rho$ with $\vec{x}_{\vec{x_0}}$ you obtain the time evolution of the density function along the trajectory of a particle of fluid: $$\rho_{\vec x_0}(t) := \rho(t,\vec{x}_{\vec{x_0}}(t))$$ Taking the derivative you have $$\frac{d}{dt}\rho_{\vec x_0}(t) = \left.\left[\frac{\partial}{\partial t} \rho(t, \vec{x}) + {\bf v}(t,\vec{x})\cdot \nabla_{\vec{x}} \rho(t, \vec{x})\right]\right|_{(t, \vec{x}_{\vec{x_0}}(t))} \tag{1}$$ We are in a position to introduce the so-called Substantial (or Material) derivative, $$\frac{D}{Dt} \rho(t,\vec{x}) := \frac{\partial}{\partial t} \rho(t, \vec{x}) + {\bf v}(t,\vec{x})\cdot \nabla_{\vec{x}} \rho(t, \vec{x})$$

I stress that it does not explicitly refer to any trajectory of the particle of the fluid and therefore it is a proper tool of the Eulerian description.

However it embodies the same information as the Lagrangian derivative $\frac{d}{dt}\rho_{\vec x_0}(t)$, since there is only one particle that at time $t$ passes through $\vec{x}$ and this fact permits one to compute $\frac{d}{dt}\rho_{\vec x_0}(t)$ exploiting (1): $$\frac{d}{dt}\rho_{\vec x_0}(t) = \left.\frac{D}{Dt} \rho(t,\vec{x})\right|_{(t, \vec{x}_{\vec{x_0}}(t))}$$