High-level, efficient ocean modeling at all scales with Oceananigans
We describe the user interface, governing equations, and numerical methods underpinning the ocean modeling software called "Oceananigans". Oceananigans development has been led by the Climate Modeling Alliance as part of a larger effort to build a trainable climate model with quantifiable uncertainty. Notably, Oceananigans is written in the Julia programming language, is optimized for GPUs, and can efficiently simulate all scales of ocean motion ranging from millimeter-scale turbulence in a small box to planetary-scale ocean circulation. We argue that this combination of capabilities is enabled by a design that combines a basic, easy-to-optimize, GPU-friendly structured finite volume algorithm exposed behind a high-level, programmable user interface. This design negotiates a dual mandate for highest-possible performance (to support state-of-the-art applications) and enhanced accessibility (to facilitate adoption and development). The dual mandate aims ultimately to accelerate the progress of Earth system science.