MOM6
MOM_regridding.F90 File Reference
#include <MOM_memory.h>
Include dependency graph for MOM_regridding.F90:

Go to the source code of this file.

Data Types

type  mom_regridding::regridding_cs
 Regridding control structure. More...
 

Modules

module  mom_regridding
 Generates vertical grids as part of the ALE algorithm.
 

Functions/Subroutines

subroutine, public mom_regridding::initialize_regridding (CS, GV, US, max_depth, param_file, mdl, coord_mode, param_prefix, param_suffix)
 Initialization and configures a regridding control structure based on customizable run-time parameters. More...
 
subroutine mom_regridding::check_grid_def (filename, varname, expected_units, msg, ierr)
 Do some basic checks on the vertical grid definition file, variable. More...
 
subroutine, public mom_regridding::end_regridding (CS)
 Deallocation of regridding memory. More...
 
subroutine, public mom_regridding::regridding_main (remapCS, CS, G, GV, h, tv, h_new, dzInterface, frac_shelf_h, conv_adjust)
 Dispatching regridding routine for orchestrating regridding & remapping. More...
 
subroutine mom_regridding::calc_h_new_by_dz (CS, G, GV, h, dzInterface, h_new)
 Calculates h_new from h + delta_k dzInterface. More...
 
subroutine, public mom_regridding::check_remapping_grid (G, GV, h, dzInterface, msg)
 Check that the total thickness of two grids match. More...
 
subroutine, public mom_regridding::check_grid_column (nk, depth, h, dzInterface, msg)
 Check that the total thickness of new and old grids are consistent. More...
 
subroutine mom_regridding::filtered_grid_motion (CS, nk, z_old, z_new, dz_g)
 Returns the change in interface position motion after filtering and assuming the top and bottom interfaces do not move. The filtering is a function of depth, and is applied as the integrated average filtering over the trajectory of the interface. By design, this code can not give tangled interfaces provided that z_old and z_new are not already tangled. More...
 
subroutine mom_regridding::build_zstar_grid (CS, G, GV, h, dzInterface, frac_shelf_h)
 Builds a z*-ccordinate grid with partial steps (Adcroft and Campin, 2004). z* is defined as z* = (z-eta)/(H+eta)*H s.t. z*=0 when z=eta and z*=-H when z=-H . More...
 
subroutine mom_regridding::build_sigma_grid (CS, G, GV, h, dzInterface)
 This routine builds a grid based on terrain-following coordinates. More...
 
subroutine mom_regridding::build_rho_grid (G, GV, h, tv, dzInterface, remapCS, CS)
 This routine builds a new grid based on a given set of target interface densities. More...
 
subroutine mom_regridding::build_grid_hycom1 (G, GV, h, tv, h_new, dzInterface, CS)
 Builds a simple HyCOM-like grid with the deepest location of potential density interpolated from the column profile and a clipping of depth for each interface to a fixed z* or p* grid. This should probably be (optionally?) changed to find the nearest location of the target density. More...
 
subroutine mom_regridding::build_grid_adaptive (G, GV, h, tv, dzInterface, remapCS, CS)
 This subroutine builds an adaptive grid that follows density surfaces where possible, subject to constraints on the smoothness of interface heights. More...
 
subroutine mom_regridding::build_grid_slight (G, GV, h, tv, dzInterface, CS)
 Builds a grid that tracks density interfaces for water that is denser than the surface density plus an increment of some number of layers, and uses all lighter layers uniformly above this location. Note that this amounts to interpolating to find the depth of an arbitrary (non-integer) interface index which should make the results vary smoothly in space to the extent that the surface density and interior stratification vary smoothly in space. Over shallow topography, this will tend to give a uniform sigma-like coordinate. For sufficiently shallow water, a minimum grid spacing is used to avoid certain instabilities. More...
 
subroutine mom_regridding::adjust_interface_motion (CS, nk, h_old, dz_int)
 Adjust dz_Interface to ensure non-negative future thicknesses. More...
 
subroutine mom_regridding::build_grid_arbitrary (G, GV, h, dzInterface, h_new, CS)
 
subroutine, public mom_regridding::inflate_vanished_layers_old (CS, G, GV, h)
 
subroutine mom_regridding::convective_adjustment (G, GV, h, tv)
 Achieve convective adjustment by swapping layers. More...
 
real function, dimension(nk), public mom_regridding::uniformresolution (nk, coordMode, maxDepth, rhoLight, rhoHeavy)
 Return a uniform resolution vector in the units of the coordinate. More...
 
subroutine mom_regridding::initcoord (CS, GV, US, coord_mode)
 Initialize the coordinate resolutions by calling the appropriate initialization routine for the specified coordinate mode. More...
 
subroutine, public mom_regridding::setcoordinateresolution (dz, CS, scale)
 Set the fixed resolution data. More...
 
subroutine, public mom_regridding::set_target_densities_from_gv (GV, US, CS)
 Set target densities based on the old Rlay variable. More...
 
subroutine, public mom_regridding::set_target_densities (CS, rho_int)
 Set target densities based on vector of interface values. More...
 
subroutine, public mom_regridding::set_regrid_max_depths (CS, max_depths, units_to_H)
 Set maximum interface depths based on a vector of input values. More...
 
subroutine, public mom_regridding::set_regrid_max_thickness (CS, max_h, units_to_H)
 Set maximum layer thicknesses based on a vector of input values. More...
 
real function, dimension(cs%nk), public mom_regridding::getcoordinateresolution (CS, undo_scaling)
 Query the fixed resolution data. More...
 
real function, dimension(cs%nk+1), public mom_regridding::getcoordinateinterfaces (CS, undo_scaling)
 Query the target coordinate interface positions. More...
 
character(len=20) function, public mom_regridding::getcoordinateunits (CS)
 Query the target coordinate units. More...
 
character(len=20) function, public mom_regridding::getcoordinateshortname (CS)
 Query the short name of the coordinate. More...
 
subroutine, public mom_regridding::set_regrid_params (CS, boundary_extrapolation, min_thickness, old_grid_weight, interp_scheme, depth_of_time_filter_shallow, depth_of_time_filter_deep, compress_fraction, dz_min_surface, nz_fixed_surface, Rho_ML_avg_depth, nlay_ML_to_interior, fix_haloclines, halocline_filt_len, halocline_strat_tol, integrate_downward_for_e, adaptTimeRatio, adaptZoom, adaptZoomCoeff, adaptBuoyCoeff, adaptAlpha, adaptDoMin)
 Can be used to set any of the parameters for MOM_regridding. More...
 
integer function, public mom_regridding::get_regrid_size (CS)
 Returns the number of levels/layers in the regridding control structure. More...
 
type(zlike_cs) function, public mom_regridding::get_zlike_cs (CS)
 This returns a copy of the zlike_CS stored in the regridding control structure. More...
 
type(sigma_cs) function, public mom_regridding::get_sigma_cs (CS)
 This returns a copy of the sigma_CS stored in the regridding control structure. More...
 
type(rho_cs) function, public mom_regridding::get_rho_cs (CS)
 This returns a copy of the rho_CS stored in the regridding control structure. More...
 
real function, dimension(cs%nk), public mom_regridding::getstaticthickness (CS, SSH, depth)
 Return coordinate-derived thicknesses for fixed coordinate systems. More...
 
subroutine mom_regridding::dz_function1 (string, dz)
 Parses a string and generates a dz(:) profile that goes like k**power. More...
 
integer function mom_regridding::rho_function1 (string, rho_target)
 Parses a string and generates a rho_target(:) profile with refined resolution downward and returns the number of levels. More...
 

Variables

character(len= *), parameter, public mom_regridding::regriddingcoordinatemodedoc = " LAYER - Isopycnal or stacked shallow water layers\n"// " ZSTAR, Z* - stretched geopotential z*\n"// " SIGMA_SHELF_ZSTAR - stretched geopotential z* ignoring shelf\n"// " SIGMA - terrain following coordinates\n"// " RHO - continuous isopycnal\n"// " HYCOM1 - HyCOM-like hybrid coordinate\n"// " SLIGHT - stretched coordinates above continuous isopycnal\n"// " ADAPTIVE - optimize for smooth neutral density surfaces"
 Documentation for coordinate options. More...
 
character(len= *), parameter, public mom_regridding::regriddinginterpschemedoc = " P1M_H2 (2nd-order accurate)\n"// " P1M_H4 (2nd-order accurate)\n"// " P1M_IH4 (2nd-order accurate)\n"// " PLM (2nd-order accurate)\n"// " PPM_H4 (3rd-order accurate)\n"// " PPM_IH4 (3rd-order accurate)\n"// " P3M_IH4IH3 (4th-order accurate)\n"// " P3M_IH6IH5 (4th-order accurate)\n"// " PQM_IH4IH3 (4th-order accurate)\n"// " PQM_IH6IH5 (5th-order accurate)"
 Documentation for regridding interpolation schemes. More...
 
character(len= *), parameter, public mom_regridding::regriddingdefaultinterpscheme = "P1M_H2"
 Default interpolation scheme. More...
 
logical, parameter, public mom_regridding::regriddingdefaultboundaryextrapolation = .false.
 Default mode for boundary extrapolation. More...
 
real, parameter, public mom_regridding::regriddingdefaultminthickness = 1.e-3
 Default minimum thickness for some coordinate generation modes. More...