TwoDTurb Module
Basic Equations
This module solves two-dimensional incompressible turbulence. The flow is given through a streamfunction $\psi$ as $(u,\upsilon) = (-\partial_y\psi, \partial_x\psi)$. The dynamical variable used here is the component of the vorticity of the flow normal to the plane of motion, $q=\partial_x \upsilon- \partial_y u = \nabla^2\psi$. The equation solved by the module is:
where $\J(a, b) = (\partial_x a)(\partial_y b)-(\partial_y a)(\partial_x b)$. On the right hand side, $f(x,y,t)$ is forcing, $\mu$ is hypoviscosity, and $\nu$ is hyperviscosity. Plain old linear drag corresponds to $n_{\mu}=0$, while normal viscosity corresponds to $n_{\nu}=1$.
Implementation
The equation is time-stepped forward in Fourier space:
In doing so the Jacobian is computed in the conservative form: $\J(f,g) = \partial_y [ (\partial_x f) g] -\partial_x[ (\partial_y f) g]$.
Thus: