Thetis Examples

July 16, 2026 · View on GitHub

This directory contains self-contained example simulations showcasing different Thetis capabilities—from 2D shallow-water flows to 3D baroclinic dynamics, sediment transport, tracer cases, and inverse modeling.

Each subfolder includes a Python script (e.g. channel2d.py), which you can run directly or in parallel.


📚 Overview of Examples

FolderShort Description
balzanoClassic wetting–drying test case with sloping bathymetry and periodic free surface.
baroclinic_channel3D baroclinic channel flow with stratification.
baroclinic_eddiesSimulation of baroclinic eddies in a channel.
bottomFrictionTests bottom friction formulations in shallow-water flow.
channel2d2D channel flow; useful for basic shallow-water tests.
channel3d3D version of channel flow with vertical structure.
channel_inversionCalibration of bathymetry/Manning coefficient/forcings using channel observations.
columbia_plumeOregon coastal plume with realistic river discharge.
cylinder_eddiesFlow around a cylinder, illustrating eddy shedding.
discrete_turbinesSimulating flow interaction with tidal turbines.
domeIdealized dome-shaped bathymetry to test internal waves.
freshwaterCylinderFreshwater release into denser ambient fluid around cylinder.
geostrophicGyreSteady geostrophic circulation in a closed basin.
headland_inversionCalibration of bottom friction around a headland using velocity observations.
idealizedEstuaryIdealized estuarine flow with salt intrusion.
katophillipsShows implementation of Kato-Phillips internal wave closure.
lockExchangeClassic lock-exchange buoyant flow test.
nonhydrostatic_casesNon-hydrostatic shallow-water wave examples.
north_seaSimplified North Sea tidal model.
overflowDense overflow flow (e.g., sinking plume).
reactionAdvection-reaction example case.
rhineROFIRhône River Estuary example (ROFI).
sediment_meander_2dSediment transport in a 2D meandering channel.
sediment_trench_2dSediment resuspension over a trench.
stommel2dClassic 2D Stommel gyre model.
stommel3d3D extension of the Stommel gyre.
tidal_barrageTidal barrage with flow-through structure.
tidalfarmOptimisation of an array of turbines in tidal flow.
tohoku_inversionCalibration (inversion) of model for Tōhoku tsunami event.
tracerBoxPassive tracer in a box flow test.
waveEq2d2D linear wave equation solver.
waveEq3d3D extension of the wave equation solver.

🚀 Running an Example

  cd channel2d
  python channel2d.py
  # or for parallel MPI runs:
  mpiexec -n 4 python channel2d.py