MOM_ALE module reference
This module contains the main regridding routines.
Regridding comprises two steps:
Interpolation and creation of a new grid based on target interface densities (or any other criterion).
Remapping of quantities between old grid and new grid.
Original module written by Laurent White, 2008.06.09
Data Types
ALE control structure |
Functions/Subroutines
This routine is typically called (from initialize_MOM in file MOM.F90) before the main time integration loop to initialize the regridding stuff. We read the MOM_input file to register the values of different regridding/remapping parameters. |
|
Sets the boundary extrapolation set for the remapping type. |
|
Sets the remapping algorithm to that of OM4 |
|
Initialize diagnostics for the ALE module. |
|
Crudely adjust (initial) grid for integrity. This routine is typically called (from initialize_MOM in file MOM.F90) before the main time integration loop to initialize the regridding stuff. We read the MOM_input file to register the values of different regridding/remapping parameters. |
|
End of regridding (memory deallocation). This routine is typically called (from MOM_end in file MOM.F90) after the main time integration loop to deallocate the regridding stuff. |
|
Save any diagnostics of the state before ALE remapping. These diagnostics are mostly used for debugging. |
|
Potentially do some preparatory work, such as convective adjustment, to clean up the model state before regridding. |
|
Takes care of building a new grid. The creation of the new grid can be based on z coordinates, target interface densities, sigma coordinates or any arbitrary coordinate system. |
|
Regrid/remap stored fields used for offline tracer integrations. These input fields are assumed to have the same layer thicknesses at the end of the last offline interval (which should be a Zstar grid). This routine builds a grid on the runtime specified vertical coordinate |
|
For a state-based coordinate, accelerate the process of regridding by repeatedly applying the grid calculation algorithm |
|
This routine takes care of remapping all tracer variables between the old and the new grids. This routine is called during initialization of the model at time=0, to remap initial conditions to the model grid. It is also called during a time step to update the state. |
|
This routine sets the thicknesses at velocity points used for vertical remapping. |
|
This routine sets the thicknesses at velocity points used for vertical remapping using a combination of the old grid and interface movements. |
|
Mask out the thicknesses at velocity points where they are below the minimum depth at adjacent tracer points |
|
This routine remaps velocity components between the old and the new grids, with thicknesses at velocity points taken to be arithmetic averages of tracer thicknesses. This routine may be called during initialization of the model at time=0, to remap initial conditions to the model grid. It is also called during a time step to update the state. |
|
Interpolate to find an updated array of values at interfaces after remapping. |
|
Interpolate to find an updated array of values at vertices of tracer cells after remapping. |
|
Mask out thicknesses to 0 when their running sum exceeds a specified value. |
|
Zero out velocities in a column in very thin layers near the seafloor |
|
Remaps a single scalar between grids described by thicknesses h_src and h_dst. h_dst must be dimensioned as a model array with GV%ke layers while h_src can have an arbitrary number of layers specified by nk_src. |
|
Calculate edge values (top and bottom of layer) for T and S consistent with a PLM reconstruction in the vertical direction. Boundary reconstructions are PCM unless bdry_extrap is true. |
|
Calculate edge values (top and bottom of layer) 3d scalar array. Boundary reconstructions are PCM unless bdry_extrap is true. |
|
Calculate edge values (top and bottom of layer) for T and S consistent with a PPM reconstruction in the vertical direction. Boundary reconstructions are PCM unless bdry_extrap is true. |
|
Calculate edge values (top and bottom of layer) for T and S consistent with a PLM reconstruction in the vertical direction that uses weighted least squares for the slope. |
|
Initializes regridding for the main ALE algorithm |
|
Query the target coordinate interfaces positions |
|
Query the target coordinate units |
|
Returns true if initial conditions should be regridded and remapped |
|
Updates the weights for time filtering the new grid generated in regridding |
|
Update the vertical grid type with ALE information. This subroutine sets information in the verticalGrid_type to be consistent with the use of ALE mode. |
|
Write the vertical coordinate information into a file. This subroutine writes out a file containing any available data related to the vertical grid used by the MOM ocean model when in ALE mode. |
|
Set h to coordinate values for fixed coordinate systems |
Type Documentation
- type, public :: ALE_CS
ALE control structure
- Parameters
remap_uv_using_old_alg
If true, uses the old "remapping via a delta z" method. If False, uses the new method that remaps between grids described by h.
partial_cell_vel_remap
If true, use partial cell thicknesses at velocity points that are masked out where they extend below the shallower of the neighboring bathymetry for remapping velocity.
regrid_time_scale
The time-scale used in blending between the current (old) grid and the target (new) grid [T ~> s]
regridCS
Regridding parameters and work arrays
remapCS
Remapping parameters and work arrays
vel_remapCS
Remapping parameters for velocities and work arrays
hybgen_unmixCS
Parameters for hybgen remapping
use_hybgen_unmix
If true, use the hybgen unmixing code before regridding
do_conv_adj
If true, do convective adjustment before regridding
nk
Used only for queries, not directly by this module
BBL_h_vel_mask
The thickness of a bottom boundary layer within which velocities in thin layers are zeroed out after remapping, following practice with Hybgen remapping, or a negative value to avoid such filtering altogether, in [H ~> m or kg m-2].
h_vel_mask
A thickness at velocity points below which near-bottom layers are zeroed out after remapping, following the practice with Hybgen remapping, or a negative value to avoid such filtering altogether, in [H ~> m or kg m-2].
remap_after_initialization
Indicates whether to regrid/remap after initializing the state.
answer_date
The vintage of the expressions and order of arithmetic to use for remapping. Values below 20190101 result in the use of older, less accurate expressions that were in use at the end of 2018. Higher values result in the use of more robust and accurate forms of mathematically equivalent expressions.
conserve_ke
Apply a correction to the baroclinic velocity after remapping to conserve KE.
debug
If true, write verbose checksums for debugging purposes.
show_call_tree
For debugging
diag
structure to regulate output
id_tracer_remap_tendency
diagnostic id
id_Htracer_remap_tendency
diagnostic id
id_Htracer_remap_tendency_2d
diagnostic id
do_tendency_diag
flag for doing diagnostics
id_dzRegrid
diagnostic id
id_u_preale
diagnostic id for zonal velocity before ALE.
id_v_preale
diagnostic id for meridional velocity before ALE.
id_h_preale
diagnostic id for layer thicknesses before ALE.
id_T_preale
diagnostic id for temperatures before ALE.
id_S_preale
diagnostic id for salinities before ALE.
id_e_preale
diagnostic id for interface heights before ALE.
id_vert_remap_h
diagnostic id for layer thicknesses used for remapping
id_vert_remap_h_tendency
diagnostic id for layer thickness tendency due to ALE
id_remap_delta_integ_u2
Change in depth-integrated rho0*u**2/2
id_remap_delta_integ_v2
Change in depth-integrated rho0*v**2/2
Functions/Subroutine Documentation
- subroutine ALE_init(param_file, G, GV, US, max_depth, CS)
This routine is typically called (from initialize_MOM in file MOM.F90) before the main time integration loop to initialize the regridding stuff. We read the MOM_input file to register the values of different regridding/remapping parameters.
- Parameters
param_file [in]
Parameter file
G [in]
Grid structure
GV [in]
Ocean vertical grid structure
US [in]
A dimensional unit scaling type
max_depth [in]
The maximum depth of the ocean [Z ~> m].
CS
Module control structure
Callers call graph
- subroutine ALE_set_extrap_boundaries(param_file, CS)
Sets the boundary extrapolation set for the remapping type.
- Parameters
param_file [in]
Parameter file
CS
Module control structure
Callees call graph
- subroutine ALE_set_OM4_remap_algorithm(CS, om4_remap_via_sub_cells)
Sets the remapping algorithm to that of OM4
The remapping aglorithm used in OM4 made poor assumptions about the reconstructions in the top/bottom layers, namely that they were always vanished and could be represented solely by their upper/lower edge value respectively. Passing .false. here uses the full reconstruction of those top and bottom layers and properly sample those layers.
- Parameters
CS
Module control structure
om4_remap_via_sub_cells [in]
If true, use OM4 remapping algorithm
Callees call graph
- subroutine ALE_register_diags(Time, G, GV, US, diag, CS)
Initialize diagnostics for the ALE module.
- Parameters
Time [in]
Time structure
G [in]
Grid structure
US [in]
A dimensional unit scaling type
GV [in]
Ocean vertical grid structure
diag [in]
Diagnostics control structure
CS
Module control structure
Callees call graph
- subroutine adjustGridForIntegrity(CS, G, GV, h)
Crudely adjust (initial) grid for integrity. This routine is typically called (from initialize_MOM in file MOM.F90) before the main time integration loop to initialize the regridding stuff. We read the MOM_input file to register the values of different regridding/remapping parameters.
- Parameters
CS [in]
Regridding parameters and options
G [in]
Ocean grid informations
GV [in]
Ocean vertical grid structure
h [inout]
Current 3D grid thickness that are to be adjusted [H ~> m or kg m-2]
Callees call graph
- subroutine ALE_end(CS)
End of regridding (memory deallocation). This routine is typically called (from MOM_end in file MOM.F90) after the main time integration loop to deallocate the regridding stuff.
- Parameters
CS
module control structure
Callees call graph
- subroutine pre_ALE_diagnostics(G, GV, US, h, u, v, tv, CS)
Save any diagnostics of the state before ALE remapping. These diagnostics are mostly used for debugging.
- Parameters
G [in]
Ocean grid informations
GV [in]
Ocean vertical grid structure
US [in]
A dimensional unit scaling type
h [inout]
Current 3D grid obtained after the last time step [H ~> m or kg m-2]
u [inout]
Zonal velocity field [L T-1 ~> m s-1]
v [inout]
Meridional velocity field [L T-1 ~> m s-1]
tv [inout]
Thermodynamic variable structure
CS
Regridding parameters and options
Callees call graph
- subroutine pre_ALE_adjustments(G, GV, US, h, tv, Reg, CS, u, v)
Potentially do some preparatory work, such as convective adjustment, to clean up the model state before regridding.
- Parameters
G [in]
Ocean grid informations
GV [in]
Ocean vertical grid structure
US [in]
A dimensional unit scaling type
h [inout]
Current 3D grid obtained after the last time step [H ~> m or kg m-2]
tv [inout]
Thermodynamic variable structure
Reg
Tracer registry structure
CS
Regridding parameters and options
u [inout]
Zonal velocity field [L T-1 ~> m s-1]
v [inout]
Meridional velocity field [L T-1 ~> m s-1]
Callees call graph
- subroutine ALE_regrid(G, GV, US, h, h_new, dzRegrid, tv, CS, frac_shelf_h, PCM_cell)
Takes care of building a new grid. The creation of the new grid can be based on z coordinates, target interface densities, sigma coordinates or any arbitrary coordinate system.
- Parameters
G [in]
Ocean grid informations
GV [in]
Ocean vertical grid structure
US [in]
A dimensional unit scaling type
h [in]
Layer thicknesses in 3D grid before regridding [H ~> m or kg m-2]
h_new [out]
Layer thicknesses in 3D grid after regridding [H ~> m or kg m-2]
dzRegrid [out]
The change in grid interface positions due to regridding, in the same units as thicknesses [H ~> m or kg m-2]
tv [inout]
Thermodynamic variable structure
CS
Regridding parameters and options
frac_shelf_h [in]
Fractional ice shelf coverage [nondim]
PCM_cell [out]
If true, use PCM remapping in a cell.
Callees call graph
- subroutine ALE_offline_inputs(CS, G, GV, US, h, tv, Reg, uhtr, vhtr, Kd, debug, OBC)
Regrid/remap stored fields used for offline tracer integrations. These input fields are assumed to have the same layer thicknesses at the end of the last offline interval (which should be a Zstar grid). This routine builds a grid on the runtime specified vertical coordinate
- Parameters
CS
Regridding parameters and options
G [in]
Ocean grid informations
GV [in]
Ocean vertical grid structure
US [in]
A dimensional unit scaling type
h [inout]
Layer thicknesses [H ~> m or kg m-2]
tv [inout]
Thermodynamic variable structure
Reg
Tracer registry structure
uhtr [inout]
Zonal mass fluxes [H L2 ~> m3 or kg]
vhtr [inout]
Meridional mass fluxes [H L2 ~> m3 or kg]
Kd [inout]
Input diffusivities [H Z T-1 ~> m2 s-1 or kg m-1 s-1]
debug [in]
If true, then turn checksums
OBC
Open boundary structure
Callees call graph
Text view
mom_ale::ale_offline_inputs → mom_debugging::check_column_integrals
mom_ale::ale_offline_inputs → mom_error_handler::calltree_leave
mom_ale::ale_offline_inputs → mom_error_handler::calltree_waypoint
mom_ale::ale_offline_inputs → mom_regridding::regridding_main
mom_ale::ale_offline_inputs → mom_remapping::interpolate_column
mom_ale::ale_offline_inputs → mom_remapping::reintegrate_column
mom_ale::ale_offline_inputs → mom_tracer_registry::interface::mom_tracer_chkinv
- subroutine ALE_regrid_accelerated(CS, G, GV, US, h, tv, n_itt, u, v, OBC, Reg, dt, dzRegrid, initial)
For a state-based coordinate, accelerate the process of regridding by repeatedly applying the grid calculation algorithm
- Parameters
CS
ALE control structure
G [inout]
Ocean grid
GV [in]
Vertical grid
US [in]
A dimensional unit scaling type
h [inout]
Original thicknesses [H ~> m or kg m-2]
tv [inout]
Thermo vars (T/S/EOS)
n_itt [in]
Number of times to regrid
u [inout]
Zonal velocity [L T-1 ~> m s-1]
v [inout]
Meridional velocity [L T-1 ~> m s-1]
OBC
Open boundary structure
Reg
Tracer registry to remap onto new grid
dt [in]
Model timestep to provide a timescale for regridding [T ~> s]
dzRegrid [inout]
Final change in interface positions [H ~> m or kg m-2]
initial [in]
Whether we're being called from an initialization routine (and expect diagnostics to work)
Callees call graph
Text view
mom_ale::ale_regrid_accelerated → mom_ale::ale_remap_set_h_vel
mom_ale::ale_regrid_accelerated → mom_ale::ale_remap_set_h_vel_via_dz
mom_ale::ale_regrid_accelerated → mom_ale::ale_remap_tracers
mom_ale::ale_regrid_accelerated → mom_ale::ale_remap_velocities
mom_ale::ale_regrid_accelerated → mom_ale::ale_update_regrid_weights
mom_ale::ale_regrid_accelerated → mom_domain_infra::do_group_pass
mom_ale::ale_regrid_accelerated → mom_domain_infra::interface::create_group_pass
mom_ale::ale_regrid_accelerated → mom_interface_heights::calc_derived_thermo
mom_ale::ale_regrid_accelerated → mom_regridding::convective_adjustment
mom_ale::ale_regrid_accelerated → mom_regridding::regridding_main
mom_ale::ale_regrid_accelerated → mom_remapping::remapping_core_h
Callers call graph
- subroutine ALE_remap_tracers(CS, G, GV, h_old, h_new, Reg, debug, dt, PCM_cell)
This routine takes care of remapping all tracer variables between the old and the new grids. This routine is called during initialization of the model at time=0, to remap initial conditions to the model grid. It is also called during a time step to update the state.
- Parameters
CS [in]
ALE control structure
G [in]
Ocean grid structure
GV [in]
Ocean vertical grid structure
h_old [in]
Thickness of source grid [H ~> m or kg m-2]
h_new [in]
Thickness of destination grid [H ~> m or kg m-2]
Reg
Tracer registry structure
debug [in]
If true, show the call tree
dt [in]
time step for diagnostics [T ~> s]
PCM_cell [in]
Use PCM remapping in cells where true
Callees call graph
Text view
mom_ale::ale_remap_tracers → mom_diag_mediator::interface::post_data
mom_ale::ale_remap_tracers → mom_error_handler::calltree_enter
mom_ale::ale_remap_tracers → mom_error_handler::calltree_leave
mom_ale::ale_remap_tracers → mom_error_handler::calltree_waypoint
mom_ale::ale_remap_tracers → mom_remapping::remapping_core_h
- subroutine ALE_remap_set_h_vel(CS, G, GV, h_new, h_u, h_v, OBC, debug)
This routine sets the thicknesses at velocity points used for vertical remapping.
- Parameters
CS [in]
ALE control structure
G [in]
Ocean grid structure
GV [in]
Ocean vertical grid structure
h_new [in]
Thickness at tracer points of the grid being interpolated to velocity points [H ~> m or kg m-2]
h_u [inout]
Grid thickness at zonal velocity points [H ~> m or kg m-2]
h_v [inout]
Grid thickness at meridional velocity points [H ~> m or kg m-2]
OBC
Open boundary structure
debug [in]
If true, show the call tree
Callees call graph
- subroutine ALE_remap_set_h_vel_via_dz(CS, G, GV, h_new, h_u, h_v, OBC, h_old, dzInterface, debug)
This routine sets the thicknesses at velocity points used for vertical remapping using a combination of the old grid and interface movements.
- Parameters
CS [in]
ALE control structure
G [in]
Ocean grid structure
GV [in]
Ocean vertical grid structure
h_new [in]
Thickness at tracer points of the grid being interpolated to velocity points [H ~> m or kg m-2]
h_u [inout]
Grid thickness at zonal velocity points [H ~> m or kg m-2]
h_v [inout]
Grid thickness at meridional velocity points [H ~> m or kg m-2]
OBC
Open boundary structure
h_old [in]
Thickness of source grid when generating the destination grid via the old algorithm [H ~> m or kg m-2]
dzInterface [in]
Change in interface position [H ~> m or kg m-2]
debug [in]
If true, show the call tree
Callees call graph
- subroutine ALE_remap_set_h_vel_partial(CS, G, GV, h_mask, h_u, h_v)
Mask out the thicknesses at velocity points where they are below the minimum depth at adjacent tracer points
- Parameters
CS [in]
ALE control structure
G [in]
Ocean grid structure
GV [in]
Ocean vertical grid structure
h_mask [in]
Thickness at tracer points used to apply the partial cell masking [H ~> m or kg m-2]
h_u [inout]
Grid thickness at zonal velocity points [H ~> m or kg m-2]
h_v [inout]
Grid thickness at meridional velocity points [H ~> m or kg m-2]
Callees call graph
Callers call graph
subroutine ALE_remap_set_h_vel_OBC(G, GV, h_new, h_u, h_v, OBC)
- Parameters
G [in]
Ocean grid structure
GV [in]
Ocean vertical grid structure
h_new [in]
Thickness at tracer points of the grid being interpolated to velocity points [H ~> m or kg m-2]
h_u [inout]
Grid thickness at zonal velocity points [H ~> m or kg m-2]
h_v [inout]
Grid thickness at meridional velocity points [H ~> m or kg m-2]
OBC
Open boundary structure
Callers call graph
- subroutine ALE_remap_velocities(CS, G, GV, h_old_u, h_old_v, h_new_u, h_new_v, u, v, debug, dt, allow_preserve_variance)
This routine remaps velocity components between the old and the new grids, with thicknesses at velocity points taken to be arithmetic averages of tracer thicknesses. This routine may be called during initialization of the model at time=0, to remap initial conditions to the model grid. It is also called during a time step to update the state.
- Parameters
CS [in]
ALE control structure
G [in]
Ocean grid structure
GV [in]
Ocean vertical grid structure
h_old_u [in]
Source grid thickness at zonal velocity points [H ~> m or kg m-2]
h_old_v [in]
Source grid thickness at meridional velocity points [H ~> m or kg m-2]
h_new_u [in]
Destination grid thickness at zonal velocity points [H ~> m or kg m-2]
h_new_v [in]
Destination grid thickness at meridional velocity points [H ~> m or kg m-2]
u [inout]
Zonal velocity [L T-1 ~> m s-1]
v [inout]
Meridional velocity [L T-1 ~> m s-1]
debug [in]
If true, show the call tree
dt [in]
time step for diagnostics [T ~> s]
allow_preserve_variance [in]
If true, enables ke-conserving correction
Callees call graph
Text view
mom_ale::ale_remap_velocities → mom_ale::mask_near_bottom_vel
mom_ale::ale_remap_velocities → mom_diag_mediator::interface::post_data
mom_ale::ale_remap_velocities → mom_error_handler::calltree_enter
mom_ale::ale_remap_velocities → mom_error_handler::calltree_leave
mom_ale::ale_remap_velocities → mom_error_handler::calltree_waypoint
mom_ale::ale_remap_velocities → mom_error_handler::mom_error
mom_ale::ale_remap_velocities → mom_remapping::remapping_core_h
- subroutine ALE_remap_interface_vals(CS, G, GV, h_old, h_new, int_val)
Interpolate to find an updated array of values at interfaces after remapping.
- Parameters
CS [in]
ALE control structure
G [in]
Ocean grid structure
GV [in]
Ocean vertical grid structure
h_old [in]
Thickness of source grid [H ~> m or kg m-2]
h_new [in]
Thickness of destination grid [H ~> m or kg m-2]
int_val [inout]
The interface values to interpolate [A]
Callers call graph
- subroutine ALE_remap_vertex_vals(CS, G, GV, h_old, h_new, vert_val)
Interpolate to find an updated array of values at vertices of tracer cells after remapping.
- Parameters
CS [in]
ALE control structure
G [in]
Ocean grid structure
GV [in]
Ocean vertical grid structure
h_old [in]
Thickness of source grid [H ~> m or kg m-2]
h_new [in]
Thickness of destination grid [H ~> m or kg m-2]
vert_val [inout]
The interface values to interpolate [A]
- subroutine apply_partial_cell_mask(h1, h_mask)
Mask out thicknesses to 0 when their running sum exceeds a specified value.
- Parameters
h1 [inout]
A column of thicknesses to be masked out after their running vertical sum exceeds h_mask [H ~> m or kg m-2]
h_mask [in]
The depth after which the thicknesses in h1 are masked out [H ~> m or kg m-2]
Callers call graph
- subroutine mask_near_bottom_vel(vel, h, h_BBL, h_thin, nk)
Zero out velocities in a column in very thin layers near the seafloor
- Parameters
nk [in]
The number of layers in this column
vel [inout]
The velocity component being zeroed out [L T-1 ~> m s-1]
h [in]
The layer thicknesses at velocity points [H ~> m or kg m-2]
h_BBL [in]
The thickness of the near-bottom region over which to apply the filtering [H ~> m or kg m-2]
h_thin [in]
A layer thickness below which the filtering is applied [H ~> m or kg m-2]
- subroutine ALE_remap_scalar(CS, G, GV, nk_src, h_src, s_src, h_dst, s_dst, all_cells, old_remap)
Remaps a single scalar between grids described by thicknesses h_src and h_dst. h_dst must be dimensioned as a model array with GV%ke layers while h_src can have an arbitrary number of layers specified by nk_src.
- Parameters
CS [in]
Remapping control structure
G [in]
Ocean grid structure
GV [in]
Ocean vertical grid structure
nk_src [in]
Number of levels on source grid
h_src [in]
Level thickness of source grid [H ~> m or kg m-2] or other units if H_neglect is provided
s_src [in]
Scalar on source grid, in arbitrary units [A]
h_dst [in]
Level thickness of destination grid in the same units as h_src, often [H ~> m or kg m-2]
s_dst [inout]
Scalar on destination grid, in the same arbitrary units as s_src [A]
all_cells [in]
If false, only reconstruct for non-vanished cells. Use all vanished layers otherwise (default).
old_remap [in]
If true, use the old "remapping_core_w" method, otherwise use "remapping_core_h".
Callees call graph
- subroutine TS_PLM_edge_values(CS, S_t, S_b, T_t, T_b, G, GV, tv, h, bdry_extrap)
Calculate edge values (top and bottom of layer) for T and S consistent with a PLM reconstruction in the vertical direction. Boundary reconstructions are PCM unless bdry_extrap is true.
- Parameters
G [in]
ocean grid structure
GV [in]
Ocean vertical grid structure
CS [inout]
module control structure
S_t [inout]
Salinity at the top edge of each layer [S ~> ppt]
S_b [inout]
Salinity at the bottom edge of each layer [S ~> ppt]
T_t [inout]
Temperature at the top edge of each layer [C ~> degC]
T_b [inout]
Temperature at the bottom edge of each layer [C ~> degC]
tv [in]
thermodynamics structure
h [in]
layer thickness [H ~> m or kg m-2]
bdry_extrap [in]
If true, use high-order boundary extrapolation within boundary cells
- subroutine ALE_PLM_edge_values(CS, G, GV, h, Q, bdry_extrap, Q_t, Q_b)
Calculate edge values (top and bottom of layer) 3d scalar array. Boundary reconstructions are PCM unless bdry_extrap is true.
- Parameters
CS [in]
module control structure
G [in]
ocean grid structure
GV [in]
Ocean vertical grid structure
h [in]
layer thickness [H ~> m or kg m-2]
Q [in]
3d scalar array, in arbitrary units [A]
bdry_extrap [in]
If true, use high-order boundary extrapolation within boundary cells
Q_t [inout]
Scalar at the top edge of each layer [A]
Q_b [inout]
Scalar at the bottom edge of each layer [A]
Callees call graph
- subroutine TS_PPM_edge_values(CS, S_t, S_b, T_t, T_b, G, GV, tv, h, bdry_extrap)
Calculate edge values (top and bottom of layer) for T and S consistent with a PPM reconstruction in the vertical direction. Boundary reconstructions are PCM unless bdry_extrap is true.
- Parameters
G [in]
ocean grid structure
GV [in]
Ocean vertical grid structure
CS [inout]
module control structure
S_t [inout]
Salinity at the top edge of each layer [S ~> ppt]
S_b [inout]
Salinity at the bottom edge of each layer [S ~> ppt]
T_t [inout]
Temperature at the top edge of each layer [C ~> degC]
T_b [inout]
Temperature at the bottom edge of each layer [C ~> degC]
tv [in]
thermodynamics structure
h [in]
layer thicknesses [H ~> m or kg m-2]
bdry_extrap [in]
If true, use high-order boundary extrapolation within boundary cells
Callees call graph
- subroutine TS_PLM_WLS_edge_values(CS, S_t, S_b, T_t, T_b, G, GV, tv, h)
Calculate edge values (top and bottom of layer) for T and S consistent with a PLM reconstruction in the vertical direction that uses weighted least squares for the slope.
- Parameters
G [in]
ocean grid structure
GV [in]
Ocean vertical grid structure
CS [inout]
module control structure
S_t [inout]
Salinity at the top edge of each layer [S ~> ppt]
S_b [inout]
Salinity at the bottom edge of each layer [S ~> ppt]
T_t [inout]
Temperature at the top edge of each layer [C ~> degC]
T_b [inout]
Temperature at the bottom edge of each layer [C ~> degC]
tv [in]
thermodynamics structure
h [in]
layer thickness [H ~> m or kg m-2]
recon
A PLM-WLS reconstruction
- subroutine ALE_initRegridding(G, GV, US, max_depth, param_file, mdl, regridCS)
Initializes regridding for the main ALE algorithm
- Parameters
G [in]
Grid structure
GV [in]
Ocean vertical grid structure
US [in]
A dimensional unit scaling type
max_depth [in]
The maximum depth of the ocean [Z ~> m].
param_file [in]
parameter file
mdl [in]
Name of calling module
regridCS [out]
Regridding parameters and work arrays
Callees call graph
Callers call graph
- function ALE_getCoordinate(CS)
Query the target coordinate interfaces positions
- Parameters
CS
module control structure
ALE_getCoordinate
The coordinate positions, in the appropriate units of the target coordinate, e.g. [Z ~> m] for z*, non-dimensional for sigma, etc.
- function ALE_getCoordinateUnits(CS)
Query the target coordinate units
- Parameters
CS
module control structure
- logical function ALE_remap_init_conds(CS)
Returns true if initial conditions should be regridded and remapped
- Parameters
CS
module control structure
- subroutine ALE_update_regrid_weights(dt, CS)
Updates the weights for time filtering the new grid generated in regridding
- Parameters
dt [in]
Time-step used between ALE calls [T ~> s]
CS
ALE control structure
- subroutine ALE_updateVerticalGridType(CS, GV)
Update the vertical grid type with ALE information. This subroutine sets information in the verticalGrid_type to be consistent with the use of ALE mode.
- Parameters
CS
ALE control structure
GV
vertical grid information
Callees call graph
Callers call graph
- subroutine ALE_writeCoordinateFile(CS, GV, directory)
Write the vertical coordinate information into a file. This subroutine writes out a file containing any available data related to the vertical grid used by the MOM ocean model when in ALE mode.
- Parameters
CS
module control structure
GV [in]
ocean vertical grid structure
directory [in]
directory for writing grid info
- subroutine ALE_initThicknessToCoord(CS, G, GV, h, height_units)
Set h to coordinate values for fixed coordinate systems
- Parameters
CS [inout]
module control structure
G [in]
module grid structure
GV [in]
Ocean vertical grid structure
h [out]
layer thickness in thickness units [H ~> m or kg m-2] or height units [Z ~> m]
height_units [in]
If present and true, the thicknesses are in height units