Grid
A Grid is a WAVI.jl object that stores information relating to the numerical grid. The key parameters, which are passed via keyword arguments in the OutputParams constructor, are as follows:
nx: number of x grid pointsny: number of y grid pointsnσ: number of levels in the verticaldx: grid spacing in xdy: grid spacing in yx0: grid origin x co-ordinatey0: grid origin y co-ordinateh_mask: Array of sizenxxnythat defines domain points: ones in theh_maskindicate loations within ice domain, while zeros in theh_maskindicate locations outside of the ice domain. Defaults totrues(nx,ny), corresponding to every grid point being in the ice domain.u_iszero: Array of sizenxxnythat defines locations of zero velocity in the x-direction: ones in theu_iszerocorrespond to points where the velocity in the x-direction is forced to be zero, while zeros in theu_iszeroarray corresponds to points where the velocity is free. Defaults tofalses(nx,ny), corresponding to no restrictions on u velocity anywhere.u_iszerocan also be specified by an array with entries from "North", "South", "East", and "West", which set the corresponding edges of the domain to have zero velocity boundary conditions there.v_iszero: As inu_iszerofor the velocity in the y-direction.σ: Dimensionless locations of sigma (vertical) levels. Values must be increasing between 0 and 1.quadrature_weights: weights associated with sigma (vertical) levels used in quadrature scheme to determine depth averaged quantities (e.g. viscosity).
WAVI.jl has several grids, on which different quantities are defined (see numerical grid). A Grid object contains explicit definitions of these grids; for example, the x-coordinates of the "h grid" are stored in grid.xxh (where grid is the name of the Grid instance).
WAVI.Grid — MethodGrid(;
nx = 80,
ny = 10,
dx = 8000.0,
dy = 8000.0,
nσ = 4,
x0 = 0.0,
y0 = -40000.0,
h_mask = nothing,
h_isfixed = nothing,
u_iszero = nothing,
v_iszero = nothing,
basin_ID = nothing,
u_isfixed = nothing,
v_isfixed = nothing)Construct a WAVI.jl grid.
Keyword arguments
nx: number of x grid pointsny: number of y grid pointsdx: grid spacing in xdy: grid spacing in ynσ: number of levels in the verticalx0: grid origin x co-ordinatey0: grid origin y co-ordinateh_mask: Mask defining domain points within grid- `h_isfixed': Mask defining locations of fixed thickness within grid
u_iszero: Locations of zero u velocity pointsv_iszero: Locations of zero v velocity pointsu_isfixed: Locations of fixed u velocity pointsv_isfixed: Locations of fixed v velocity pointsquadrature_weights: weights associated with sigma levels used in quadrature schemebasin_ID: grid of basin IDs