MOM_set_visc module reference

Calculates various values related to the bottom boundary layer, such as the viscosity and thickness of the BBL (set_viscous_BBL).

Data Types

set_visc_CS

Control structure for MOM_set_visc

Functions/Subroutines

set_viscous_BBL

Calculates the thickness of the bottom boundary layer and the viscosity within that layer.

find_L_open_uniform_slope

Determine the normalized open length of each interface, given the edge depths and normalized volumes below each interface.

find_L_open_concave_trigonometric

Determine the normalized open length of each interface for concave bathymetry (from the ocean perspective) using trigonometric expressions. In this case there can be two separate open regions.

find_L_open_concave_iterative

Determine the normalized open length of each interface for concave bathymetry (from the ocean perspective) using iterative methods to solve the relevant cubic equations. In this case there can be two separate open regions.

test_L_open_concave

Test the validity the normalized open lengths of each interface for concave bathymetry (from the ocean perspective) by evaluating and returing the relevant cubic equations.

find_L_open_convex

Determine the normalized open length of each interface for convex bathymetry (from the ocean perspective) using Newton's method iterations. In this case there is a single open region with the minimum depth at one edge of the cell.

set_v_at_u

This subroutine finds a thickness-weighted value of v at the u-points.

set_u_at_v

This subroutine finds a thickness-weighted value of u at the v-points.

set_viscous_ML

Calculates the thickness of the surface boundary layer for applying an elevated viscosity.

set_visc_register_restarts

Register any fields associated with the vertvisc_type.

remap_vertvisc_aux_vars

This subroutine does remapping for the auxiliary restart variables in a vertvisc_type that are used across timesteps

set_visc_init

Initializes the MOM_set_visc control structure

set_visc_end

This subroutine dellocates any memory in the set_visc control structure.

Detailed Description

This would also be the module in which other viscous quantities that are flow-independent might be set. This information is transmitted to other modules via a vertvisc type structure.

The same code is used for the two velocity components, by indirectly referencing the velocities and defining a handful of direction-specific defined variables.

Type Documentation

type, public :: set_visc_CS

Control structure for MOM_set_visc

Parameters
  • initialized

    True if this control structure has been initialized.

  • Hbbl

    The static bottom boundary layer thickness [H ~> m or kg m-2]. Runtime parameter HBBL.

  • dz_bbl

    The static bottom boundary layer thickness in height units [Z ~> m]. Runtime parameter HBBL.

  • cdrag

    The quadratic drag coefficient [nondim]. Runtime parameter CDRAG.

  • c_Smag

    The Laplacian Smagorinsky coefficient for calculating the drag in channels [nondim].

  • drag_bg_vel

    An assumed unresolved background velocity for calculating the bottom drag [L T-1 ~> m s-1]. Runtime parameter DRAG_BG_VEL. Should not be used if BBL_USE_TIDAL_BG is True.

  • BBL_thick_min

    The minimum bottom boundary layer thickness [Z ~> m]. This might be Kv / (cdrag * drag_bg_vel) to give Kv as the minimum near-bottom viscosity.

  • Htbl_shelf

    A nominal thickness of the surface boundary layer for use in calculating the near-surface velocity [H ~> m or kg m-2].

  • Htbl_shelf_min

    The minimum surface boundary layer thickness [Z ~> m].

  • KV_BBL_min

    The minimum viscosity in the bottom boundary layer [H Z T-1 ~> m2 s-1 or Pa s]

  • KV_TBL_min

    The minimum viscosity in the top boundary layer [H Z T-1 ~> m2 s-1 or Pa s]

  • bottomdraglaw

    If true, the bottom stress is calculated with a drag law c_drag*|u|*u. The velocity magnitude may be an assumed value or it may be based on the actual velocity in the bottommost HBBL, depending on whether linear_drag is true. Runtime parameter BOTTOMDRAGLAW.

  • bottomdragmap

    If true, apply the spatially varying drag coefficient (cdrag_2d) instead of the spatially uniform drag coefficient (cdrag).

  • body_force_drag

    If true, the bottom stress is imposed as an explicit body force applied over a fixed distance from the bottom, rather than as an implicit calculation based on an enhanced near-bottom viscosity.

  • BBL_use_EOS

    If true, use the equation of state in determining the properties of the bottom boundary layer.

  • linear_drag

    If true, the drag law is cdrag*``DRAG_BG_VEL``*u. Runtime parameter LINEAR_DRAG.

  • Channel_drag

    If true, the drag is exerted directly on each layer according to what fraction of the bottom they overlie.

  • Chan_drag_max_vol

    The maximum bottom boundary layer volume within which the channel drag is applied, normalized by the full cell area, or a negative value to apply no maximum [Z ~> m].

  • channel_break_depth

    When CHANNEL_DRAG is true, the bathymetric depth interpolated to the vorticity point is a combination of the harmonic mean of the adjacent velocity point depths below this depth [Z ~> m] and the arithmetic mean of the adjacent depths above it, to roughly mimic a continental shelf break profile. The internal version of this depth uses the same offset (G%Z_ref) as the bathymetry.

  • correct_BBL_bounds

    If true, uses the correct bounds on the BBL thickness and viscosity so that the bottom layer feels the intended drag.

  • RiNo_mix

    If true, use Richardson number dependent mixing.

  • dynamic_viscous_ML

    If true, use a bulk Richardson number criterion to determine the mixed layer thickness for viscosity.

  • bulk_Ri_ML

    The bulk mixed layer used to determine the thickness of the viscous mixed layer [nondim]

  • omega

    The Earth's rotation rate [T-1 ~> s-1].

  • ustar_min

    A minimum value of ustar to avoid numerical problems [H T-1 ~> m s-1 or kg m-2 s-1]. If the value is small enough, this should not affect the solution.

  • TKE_decay

    The ratio of the natural Ekman depth to the TKE decay scale [nondim]

  • omega_frac

    When setting the decay scale for turbulence, use this fraction of the absolute rotation rate blended with the local value of f, as sqrt((1-of)*f^2 + of*4*omega^2) [nondim]

  • tideampfac2

    A factor to multiply by tideamp to convert to a mean ustar, accounts for conversion of amplitude to mean magnitude over a time average much longer than the tidal periods and for non-commuting conversion of mean tideamp to mean ustar**3 [nondim]

  • concave_trigonometric_L

    If true, use trigonometric expressions to determine the fractional open interface lengths for concave topography.

  • answer_date

    The vintage of the order of arithmetic and expressions in the set viscosity calculations. Values below 20190101 recover the answers from the end of 2018, while higher values use updated and more robust forms of the same expressions. Values below 20260704 use the non-reproducible power operator in place of cuberoot() when finding the open distances with CHANNEL_DRAG.

  • debug

    If true, write verbose checksums for debugging purposes.

  • BBL_use_tidal_bg

    If true, use a tidal background amplitude for the bottom velocity when computing the bottom stress.

  • inputdir

    The directory for input files.

  • OBC

    Open boundaries control structure

  • diag

    A structure that is used to regulate the timing of diagnostic output.

  • cdrag_u

    The spatially varying quadratic drag coefficient [nondim]

  • cdrag_v

    The spatially varying quadratic drag coefficient [nondim]

  • tideamp

    RMS tidal amplitude at h points [L T-1 ~> m s-1]

  • bbl_u

    BBL mean U current [L T-1 ~> m s-1]

  • id_bbl_thick_u

    Diagnostics handles

  • id_kv_bbl_u

    Diagnostics handles

  • id_bbl_u

    Diagnostics handles

  • id_bbl_thick_v

    Diagnostics handles

  • id_kv_bbl_v

    Diagnostics handles

  • id_bbl_v

    Diagnostics handles

  • id_Ray_u

    Diagnostics handles

  • id_Ray_v

    Diagnostics handles

  • id_nkml_visc_u

    Diagnostics handles

  • id_nkml_visc_v

    Diagnostics handles

Functions/Subroutine Documentation

subroutine set_viscous_BBL(u, v, h, tv, visc, G, GV, US, CS, pbv)

Calculates the thickness of the bottom boundary layer and the viscosity within that layer.

Parameters
  • G [inout]

    The ocean's grid structure.

  • GV [in]

    The ocean's vertical grid structure.

  • US [in]

    A dimensional unit scaling type

  • u [in]

    The zonal velocity [L T-1 ~> m s-1].

  • v [in]

    The meridional velocity [L T-1 ~> m s-1].

  • h [in]

    Layer thicknesses [H ~> m or kg m-2].

  • tv [in]

    A structure containing pointers to any available thermodynamic fields. Absent fields have NULL pointers.

  • visc [inout]

    A structure containing vertical viscosities and related fields.

  • CS [inout]

    The control structure returned by a previous call to set_visc_init.

  • pbv [in]

    porous barrier fractional cell metrics

Callees call graph
Callees of mom_set_visc::set_viscous_bbl calls cluster_mom_checksums MOM_checksums cluster_mom_diag_mediator MOM_diag_mediator cluster_mom_eos MOM_EOS cluster_mom_error_handler MOM_error_handler cluster_mom_interface_heights MOM_interface_heights cluster_mom_set_visc MOM_set_visc mom_checksums::interface::hchksum hchksum (interface) mom_checksums::interface::uvchksum uvchksum (interface) mom_diag_mediator::interface::post_data post_data (interface) mom_eos::interface::calculate_density calculate_density (interface) mom_eos::interface::calculate_density_derivs calculate_density_derivs (interface) mom_error_handler::mom_error MOM_error mom_interface_heights::interface::thickness_to_dz thickness_to_dz (interface) mom_set_visc::find_l_open_concave_iterative find_L_open_concave_iterative [private/internal] mom_set_visc::find_l_open_concave_trigonometric find_L_open_concave_trigonometric [private/internal] mom_set_visc::find_l_open_convex find_L_open_convex [private/internal] mom_set_visc::find_l_open_uniform_slope find_L_open_uniform_slope [private/internal] mom_set_visc::set_u_at_v set_u_at_v mom_set_visc::set_v_at_u set_v_at_u mom_set_visc::set_viscous_bbl set_viscous_BBL mom_set_visc::set_viscous_bbl->mom_checksums::interface::hchksum mom_set_visc::set_viscous_bbl->mom_checksums::interface::uvchksum mom_set_visc::set_viscous_bbl->mom_diag_mediator::interface::post_data mom_set_visc::set_viscous_bbl->mom_eos::interface::calculate_density mom_set_visc::set_viscous_bbl->mom_eos::interface::calculate_density_derivs mom_set_visc::set_viscous_bbl->mom_error_handler::mom_error mom_set_visc::set_viscous_bbl->mom_interface_heights::interface::thickness_to_dz mom_set_visc::set_viscous_bbl->mom_set_visc::find_l_open_concave_iterative mom_set_visc::set_viscous_bbl->mom_set_visc::find_l_open_concave_trigonometric mom_set_visc::set_viscous_bbl->mom_set_visc::find_l_open_convex mom_set_visc::set_viscous_bbl->mom_set_visc::find_l_open_uniform_slope mom_set_visc::set_viscous_bbl->mom_set_visc::set_u_at_v mom_set_visc::set_viscous_bbl->mom_set_visc::set_v_at_u mom_set_visc::test_l_open_concave test_L_open_concave [private/internal] mom_set_visc::set_viscous_bbl->mom_set_visc::test_l_open_concave
Text view
Callers call graph
Callers of mom_set_visc::set_viscous_bbl calls cluster_mom MOM cluster_mom_set_visc MOM_set_visc mom::step_mom_dynamics step_MOM_dynamics [private/internal] mom_set_visc::set_viscous_bbl set_viscous_BBL mom::step_mom_dynamics->mom_set_visc::set_viscous_bbl mom::step_mom_thermo step_MOM_thermo [private/internal] mom::step_mom_thermo->mom_set_visc::set_viscous_bbl
Text view
subroutine find_L_open_uniform_slope(vol_below, Dp, Dm, L, GV)

Determine the normalized open length of each interface, given the edge depths and normalized volumes below each interface.

Parameters
  • GV [in]

    The ocean's vertical grid structure.

  • vol_below [in]

    The volume below each interface, normalized by the full horizontal area of a velocity cell [Z ~> m]

  • Dp [in]

    The larger of the two depths at the edge of a velocity cell [Z ~> m]

  • Dm [in]

    The smaller of the two depths at the edge of a velocity cell [Z ~> m]

  • L [out]

    The fraction of the full cell width that is open at the depth of each interface [nondim]

Callers call graph
Callers of mom_set_visc::find_l_open_uniform_slope calls cluster_mom_set_visc MOM_set_visc mom_set_visc::find_l_open_uniform_slope find_L_open_uniform_slope [private/internal] mom_set_visc::set_viscous_bbl set_viscous_BBL mom_set_visc::set_viscous_bbl->mom_set_visc::find_l_open_uniform_slope
Text view
subroutine find_L_open_concave_trigonometric(vol_below, D_vel, Dp, Dm, L, GV)

Determine the normalized open length of each interface for concave bathymetry (from the ocean perspective) using trigonometric expressions. In this case there can be two separate open regions.

Parameters
  • GV [in]

    The ocean's vertical grid structure.

  • vol_below [in]

    The volume below each interface, normalized by the full horizontal area of a velocity cell [Z ~> m]

  • D_vel [in]

    The average bottom depth at a velocity point [Z ~> m]

  • Dp [in]

    The larger of the two depths at the edge of a velocity cell [Z ~> m]

  • Dm [in]

    The smaller of the two depths at the edge of a velocity cell [Z ~> m]

  • L [out]

    The fraction of the full cell width that is open at the depth of each interface [nondim]

Callers call graph
Callers of mom_set_visc::find_l_open_concave_trigonometric calls cluster_mom_set_visc MOM_set_visc mom_set_visc::find_l_open_concave_trigonometric find_L_open_concave_trigonometric [private/internal] mom_set_visc::set_viscous_bbl set_viscous_BBL mom_set_visc::set_viscous_bbl->mom_set_visc::find_l_open_concave_trigonometric
Text view
subroutine find_L_open_concave_iterative(vol_below, D_vel, Dp, Dm, L, GV)

Determine the normalized open length of each interface for concave bathymetry (from the ocean perspective) using iterative methods to solve the relevant cubic equations. In this case there can be two separate open regions.

Parameters
  • GV [in]

    The ocean's vertical grid structure.

  • vol_below [in]

    The volume below each interface, normalized by the full horizontal area of a velocity cell [Z ~> m]

  • D_vel [in]

    The average bottom depth at a velocity point [Z ~> m]

  • Dp [in]

    The larger of the two depths at the edge of a velocity cell [Z ~> m]

  • Dm [in]

    The smaller of the two depths at the edge of a velocity cell [Z ~> m]

  • L [out]

    The fraction of the full cell width that is open at the depth of each interface [nondim]

Callers call graph
Callers of mom_set_visc::find_l_open_concave_iterative calls cluster_mom_set_visc MOM_set_visc mom_set_visc::find_l_open_concave_iterative find_L_open_concave_iterative [private/internal] mom_set_visc::set_viscous_bbl set_viscous_BBL mom_set_visc::set_viscous_bbl->mom_set_visc::find_l_open_concave_iterative
Text view
subroutine test_L_open_concave(vol_below, D_vel, Dp, Dm, L, vol_err, GV)

Test the validity the normalized open lengths of each interface for concave bathymetry (from the ocean perspective) by evaluating and returing the relevant cubic equations.

Parameters
  • GV [in]

    The ocean's vertical grid structure.

  • vol_below [in]

    The volume below each interface, normalized by the full horizontal area of a velocity cell [Z ~> m]

  • D_vel [in]

    The average bottom depth at a velocity point [Z ~> m]

  • Dp [in]

    The larger of the two depths at the edge of a velocity cell [Z ~> m]

  • Dm [in]

    The smaller of the two depths at the edge of a velocity cell [Z ~> m]

  • L [in]

    The fraction of the full cell width that is open at the depth of each interface [nondim]

  • vol_err [out]

    The difference between vol_below and the value obtained from using L in the cubic equation [Z ~> m]

Callers call graph
Callers of mom_set_visc::test_l_open_concave calls cluster_mom_set_visc MOM_set_visc mom_set_visc::set_viscous_bbl set_viscous_BBL mom_set_visc::test_l_open_concave test_L_open_concave [private/internal] mom_set_visc::set_viscous_bbl->mom_set_visc::test_l_open_concave
Text view
subroutine find_L_open_convex(vol_below, D_vel, Dp, Dm, L, GV, US, CS)

Determine the normalized open length of each interface for convex bathymetry (from the ocean perspective) using Newton's method iterations. In this case there is a single open region with the minimum depth at one edge of the cell.

Parameters
  • GV [in]

    The ocean's vertical grid structure.

  • vol_below [in]

    The volume below each interface, normalized by the full horizontal area of a velocity cell [Z ~> m]

  • D_vel [in]

    The average bottom depth at a velocity point [Z ~> m]

  • Dp [in]

    The larger of the two depths at the edge of a velocity cell [Z ~> m]

  • Dm [in]

    The smaller of the two depths at the edge of a velocity cell [Z ~> m]

  • L [out]

    The fraction of the full cell width that is open at the depth of each interface [nondim]

  • US [in]

    A dimensional unit scaling type

  • CS [in]

    The control structure returned by a previous call to set_visc_init.

Callees call graph
Callees of mom_set_visc::find_l_open_convex calls cluster_mom_intrinsic_functions MOM_intrinsic_functions cluster_mom_set_visc MOM_set_visc mom_intrinsic_functions::cuberoot cuberoot mom_set_visc::find_l_open_convex find_L_open_convex [private/internal] mom_set_visc::find_l_open_convex->mom_intrinsic_functions::cuberoot
Text view
Callers call graph
Callers of mom_set_visc::find_l_open_convex calls cluster_mom_set_visc MOM_set_visc mom_set_visc::find_l_open_convex find_L_open_convex [private/internal] mom_set_visc::set_viscous_bbl set_viscous_BBL mom_set_visc::set_viscous_bbl->mom_set_visc::find_l_open_convex
Text view
function set_v_at_u(v, h, G, GV, i, j, k, mask2dCv, OBC)

This subroutine finds a thickness-weighted value of v at the u-points.

Parameters
  • G [in]

    The ocean's grid structure

  • GV [in]

    Vertical grid structure

  • v [in]

    The meridional velocity [L T-1 ~> m s-1]

  • h [in]

    Layer thicknesses [H ~> m or kg m-2]

  • i [in]

    The i-index of the u-location to work on.

  • j [in]

    The j-index of the u-location to work on.

  • k [in]

    The k-index of the u-location to work on.

  • mask2dCv [in]

    A multiplicative mask of the v-points [nondim]

  • OBC

    A pointer to an open boundary condition structure

  • set_v_at_u

    The return value of v at u points points in the same units as u, i.e. [L T-1 ~> m s-1] or other units.

Callers call graph
Callers of mom_set_visc::set_v_at_u calls cluster_mom_set_visc MOM_set_visc mom_set_visc::set_v_at_u set_v_at_u mom_set_visc::set_viscous_bbl set_viscous_BBL mom_set_visc::set_viscous_bbl->mom_set_visc::set_v_at_u mom_set_visc::set_viscous_ml set_viscous_ML mom_set_visc::set_viscous_ml->mom_set_visc::set_v_at_u
Text view
function set_u_at_v(u, h, G, GV, i, j, k, mask2dCu, OBC)

This subroutine finds a thickness-weighted value of u at the v-points.

Parameters
  • G [in]

    The ocean's grid structure

  • GV [in]

    Vertical grid structure

  • u [in]

    The zonal velocity [L T-1 ~> m s-1] or other units.

  • h [in]

    Layer thicknesses [H ~> m or kg m-2]

  • i [in]

    The i-index of the u-location to work on.

  • j [in]

    The j-index of the u-location to work on.

  • k [in]

    The k-index of the u-location to work on.

  • mask2dCu [in]

    A multiplicative mask of the u-points [nondim]

  • OBC

    A pointer to an open boundary condition structure

  • set_u_at_v

    The return value of u at v points in the same units as u, i.e. [L T-1 ~> m s-1] or other units.

Callers call graph
Callers of mom_set_visc::set_u_at_v calls cluster_mom_set_visc MOM_set_visc mom_set_visc::set_u_at_v set_u_at_v mom_set_visc::set_viscous_bbl set_viscous_BBL mom_set_visc::set_viscous_bbl->mom_set_visc::set_u_at_v mom_set_visc::set_viscous_ml set_viscous_ML mom_set_visc::set_viscous_ml->mom_set_visc::set_u_at_v
Text view
subroutine set_viscous_ML(u, v, h, tv, forces, visc, dt, G, GV, US, CS)

Calculates the thickness of the surface boundary layer for applying an elevated viscosity.

A bulk Richardson criterion or the thickness of the topmost NKML layers (with a bulk mixed layer) are currently used. The thicknesses are given in terms of fractional layers, so that this thickness will move as the thickness of the topmost layers change.

Parameters
  • G [inout]

    The ocean's grid structure.

  • GV [in]

    The ocean's vertical grid structure.

  • US [in]

    A dimensional unit scaling type

  • u [in]

    The zonal velocity [L T-1 ~> m s-1].

  • v [in]

    The meridional velocity [L T-1 ~> m s-1].

  • h [in]

    Layer thicknesses [H ~> m or kg m-2].

  • tv [in]

    A structure containing pointers to any available thermodynamic fields. Absent fields have NULL pointers.

  • forces [in]

    A structure with the driving mechanical forces

  • visc [inout]

    A structure containing vertical viscosities and related fields.

  • dt [in]

    Time increment [T ~> s].

  • CS [inout]

    The control structure returned by a previous call to set_visc_init.

Callees call graph
Callees of mom_set_visc::set_viscous_ml calls cluster_mom_checksums MOM_checksums cluster_mom_diag_mediator MOM_diag_mediator cluster_mom_eos MOM_EOS cluster_mom_error_handler MOM_error_handler cluster_mom_forcing_type MOM_forcing_type cluster_mom_interface_heights MOM_interface_heights cluster_mom_set_visc MOM_set_visc mom_checksums::interface::uvchksum uvchksum (interface) mom_diag_mediator::interface::post_data post_data (interface) mom_eos::interface::calculate_density_derivs calculate_density_derivs (interface) mom_eos::interface::calculate_specific_vol_derivs calculate_specific_vol_derivs (interface) mom_error_handler::mom_error MOM_error mom_forcing_type::interface::find_ustar find_ustar (interface) mom_interface_heights::interface::thickness_to_dz thickness_to_dz (interface) mom_set_visc::set_u_at_v set_u_at_v mom_set_visc::set_v_at_u set_v_at_u mom_set_visc::set_viscous_ml set_viscous_ML mom_set_visc::set_viscous_ml->mom_checksums::interface::uvchksum mom_set_visc::set_viscous_ml->mom_diag_mediator::interface::post_data mom_set_visc::set_viscous_ml->mom_eos::interface::calculate_density_derivs mom_set_visc::set_viscous_ml->mom_eos::interface::calculate_specific_vol_derivs mom_set_visc::set_viscous_ml->mom_error_handler::mom_error mom_set_visc::set_viscous_ml->mom_forcing_type::interface::find_ustar mom_set_visc::set_viscous_ml->mom_interface_heights::interface::thickness_to_dz mom_set_visc::set_viscous_ml->mom_set_visc::set_u_at_v mom_set_visc::set_viscous_ml->mom_set_visc::set_v_at_u
Text view
Callers call graph
Callers of mom_set_visc::set_viscous_ml calls cluster_mom_dynamics_split_rk2 MOM_dynamics_split_RK2 cluster_mom_dynamics_split_rk2b MOM_dynamics_split_RK2b cluster_mom_dynamics_unsplit MOM_dynamics_unsplit cluster_mom_dynamics_unsplit_rk2 MOM_dynamics_unsplit_RK2 cluster_mom_set_visc MOM_set_visc mom_dynamics_split_rk2::step_mom_dyn_split_rk2 step_MOM_dyn_split_RK2 mom_set_visc::set_viscous_ml set_viscous_ML mom_dynamics_split_rk2::step_mom_dyn_split_rk2->mom_set_visc::set_viscous_ml mom_dynamics_split_rk2b::step_mom_dyn_split_rk2b step_MOM_dyn_split_RK2b mom_dynamics_split_rk2b::step_mom_dyn_split_rk2b->mom_set_visc::set_viscous_ml mom_dynamics_unsplit::step_mom_dyn_unsplit step_MOM_dyn_unsplit mom_dynamics_unsplit::step_mom_dyn_unsplit->mom_set_visc::set_viscous_ml mom_dynamics_unsplit_rk2::step_mom_dyn_unsplit_rk2 step_MOM_dyn_unsplit_RK2 mom_dynamics_unsplit_rk2::step_mom_dyn_unsplit_rk2->mom_set_visc::set_viscous_ml
Text view
subroutine set_visc_register_restarts(HI, G, GV, US, param_file, visc, restart_CS, use_ice_shelf)

Register any fields associated with the vertvisc_type.

Parameters
  • HI [in]

    A horizontal index type structure.

  • G [in]

    The ocean's grid structure.

  • GV [in]

    The ocean's vertical grid structure.

  • US [in]

    A dimensional unit scaling type

  • param_file [in]

    A structure to parse for run-time parameters.

  • visc [inout]

    A structure containing vertical viscosities and related fields. Allocated here.

  • restart_CS [inout]

    MOM restart control structure

  • use_ice_shelf [in]

    if true, register tau_shelf restarts

  • hfreeze

    If hfreeze > 0 [Z ~> m], melt potential will be computed.

Callees call graph
Callees of mom_set_visc::set_visc_register_restarts calls cluster_mom_cvmix_conv MOM_CVMix_conv cluster_mom_cvmix_shear MOM_CVMix_shear cluster_mom_file_parser MOM_file_parser cluster_mom_io MOM_io cluster_mom_kappa_shear MOM_kappa_shear cluster_mom_restart MOM_restart cluster_mom_safe_alloc MOM_safe_alloc cluster_mom_set_visc MOM_set_visc cluster_mom_verticalgrid MOM_verticalGrid mom_cvmix_conv::cvmix_conv_is_used CVMix_conv_is_used mom_cvmix_shear::cvmix_shear_is_used CVMix_shear_is_used mom_file_parser::closeparameterblock closeParameterBlock mom_file_parser::interface::get_param get_param (interface) mom_file_parser::openparameterblock openParameterBlock mom_io::var_desc var_desc mom_kappa_shear::kappa_shear_at_vertex kappa_shear_at_vertex mom_kappa_shear::kappa_shear_is_used kappa_shear_is_used mom_restart::interface::register_restart_field register_restart_field (interface) mom_restart::interface::register_restart_pair register_restart_pair (interface) mom_safe_alloc::interface::safe_alloc_ptr safe_alloc_ptr (interface) mom_set_visc::set_visc_register_restarts set_visc_register_restarts mom_set_visc::set_visc_register_restarts->mom_cvmix_conv::cvmix_conv_is_used mom_set_visc::set_visc_register_restarts->mom_cvmix_shear::cvmix_shear_is_used mom_set_visc::set_visc_register_restarts->mom_file_parser::closeparameterblock mom_set_visc::set_visc_register_restarts->mom_file_parser::interface::get_param mom_set_visc::set_visc_register_restarts->mom_file_parser::openparameterblock mom_set_visc::set_visc_register_restarts->mom_io::var_desc mom_set_visc::set_visc_register_restarts->mom_kappa_shear::kappa_shear_at_vertex mom_set_visc::set_visc_register_restarts->mom_kappa_shear::kappa_shear_is_used mom_set_visc::set_visc_register_restarts->mom_restart::interface::register_restart_field mom_set_visc::set_visc_register_restarts->mom_restart::interface::register_restart_pair mom_set_visc::set_visc_register_restarts->mom_safe_alloc::interface::safe_alloc_ptr mom_verticalgrid::get_thickness_units get_thickness_units mom_set_visc::set_visc_register_restarts->mom_verticalgrid::get_thickness_units
Text view
Callers call graph
Callers of mom_set_visc::set_visc_register_restarts calls cluster_mom MOM cluster_mom_set_visc MOM_set_visc mom::initialize_mom initialize_MOM mom_set_visc::set_visc_register_restarts set_visc_register_restarts mom::initialize_mom->mom_set_visc::set_visc_register_restarts
Text view
subroutine remap_vertvisc_aux_vars(G, GV, visc, h_old, h_new, ALE_CSp, OBC)

This subroutine does remapping for the auxiliary restart variables in a vertvisc_type that are used across timesteps

Parameters
  • G [inout]

    ocean grid structure

  • GV [in]

    ocean vertical grid structure

  • visc [inout]

    A structure containing vertical viscosities and related fields.

  • 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]

  • ALE_CSp

    ALE control structure to use when remapping

  • OBC

    Open boundary structure

Callees call graph
Callees of mom_set_visc::remap_vertvisc_aux_vars calls cluster_mom_ale MOM_ALE cluster_mom_set_visc MOM_set_visc mom_ale::ale_remap_interface_vals ALE_remap_interface_vals mom_ale::ale_remap_vertex_vals ALE_remap_vertex_vals mom_set_visc::remap_vertvisc_aux_vars remap_vertvisc_aux_vars mom_set_visc::remap_vertvisc_aux_vars->mom_ale::ale_remap_interface_vals mom_set_visc::remap_vertvisc_aux_vars->mom_ale::ale_remap_vertex_vals
Text view
Callers call graph
Callers of mom_set_visc::remap_vertvisc_aux_vars calls cluster_mom MOM cluster_mom_set_visc MOM_set_visc mom::ale_regridding_and_remapping ALE_regridding_and_remapping [private/internal] mom_set_visc::remap_vertvisc_aux_vars remap_vertvisc_aux_vars mom::ale_regridding_and_remapping->mom_set_visc::remap_vertvisc_aux_vars
Text view
subroutine set_visc_init(Time, G, GV, US, param_file, diag, visc, CS, restart_CS, OBC)

Initializes the MOM_set_visc control structure

Parameters
  • Time [in]

    The current model time.

  • G [inout]

    The ocean's grid structure.

  • GV [in]

    The ocean's vertical grid structure.

  • US [in]

    A dimensional unit scaling type

  • param_file [in]

    A structure to parse for run-time parameters.

  • diag [inout]

    A structure that is used to regulate diagnostic output.

  • visc [inout]

    A structure containing vertical viscosities and related fields.

  • CS [inout]

    Vertical viscosity control structure

  • restart_CS [inout]

    MOM restart control structure

  • OBC

    A pointer to an open boundary condition structure

  • cdrag_h

    The spatially varying quadratic drag coefficient [nondim]

Callees call graph
Callees of mom_set_visc::set_visc_init calls cluster_mom_diag_mediator MOM_diag_mediator cluster_mom_domain_infra MOM_domain_infra cluster_mom_error_handler MOM_error_handler cluster_mom_file_parser MOM_file_parser cluster_mom_io MOM_io cluster_mom_kappa_shear MOM_kappa_shear cluster_mom_restart MOM_restart cluster_mom_set_visc MOM_set_visc cluster_mom_string_functions MOM_string_functions mom_diag_mediator::register_diag_field register_diag_field mom_domain_infra::interface::pass_var pass_var (interface) mom_error_handler::mom_error MOM_error mom_file_parser::interface::get_param get_param (interface) mom_file_parser::interface::log_param log_param (interface) mom_file_parser::interface::log_version log_version (interface) mom_io::interface::mom_read_data MOM_read_data (interface) mom_kappa_shear::kappa_shear_at_vertex kappa_shear_at_vertex mom_kappa_shear::kappa_shear_is_used kappa_shear_is_used mom_restart::register_restart_field_as_obsolete register_restart_field_as_obsolete mom_set_visc::set_visc_init set_visc_init mom_set_visc::set_visc_init->mom_diag_mediator::register_diag_field mom_set_visc::set_visc_init->mom_domain_infra::interface::pass_var mom_set_visc::set_visc_init->mom_error_handler::mom_error mom_set_visc::set_visc_init->mom_file_parser::interface::get_param mom_set_visc::set_visc_init->mom_file_parser::interface::log_param mom_set_visc::set_visc_init->mom_file_parser::interface::log_version mom_set_visc::set_visc_init->mom_io::interface::mom_read_data mom_set_visc::set_visc_init->mom_kappa_shear::kappa_shear_at_vertex mom_set_visc::set_visc_init->mom_kappa_shear::kappa_shear_is_used mom_set_visc::set_visc_init->mom_restart::register_restart_field_as_obsolete mom_string_functions::slasher slasher mom_set_visc::set_visc_init->mom_string_functions::slasher
Text view
Callers call graph
Callers of mom_set_visc::set_visc_init calls cluster_mom MOM cluster_mom_set_visc MOM_set_visc mom::initialize_mom initialize_MOM mom_set_visc::set_visc_init set_visc_init mom::initialize_mom->mom_set_visc::set_visc_init
Text view
subroutine set_visc_end(visc, CS)

This subroutine dellocates any memory in the set_visc control structure.

Parameters
  • visc [inout]

    A structure containing vertical viscosities and related fields. Elements are deallocated here.

  • CS [inout]

    The control structure returned by a previous call to set_visc_init.

Callers call graph
Callers of mom_set_visc::set_visc_end calls cluster_mom MOM cluster_mom_set_visc MOM_set_visc mom::mom_end MOM_end mom_set_visc::set_visc_end set_visc_end mom::mom_end->mom_set_visc::set_visc_end
Text view
API generated with Flint · Rendered from reStructuredText