pistol’s documentation

Equations of motion

See this Equations of motions

Install

We recommend conda for dependencies, see README on pistol github repository

Tutorial

To do …

mpirun -n 4 python analytical.py -mf -ksp_view -ksp_monitor -ksp_converged_reason

Profiling:

mpirun -n 4 python -m cProfile -o output.prof uniform.py
snakeviz output.prof

API

Equations of motions

Continuous form

Boussinesq, adiabatic, hydrostatic and nonlinear shallow water equations for conservation of momentum:

\[\partial_t \mathbf{u}_n(x,y) + (\zeta_n + f) \mathbf{k}\times\mathbf{u}_n = -\nabla \Big \{ M_n + \frac{1}{2} |\mathbf{u}_n|^2 + g \Pi \Big \} + \mathbf{H}_n + \mathbf{V}_n\]

for \(n=0,\cdots N-1\) and where \(f\) is the Coriolis frequency and \(\zeta_n = \mathbf{k}\cdot (\nabla \times \mathbf{u}_n )\) is the relative vorticity, \(M_n\) is the perturbation Montgomery potential. The latter is given by:

\[ \begin{align}\begin{aligned}z_0 &= \eta\\z_n &= z_{n-1} - h_n, n > 0\end{aligned}\end{align} \]
\[ \begin{align}\begin{aligned}M_0 &= g \eta\\M_n &= M_{n-1} + g (\rho_{n}-\rho_{n-1}) z_n, n>0\end{aligned}\end{align} \]
\[p_n(x,y,z) = M_n(x,y) - g \rho_n z\]

Thickness tendency equations:

\[\partial_t h_n(x,y) + \nabla \cdot (\mathbf{u}_n h_n ) = 0.\]

References: …

Spectral discretization

Temporal discretization

AB or RK for now, time splitting latter

Hallberg09, Vitousek14

QG formulation

qgsolver package

Submodules

qgsolver.grid module

qgsolver.inout module

qgsolver.omegainv module

qgsolver.pvinv module

qgsolver.qg module

qgsolver.state module

qgsolver.timestepper module

qgsolver.utils module

qgsolver.window module

Module contents

Indices and tables