# navier_stokes_2d_exact

navier_stokes_2d_exact, a MATLAB code which evaluates exact solutions to the incompressible time-dependent Navier-Stokes equations (NSE) over an arbitrary domain in 2D.

• cavity: steady, polynomial in space, zero velocity boundary conditions on sides and bottoms, variable velocity on "top". This is NOT the standard "driven cavity" example;
• exppoly: time dependent, exponential growth in time, zero velocity boundary conditions on unit square;
• exptrig: time dependent, trigonometric in space, exponential growth in time, zero velocity boundary conditions on unit square; at t=1, this flow forms a spiral. At later times, the exponential growth seems to make the solution physically absurd and computationally intractable.
• GMS: time dependent, vortices do not decay to zero;
• Lukas: steady, zero pressure;
• Poiseuille: steady, zero vertical velocity, zero source term;
• Spiral: time dependent, zero velocity on the unit square;
• Taylor: time dependent, zero source term, solution decays exponentially.
• Vortex: steady, same velocity pattern as Taylor.

### Licensing:

The computer code and data files made available on this web page are distributed under the MIT license

### Languages:

navier_stokes_2d_exact is available in a C version and a C++ version and a FORTRAN90 version and a MATLAB version and an Octave version and a Python version.

### Related Data and Programs:

navier_stokes_3d_exact, a MATLAB code which evaluates exact solutions to the incompressible time-dependent Navier-Stokes equations over an arbitrary domain in 3D.

navier_stokes_mesh2d, MATLAB data files which define meshes for several 2D test problems involving the Navier Stokes equations for fluid flow, provided by Leo Rebholz.

spiral_data, a MATLAB code which computes a velocity vector field that satisfies the continuity equation, writing the data to a file that can be plotted by gnuplot.

stokes_2d_exact, a MATLAB code which evaluates exact solutions to the incompressible steady Stokes equations over the unit square in 2D.

### Reference:

1. Jean-Luc Guermand, Peter Minev, Jie Shen,
An overview of projection methods for incompressible flows,
Computer methods in applied mechanics and engineering,
Volume 105, pages 6011-6045, 2006.
2. Xiaoli Li, Jie Shen,
Error analysis of the SAC-MAC scheme for the Navier-Stokes equations,
arXiv:1909.05131v1 [math.NA] 8 Sep 2019
3. Maxim Olshanskii, Leo Rebholz,
Application of barycenter refined meshes in linear elasticity and incompressible fluid dynamics,
ETNA: Electronic Transactions in Numerical Analysis,
Volume 38, pages 258-274, 2011.
4. Tien-Mo Shih, C H Tan, B C Hwang,
Effects of grid staggering on numerical schemes,
International Journal for Numerical Methods of Fluids,
Volume 9, Number 2, pages 193-212, February 1989.
5. 38, pages 258-274, 2011.
6. Geoffrey Taylor,
On the decay of vortices in a viscous fluid,
Philosophical Magazine,
Volume 46, 1923, pages 671-674.
7. Geoffrey Taylor, Albert Green,
Mechanism for the production of small eddies from large ones,
Proceedings of the Royal Society of London,
Series A, Volume 158, 1937, pages 499-521.

### Source Code:

Last revised on 27 August 2020.