mom_cvmix_shear module reference

Interface to CVMix interior shear schemes.

More…

Data Types

cvmix_shear_cs

Control structure including parameters for CVMix interior shear schemes.

Functions/Subroutines

calculate_cvmix_shear()

Subroutine for calculating (internal) vertical diffusivities/viscosities.

cvmix_shear_init()

Initialized the CVMix internal shear mixing routine.

cvmix_shear_is_used()

Reads the parameters “LMD94” and “PP81” and returns state.

cvmix_shear_end()

Clear pointers and dealocate memory.

Detailed Description

Interface to CVMix interior shear schemes.

Type Documentation

type mom_cvmix_shear/cvmix_shear_cs

Control structure including parameters for CVMix interior shear schemes.

Type fields
  • % id_n2 [integer] :: Diagnostic handles.

  • % id_s2 [integer] :: Diagnostic handles.

  • % id_ri_grad [integer] :: Diagnostic handles.

  • % id_kv [integer] :: Diagnostic handles.

  • % id_kd [integer] :: Diagnostic handles.

  • % id_ri_grad_smooth [integer] :: Diagnostic handles.

  • % use_lmd94 [logical] :: Flags to use the LMD94 scheme.

  • % use_pp81 [logical] :: Flags to use Pacanowski and Philander (JPO 1981)

  • % smooth_ri [logical] :: If true, smooth Ri using a 1-2-1 filter.

  • % ri_zero [real] :: LMD94 critical Richardson number.

  • % nu_zero [real] :: LMD94 maximum interior diffusivity.

  • % kpp_exp [real] :: Exponent of unitless factor of diff. for KPP internal shear mixing scheme.

  • % n2 [real(:,:,:),allocatable] :: Squared Brunt-Vaisala frequency [T-2 ~> s-2].

  • % s2 [real(:,:,:),allocatable] :: Squared shear frequency [T-2 ~> s-2].

  • % ri_grad [real(:,:,:),allocatable] :: Gradient Richardson number.

  • % ri_grad_smooth [real(:,:,:),allocatable] :: Gradient Richardson number after smoothing.

  • % mix_scheme [character (10)] :: Mixing scheme name (string)

  • % diag [type(diag_ctrl),pointer] :: Pointer to the diagnostics control structure.

Function/Subroutine Documentation

subroutine mom_cvmix_shear/calculate_cvmix_shear(u_H, v_H, h, tv, kd, kv, G, GV, US, CS)

Subroutine for calculating (internal) vertical diffusivities/viscosities.

Parameters
  • g :: [in] Grid structure.

  • gv :: [in] Vertical grid structure.

  • us :: [in] A dimensional unit scaling type

  • u_h :: [in] Initial zonal velocity on T points [L T-1 ~> m s-1]

  • v_h :: [in] Initial meridional velocity on T points [L T-1 ~> m s-1]

  • h :: [in] Layer thickness [H ~> m or kg m-2].

  • tv :: [in] Thermodynamics structure.

  • kd :: [out] The vertical diffusivity at each interface (not layer!) [Z2 T-1 ~> m2 s-1].

  • kv :: [out] The vertical viscosity at each interface (not layer!) [Z2 T-1 ~> m2 s-1].

  • cs :: The control structure returned by a previous call to CVMix_shear_init.

function mom_cvmix_shear/cvmix_shear_init(Time, G, GV, US, param_file, diag, CS) [logical]

Initialized the CVMix internal shear mixing routine.

Todo

Does this note require emphasis?

Parameters
  • time :: [in] The current time.

  • g :: [in] Grid structure.

  • gv :: [in] Vertical grid structure.

  • us :: [in] A dimensional unit scaling type

  • param_file :: [in] Run-time parameter file handle

  • diag :: [inout] Diagnostics control structure.

  • cs :: This module’s control structure.

Call to

mom_kappa_shear::kappa_shear_is_used mdl mom_error_handler::mom_error

function mom_cvmix_shear/cvmix_shear_is_used(param_file) [logical]

Reads the parameters “LMD94” and “PP81” and returns state. This function allows other modules to know whether this parameterization will be used without needing to duplicate the log entry.

Parameters

param_file :: [in] Run-time parameter files handle.

Call to

mdl

Called from

mom_diabatic_driver::diabatic_driver_init mom_set_visc::set_visc_register_restarts

subroutine mom_cvmix_shear/cvmix_shear_end(CS)

Clear pointers and dealocate memory.

Parameters

cs :: [inout] Control structure for this module that will be deallocated in this subroutine

Called from

mom_set_diffusivity::set_diffusivity_end