# Can we simulate compressible flows by simple direct explicit calculation, without solving systems of linear equations (such as Poisson eq)?

Is this is plausible at all? It seems the most obvious/naive approach, so there's probably good reasons why it's not used - what are they?

Viscosity is not important.

Starting with inviscid Navier Stokes:

$$\frac{\partial \mathbf u}{\partial t} + \mathbf u \cdot \nabla \mathbf u + \frac{1}{\rho} \nabla p = \mathbf f$$

Conserve mass by tracking density as a state variable. We advect it and update it with the divergence of the velocity:

$$\frac{\partial \rho}{\partial t} = - \mathbf u \cdot \nabla \rho - \rho ( \nabla \cdot \mathbf u )$$

Next, calculate pressure from density:

$$p = \frac{1}{\alpha} ( \frac{\rho}{\rho_0} - 1 )$$

Now, we have pressure $p$ and we can use its gradient to calculate the change in $\mathbf u$ from the first Navier Stokes equation (rearranged from above) $$\frac{\partial \mathbf u}{\partial t} = - \mathbf u \cdot \nabla \mathbf u - \frac{1}{\rho} \nabla p + \mathbf f$$

This idea is similar to simulating the Shallow Water equations, where the velocity divergence is used to update the height of the water. The height is like a 2d density (mass per area). The weight of the fluid causes pressure. Differences in pressure (gradient) cause accelerations in the velocity field.

However, I don't seem to get any eddies/vorticity from simulating the Shallow Water equations, so I wonder if there's some fundamental problem with this idea...

EDIT The non creation of vorticity is revealed by the evolution equation of vorticity for an inviscid compressible gas in two dimensions; $$\partial_t\omega+\mathbf{u}\cdot\nabla\omega+\omega\nabla\cdot\mathbf{u}+\frac{\nabla{p}\times\nabla{\rho}}{\rho^2}=0$$
• Right, shallow water is just isentropic gas dynamics with $\gamma=2$. Flows in which the pressure is a function only of the density (in SW pressure is proportional to the square of the height and density is proportional to the height) are called barotropic. Now consider a flow for which this is not true and a small spherical element. Because the pressure force on any part of the surface passes through the center of the sphere, so does the total pressure force, which is in the direction of the pressure gradient.The pressure force acts along a line parallel to the gradient and through the c.g. – Philip Roe May 9 '17 at 16:06