diff --git a/config_src/ice_solo_driver/user_surface_forcing.F90 b/config_src/ice_solo_driver/user_surface_forcing.F90 index 41694af97c..bbfa4560fb 100644 --- a/config_src/ice_solo_driver/user_surface_forcing.F90 +++ b/config_src/ice_solo_driver/user_surface_forcing.F90 @@ -83,7 +83,7 @@ module user_surface_forcing real :: G_Earth ! The gravitational acceleration [m s-2]. real :: Flux_const ! The restoring rate at the surface [m s-1]. real :: gust_const ! A constant unresolved background gustiness - ! that contributes to ustar, in Pa. + ! that contributes to ustar [Pa]. type(diag_ctrl), pointer :: diag ! A structure that is used to regulate the ! timing of diagnostic output. @@ -126,7 +126,7 @@ subroutine USER_wind_forcing(sfc_state, forces, day, G, US, CS) ! Allocate the forcing arrays, if necessary. call allocate_mech_forcing(G, forces, stress=.true., ustar=.true.) - ! Set the surface wind stresses, in units of Pa. A positive taux + ! Set the surface wind stresses [Pa]. A positive taux ! accelerates the ocean to the (pseudo-)east. ! The i-loop extends to is-1 so that taux can be used later in the @@ -138,8 +138,7 @@ subroutine USER_wind_forcing(sfc_state, forces, day, G, US, CS) forces%tauy(i,J) = G%mask2dCv(i,J) * 0.0 ! Change this to the desired expression. enddo ; enddo - ! Set the surface friction velocity, in units of m s-1. ustar - ! is always positive. + ! Set the surface friction velocity [Z s-1 ~> m s-1]. ustar is always positive. if (associated(forces%ustar)) then ; do j=js,je ; do i=is,ie ! This expression can be changed if desired, but need not be. forces%ustar(i,j) = US%m_to_Z * G%mask2dT(i,j) * sqrt(CS%gust_const/CS%Rho0 + & @@ -177,8 +176,8 @@ subroutine USER_buoyancy_forcing(sfc_state, fluxes, day, dt, G, CS) ! are in W m-2 and positive for heat going into the ocean. All fresh water ! fluxes are in kg m-2 s-1 and positive for water moving into the ocean. - real :: Temp_restore ! The temperature that is being restored toward, in C. - real :: Salin_restore ! The salinity that is being restored toward, in PSU. + real :: Temp_restore ! The temperature that is being restored toward [C]. + real :: Salin_restore ! The salinity that is being restored toward [ppt] real :: density_restore ! The potential density that is being restored ! toward [kg m-3]. real :: rhoXcp ! The mean density times the heat capacity [J m-3 degC-1]. diff --git a/config_src/solo_driver/MESO_surface_forcing.F90 b/config_src/solo_driver/MESO_surface_forcing.F90 index e6f35274bf..a676b35bc0 100644 --- a/config_src/solo_driver/MESO_surface_forcing.F90 +++ b/config_src/solo_driver/MESO_surface_forcing.F90 @@ -30,14 +30,14 @@ module MESO_surface_forcing real :: G_Earth !< The gravitational acceleration [m s-2]. real :: Flux_const !< The restoring rate at the surface [m s-1]. real :: gust_const !< A constant unresolved background gustiness - !! that contributes to ustar, in Pa. + !! that contributes to ustar [Pa]. real, dimension(:,:), pointer :: & - T_Restore(:,:) => NULL(), & !< The temperature to restore the SST toward, in C. - S_Restore(:,:) => NULL(), & !< The salinity to restore the sea surface salnity toward, in PSU. - PmE(:,:) => NULL(), & !< The prescribed precip minus evap, in m s-1. - Solar(:,:) => NULL() !< The shortwave forcing into the ocean, in W m-2 m s-1. + T_Restore(:,:) => NULL(), & !< The temperature to restore the SST toward [degC]. + S_Restore(:,:) => NULL(), & !< The salinity to restore the sea surface salnity toward [ppt] + PmE(:,:) => NULL(), & !< The prescribed precip minus evap [m s-1]. + Solar(:,:) => NULL() !< The shortwave forcing into the ocean [W m-2]. real, dimension(:,:), pointer :: Heat(:,:) => NULL() !< The prescribed longwave, latent and sensible - !! heat flux into the ocean, in W m-2. + !! heat flux into the ocean [W m-2]. character(len=200) :: inputdir !< The directory where NetCDF input files are. character(len=200) :: salinityrestore_file !< The file with the target sea surface salinity character(len=200) :: SSTrestore_file !< The file with the target sea surface temperature @@ -76,7 +76,7 @@ subroutine MESO_buoyancy_forcing(sfc_state, fluxes, day, dt, G, CS) ! fluxes are in kg m-2 s-1 and positive for water moving into the ocean. real :: Temp_restore ! The temperature that is being restored toward [degC]. - real :: Salin_restore ! The salinity that is being restored toward, in PSU. + real :: Salin_restore ! The salinity that is being restored toward [ppt] real :: density_restore ! The potential density that is being restored ! toward [kg m-3]. real :: rhoXcp ! The mean density times the heat capacity [J m-3 degC-1]. diff --git a/config_src/solo_driver/MOM_surface_forcing.F90 b/config_src/solo_driver/MOM_surface_forcing.F90 index ed990dbbaa..529b5087f4 100644 --- a/config_src/solo_driver/MOM_surface_forcing.F90 +++ b/config_src/solo_driver/MOM_surface_forcing.F90 @@ -78,32 +78,32 @@ module MOM_surface_forcing real :: south_lat !< southern latitude of the domain real :: len_lat !< domain length in latitude - real :: Rho0 !< Boussinesq reference density (kg/m^3) - real :: G_Earth !< gravitational acceleration (m/s^2) + real :: Rho0 !< Boussinesq reference density [kg m-3] + real :: G_Earth !< gravitational acceleration [m s-2] real :: Flux_const !< piston velocity for surface restoring [m s-1] real :: Flux_const_T !< piston velocity for surface temperature restoring [m s-1] real :: Flux_const_S !< piston velocity for surface salinity restoring [m s-1] - real :: latent_heat_fusion !< latent heat of fusion (J/kg) - real :: latent_heat_vapor !< latent heat of vaporization (J/kg) + real :: latent_heat_fusion !< latent heat of fusion [J kg] + real :: latent_heat_vapor !< latent heat of vaporization [J kg] real :: tau_x0 !< Constant zonal wind stress used in the WIND_CONFIG="const" forcing real :: tau_y0 !< Constant meridional wind stress used in the WIND_CONFIG="const" forcing - real :: gust_const !< constant unresolved background gustiness for ustar (Pa) + real :: gust_const !< constant unresolved background gustiness for ustar [Pa] logical :: read_gust_2d !< if true, use 2-dimensional gustiness supplied from a file - real, pointer :: gust(:,:) => NULL() !< spatially varying unresolved background gustiness (Pa) + real, pointer :: gust(:,:) => NULL() !< spatially varying unresolved background gustiness [Pa] !! gust is used when read_gust_2d is true. - real, pointer :: T_Restore(:,:) => NULL() !< temperature to damp (restore) the SST to (deg C) - real, pointer :: S_Restore(:,:) => NULL() !< salinity to damp (restore) the SSS (g/kg) - real, pointer :: Dens_Restore(:,:) => NULL() !< density to damp (restore) surface density (kg/m^3) + real, pointer :: T_Restore(:,:) => NULL() !< temperature to damp (restore) the SST to [degC] + real, pointer :: S_Restore(:,:) => NULL() !< salinity to damp (restore) the SSS [ppt] + real, pointer :: Dens_Restore(:,:) => NULL() !< density to damp (restore) surface density [kg m-3] integer :: buoy_last_lev_read = -1 !< The last time level read from buoyancy input files ! if WIND_CONFIG=='gyres' then use the following as = A, B, C and n respectively for ! taux = A + B*sin(n*pi*y/L) + C*cos(n*pi*y/L) - real :: gyres_taux_const !< A constant wind stress, in Pa. - real :: gyres_taux_sin_amp !< The amplitude of cosine wind stress gyres, in Pa, if WIND_CONFIG=='gyres'. - real :: gyres_taux_cos_amp !< The amplitude of cosine wind stress gyres, in Pa, if WIND_CONFIG=='gyres'. + real :: gyres_taux_const !< A constant wind stress [Pa]. + real :: gyres_taux_sin_amp !< The amplitude of cosine wind stress gyres [Pa], if WIND_CONFIG=='gyres'. + real :: gyres_taux_cos_amp !< The amplitude of cosine wind stress gyres [Pa], if WIND_CONFIG=='gyres'. real :: gyres_taux_n_pis !< The number of sine lobes in the basin if if WIND_CONFIG=='gyres' @@ -360,8 +360,8 @@ subroutine wind_forcing_const(sfc_state, forces, tau_x0, tau_y0, day, G, US, CS) type(surface), intent(inout) :: sfc_state !< A structure containing fields that !! describe the surface state of the ocean. type(mech_forcing), intent(inout) :: forces !< A structure with the driving mechanical forces - real, intent(in) :: tau_x0 !< The zonal wind stress in Pa - real, intent(in) :: tau_y0 !< The meridional wind stress in Pa + real, intent(in) :: tau_x0 !< The zonal wind stress [Pa] + real, intent(in) :: tau_y0 !< The meridional wind stress [Pa] type(time_type), intent(in) :: day !< The time of the fluxes type(ocean_grid_type), intent(in) :: G !< The ocean's grid structure type(unit_scale_type), intent(in) :: US !< A dimensional unit scaling type @@ -484,7 +484,7 @@ subroutine wind_forcing_gyres(sfc_state, forces, day, G, US, CS) is = G%isc ; ie = G%iec ; js = G%jsc ; je = G%jec Isq = G%IscB ; Ieq = G%IecB ; Jsq = G%JscB ; Jeq = G%JecB - ! steady surface wind stresses (Pa) + ! steady surface wind stresses [Pa] PI = 4.0*atan(1.0) do j=js-1,je+1 ; do I=is-1,Ieq @@ -522,7 +522,7 @@ subroutine wind_forcing_from_file(sfc_state, forces, day, G, US, CS) ! Local variables character(len=200) :: filename ! The name of the input file. real :: temp_x(SZI_(G),SZJ_(G)) ! Pseudo-zonal and psuedo-meridional - real :: temp_y(SZI_(G),SZJ_(G)) ! wind stresses at h-points, in Pa. + real :: temp_y(SZI_(G),SZJ_(G)) ! wind stresses at h-points [Pa]. integer :: time_lev_daily ! The time levels to read for fields with integer :: time_lev_monthly ! daily and montly cycles. integer :: time_lev ! The time level that is used for a field. @@ -671,7 +671,7 @@ subroutine wind_forcing_by_data_override(sfc_state, forces, day, G, US, CS) !! a previous surface_forcing_init call ! Local variables real :: temp_x(SZI_(G),SZJ_(G)) ! Pseudo-zonal and psuedo-meridional - real :: temp_y(SZI_(G),SZJ_(G)) ! wind stresses at h-points, in Pa. + real :: temp_y(SZI_(G),SZJ_(G)) ! wind stresses at h-points [Pa]. real :: temp_ustar(SZI_(G),SZJ_(G)) ! ustar [m s-1] (not rescaled). integer :: i, j, is_in, ie_in, js_in, je_in logical :: read_uStar @@ -743,15 +743,15 @@ subroutine buoyancy_forcing_from_files(sfc_state, fluxes, day, dt, G, CS) real, dimension(SZI_(G),SZJ_(G)) :: & temp, & ! A 2-d temporary work array with various units. SST_anom, & ! Instantaneous sea surface temperature anomalies from a - ! target (observed) value, in deg C. + ! target (observed) value [degC]. SSS_anom, & ! Instantaneous sea surface salinity anomalies from a target - ! (observed) value, in g kg-1. + ! (observed) value [ppt]. SSS_mean ! A (mean?) salinity about which to normalize local salinity ! anomalies when calculating restorative precipitation - ! anomalies, in g kg-1. + ! anomalies [ppt]. - real :: rhoXcp ! reference density times heat capacity (J/(m^3 * K)) - real :: Irho0 ! inverse of the Boussinesq reference density (m^3/kg) + real :: rhoXcp ! reference density times heat capacity [J m-3 degC-1] + real :: Irho0 ! inverse of the Boussinesq reference density [m3 kg-1] integer :: time_lev_daily ! time levels to read for fields with daily cycle integer :: time_lev_monthly ! time levels to read for fields with monthly cycle @@ -1021,14 +1021,14 @@ subroutine buoyancy_forcing_from_data_override(sfc_state, fluxes, day, dt, G, CS real, dimension(SZI_(G),SZJ_(G)) :: & temp, & ! A 2-d temporary work array with various units. SST_anom, & ! Instantaneous sea surface temperature anomalies from a - ! target (observed) value, in deg C. + ! target (observed) value [degC]. SSS_anom, & ! Instantaneous sea surface salinity anomalies from a target - ! (observed) value, in g kg-1. + ! (observed) value [ppt]. SSS_mean ! A (mean?) salinity about which to normalize local salinity ! anomalies when calculating restorative precipitation - ! anomalies, in g kg-1. - real :: rhoXcp ! The mean density times the heat capacity, in J m-3 K-1. - real :: Irho0 ! The inverse of the Boussinesq density, in m3 kg-1. + ! anomalies [ppt]. + real :: rhoXcp ! The mean density times the heat capacity [J m-3 degC-1]. + real :: Irho0 ! The inverse of the Boussinesq density [m3 kg-1]. integer :: time_lev_daily ! The time levels to read for fields with integer :: time_lev_monthly ! daily and montly cycles. diff --git a/config_src/solo_driver/user_surface_forcing.F90 b/config_src/solo_driver/user_surface_forcing.F90 index 4472ea9a76..92d07c774a 100644 --- a/config_src/solo_driver/user_surface_forcing.F90 +++ b/config_src/solo_driver/user_surface_forcing.F90 @@ -37,7 +37,7 @@ module user_surface_forcing real :: G_Earth !< The gravitational acceleration [m s-2]. real :: Flux_const !< The restoring rate at the surface [m s-1]. real :: gust_const !< A constant unresolved background gustiness - !! that contributes to ustar, in Pa. + !! that contributes to ustar [Pa]. type(diag_ctrl), pointer :: diag !< A structure that is used to regulate the !! timing of diagnostic output. @@ -125,7 +125,7 @@ subroutine USER_buoyancy_forcing(sfc_state, fluxes, day, dt, G, CS) ! Local variables real :: Temp_restore ! The temperature that is being restored toward [degC]. - real :: Salin_restore ! The salinity that is being restored toward, in PSU. + real :: Salin_restore ! The salinity that is being restored toward [ppt] real :: density_restore ! The potential density that is being restored ! toward [kg m-3]. real :: rhoXcp ! The mean density times the heat capacity [J m-3 degC-1]. diff --git a/src/core/MOM_PressureForce_analytic_FV.F90 b/src/core/MOM_PressureForce_analytic_FV.F90 index 1b380ac334..044aef35a4 100644 --- a/src/core/MOM_PressureForce_analytic_FV.F90 +++ b/src/core/MOM_PressureForce_analytic_FV.F90 @@ -162,14 +162,14 @@ subroutine PressureForce_AFV_nonBouss(h, tv, PFu, PFv, G, GV, US, CS, ALE_CSp, p real :: g_Earth_z ! A scaled version of g_Earth [m2 Z-1 s-2 ~> m s-2]. real :: I_gEarth ! The inverse of g_Earth_z [s2 Z m-2 ~> s2 m-1] real :: alpha_anom ! The in-situ specific volume, averaged over a - ! layer, less alpha_ref, in m3 kg-1. + ! layer, less alpha_ref [m3 kg-1]. logical :: use_p_atm ! If true, use the atmospheric pressure. logical :: use_ALE ! If true, use an ALE pressure reconstruction. logical :: use_EOS ! If true, density is calculated from T & S using an ! equation of state. type(thermo_var_ptrs) :: tv_tmp! A structure of temporary T & S. - real :: alpha_ref ! A reference specific volume, in m3 kg-1, that is used + real :: alpha_ref ! A reference specific volume [m3 kg-1], that is used ! to reduce the impact of truncation errors. real :: rho_in_situ(SZI_(G)) ! The in situ density [kg m-3]. real :: Pa_to_H ! A factor to convert from Pa to the thicknesss units (H). diff --git a/src/core/MOM_checksum_packages.F90 b/src/core/MOM_checksum_packages.F90 index 0984185c34..a71f4bab48 100644 --- a/src/core/MOM_checksum_packages.F90 +++ b/src/core/MOM_checksum_packages.F90 @@ -50,9 +50,11 @@ subroutine MOM_state_chksum_5arg(mesg, u, v, h, uh, vh, G, GV, haloshift, symmet real, dimension(SZI_(G),SZJ_(G),SZK_(G)), & intent(in) :: h !< Layer thicknesses [H ~> m or kg m-2]. real, dimension(SZIB_(G),SZJ_(G),SZK_(G)), & - intent(in) :: uh !< Volume flux through zonal faces = u*h*dy, m3 s-1. + intent(in) :: uh !< Volume flux through zonal faces = u*h*dy + !! [H m2 s-1 ~> m3 s-1 or kg s-1]. real, dimension(SZI_(G),SZJB_(G),SZK_(G)), & - intent(in) :: vh !< Volume flux through meridional faces = v*h*dx, in m3 s-1. + intent(in) :: vh !< Volume flux through meridional faces = v*h*dx + !! [H m2 s-1 ~> m3 s-1 or kg s-1]. integer, optional, intent(in) :: haloshift !< The width of halos to check (default 0). logical, optional, intent(in) :: symmetric !< If true, do checksums on the fully symmetric !! computationoal domain. @@ -185,10 +187,10 @@ subroutine MOM_accel_chksum(mesg, CAu, CAv, PFu, PFv, diffu, diffv, G, GV, pbce, !! [m2 s-2 H-1 ~> m s-2 or m4 s-2 kg-1]. real, dimension(SZIB_(G),SZJ_(G),SZK_(G)), & optional, intent(in) :: u_accel_bt !< The zonal acceleration from terms in the - !! barotropic solver,in m s-2. + !! barotropic solver [m s-2]. real, dimension(SZI_(G),SZJB_(G),SZK_(G)), & optional, intent(in) :: v_accel_bt !< The meridional acceleration from terms in - !! the barotropic solver,in m s-2. + !! the barotropic solver [m s-2]. logical, optional, intent(in) :: symmetric !< If true, do checksums on the fully symmetric !! computationoal domain. @@ -223,9 +225,9 @@ subroutine MOM_state_stats(mesg, u, v, h, Temp, Salt, G, allowChange, permitDimi real, dimension(SZI_(G),SZJ_(G),SZK_(G)), & intent(in) :: h !< Layer thicknesses [H ~> m or kg m-2]. real, pointer, dimension(:,:,:), & - intent(in) :: Temp !< Temperature in degree C. + intent(in) :: Temp !< Temperature [degC]. real, pointer, dimension(:,:,:), & - intent(in) :: Salt !< Salinity, in ppt. + intent(in) :: Salt !< Salinity [ppt]. logical, optional, intent(in) :: allowChange !< do not flag an error !! if the statistics change. logical, optional, intent(in) :: permitDiminishing !< do not flag error diff --git a/src/core/MOM_continuity.F90 b/src/core/MOM_continuity.F90 index f2efa147f2..66ec869e0c 100644 --- a/src/core/MOM_continuity.F90 +++ b/src/core/MOM_continuity.F90 @@ -53,18 +53,18 @@ subroutine continuity(u, v, hin, h, uh, vh, dt, G, GV, CS, uhbt, vhbt, OBC, & intent(inout) :: h !< Final layer thickness [H ~> m or kg m-2]. real, dimension(SZIB_(G),SZJ_(G),SZK_(G)), & intent(out) :: uh !< Volume flux through zonal faces = - !! u*h*dy, in m3/s. + !! u*h*dy [H m2 s-1 ~> m3 s-1 or kg s-1]. real, dimension(SZI_(G),SZJB_(G),SZK_(G)), & intent(out) :: vh !< Volume flux through meridional faces = - !! v*h*dx, in m3/s. + !! v*h*dx [H m2 s-1 ~> m3 s-1 or kg s-1]. real, intent(in) :: dt !< Time increment [s]. type(continuity_CS), pointer :: CS !< Control structure for mom_continuity. real, dimension(SZIB_(G),SZJ_(G)), & optional, intent(in) :: uhbt !< The vertically summed volume - !! flux through zonal faces, in m3/s. + !! flux through zonal faces [H m2 s-1 ~> m3 s-1 or kg s-1]. real, dimension(SZI_(G),SZJB_(G)), & optional, intent(in) :: vhbt !< The vertically summed volume - !! flux through meridional faces, in m3/s. + !! flux through meridional faces [H m2 s-1 ~> m3 s-1 or kg s-1]. type(ocean_OBC_type), & optional, pointer :: OBC !< Open boundaries control structure. real, dimension(SZIB_(G),SZJ_(G),SZK_(G)), & diff --git a/src/core/MOM_isopycnal_slopes.F90 b/src/core/MOM_isopycnal_slopes.F90 index 03f89f7061..e5e2045c7a 100644 --- a/src/core/MOM_isopycnal_slopes.F90 +++ b/src/core/MOM_isopycnal_slopes.F90 @@ -49,12 +49,11 @@ subroutine calc_isoneutral_slopes(G, GV, US, h, e, tv, dt_kappa_smooth, & ! (This argument has been tested but for now serves no purpose.) !! of eta to m; US%Z_to_m by default. ! Local variables real, dimension(SZI_(G), SZJ_(G), SZK_(G)) :: & - T, & ! The temperature (or density) in C, with the values in + T, & ! The temperature [degC], with the values in ! in massless layers filled vertically by diffusion. - S, & ! The filled salinity, in PSU, with the values in + S, & ! The filled salinity [PSU], with the values in ! in massless layers filled vertically by diffusion. - Rho ! Density itself, when a nonlinear equation of state is - ! not in use. + Rho ! Density itself, when a nonlinear equation of state is not in use [kg m-3]. real, dimension(SZI_(G), SZJ_(G), SZK_(G)+1) :: & pres ! The pressure at an interface [Pa]. real, dimension(SZIB_(G)) :: & diff --git a/src/diagnostics/MOM_sum_output.F90 b/src/diagnostics/MOM_sum_output.F90 index 7ae94450df..3f3da7296c 100644 --- a/src/diagnostics/MOM_sum_output.F90 +++ b/src/diagnostics/MOM_sum_output.F90 @@ -43,9 +43,9 @@ module MOM_sum_output !> A list of depths and corresponding globally integrated ocean area at each !! depth and the ocean volume below each depth. type :: Depth_List - real :: depth !< A depth, in m. - real :: area !< The cross-sectional area of the ocean at that depth, in m2. - real :: vol_below !< The ocean volume below that depth, in m3. + real :: depth !< A depth [m]. + real :: area !< The cross-sectional area of the ocean at that depth [m2]. + real :: vol_below !< The ocean volume below that depth [m3]. end type Depth_List !> The control structure for the MOM_sum_output module @@ -66,17 +66,17 @@ module MOM_sum_output !! entries in the depth-list file, 0 by default. logical :: use_temperature !< If true, temperature and salinity are state variables. real :: fresh_water_input !< The total mass of fresh water added by surface fluxes - !! since the last time that write_energy was called, in kg. + !! since the last time that write_energy was called [kg]. real :: mass_prev !< The total ocean mass the last time that - !! write_energy was called, in kg. + !! write_energy was called [kg]. real :: salt_prev !< The total amount of salt in the ocean the last - !! time that write_energy was called, in PSU kg. + !! time that write_energy was called [ppt kg]. real :: net_salt_input !< The total salt added by surface fluxes since the last - !! time that write_energy was called, in PSU kg. + !! time that write_energy was called [ppt kg]. real :: heat_prev !< The total amount of heat in the ocean the last - !! time that write_energy was called, in Joules. + !! time that write_energy was called [J]. real :: net_heat_input !< The total heat added by surface fluxes since the last - !! the last time that write_energy was called, in Joules. + !! the last time that write_energy was called [J]. type(EFP_type) :: fresh_water_in_EFP !< An extended fixed point version of fresh_water_input type(EFP_type) :: net_salt_in_EFP !< An extended fixed point version of net_salt_input type(EFP_type) :: net_heat_in_EFP !< An extended fixed point version of net_heat_input @@ -136,8 +136,9 @@ subroutine MOM_sum_output_init(G, US, param_file, directory, ntrnc, & type(Sum_output_CS), pointer :: CS !< A pointer that is set to point to the !! control structure for this module. ! Local variables - real :: Time_unit ! The time unit in seconds for ENERGYSAVEDAYS. - real :: Rho_0, maxvel + real :: Time_unit ! The time unit in seconds for ENERGYSAVEDAYS. + real :: Rho_0 ! A reference density [kg m-3] + real :: maxvel ! The maximum permitted velocity [m s-1] ! This include declares and sets the variable "version". #include "version_variable.h" character(len=40) :: mdl = "MOM_sum_output" ! This module's name. @@ -297,43 +298,43 @@ subroutine write_energy(u, v, h, tv, day, n, G, GV, US, CS, tracer_CSp, OBC, dt_ type(time_type), optional, intent(in) :: dt_forcing !< The forcing time step ! Local variables real :: eta(SZI_(G),SZJ_(G),SZK_(G)+1) ! The height of interfaces [Z ~> m]. - real :: areaTm(SZI_(G),SZJ_(G)) ! A masked version of areaT, in m2. - real :: KE(SZK_(G)) ! The total kinetic energy of a layer, in J. - real :: PE(SZK_(G)+1)! The available potential energy of an interface, in J. - real :: KE_tot ! The total kinetic energy, in J. - real :: PE_tot ! The total available potential energy, in J. + real :: areaTm(SZI_(G),SZJ_(G)) ! A masked version of areaT [m2]. + real :: KE(SZK_(G)) ! The total kinetic energy of a layer [J]. + real :: PE(SZK_(G)+1)! The available potential energy of an interface [J]. + real :: KE_tot ! The total kinetic energy [J]. + real :: PE_tot ! The total available potential energy [J]. real :: Z_0APE(SZK_(G)+1) ! The uniform depth which overlies the same ! volume as is below an interface [Z ~> m]. real :: H_0APE(SZK_(G)+1) ! A version of Z_0APE, converted to m, usually positive. real :: toten ! The total kinetic & potential energies of - ! all layers, in Joules (i.e. kg m2 s-2). + ! all layers [J] (i.e. kg m2 s-2). real :: En_mass ! The total kinetic and potential energies divided by ! the total mass of the ocean [m2 s-2]. real :: vol_lay(SZK_(G)) ! The volume of fluid in a layer [Z m2 ~> m3]. real :: volbelow ! The volume of all layers beneath an interface [Z m2 ~> m3]. - real :: mass_lay(SZK_(G)) ! The mass of fluid in a layer, in kg. - real :: mass_tot ! The total mass of the ocean in kg. - real :: vol_tot ! The total ocean volume in m3. + real :: mass_lay(SZK_(G)) ! The mass of fluid in a layer [kg]. + real :: mass_tot ! The total mass of the ocean [kg]. + real :: vol_tot ! The total ocean volume [m3]. real :: mass_chg ! The change in total ocean mass of fresh water since - ! the last call to this subroutine, in kg. + ! the last call to this subroutine [kg]. real :: mass_anom ! The change in fresh water that cannot be accounted for - ! by the surface fluxes, in kg. - real :: Salt ! The total amount of salt in the ocean, in PSU kg. + ! by the surface fluxes [kg]. + real :: Salt ! The total amount of salt in the ocean [ppt kg]. real :: Salt_chg ! The change in total ocean salt since the last call - ! to this subroutine, in PSU kg. + ! to this subroutine [ppt kg]. real :: Salt_anom ! The change in salt that cannot be accounted for by - ! the surface fluxes, in PSU kg. - real :: salin ! The mean salinity of the ocean [PSU]. + ! the surface fluxes [ppt kg]. + real :: salin ! The mean salinity of the ocean [ppt]. real :: salin_chg ! The change in total salt since the last call - ! to this subroutine divided by total mass [PSU]. + ! to this subroutine divided by total mass [ppt]. real :: salin_anom ! The change in total salt that cannot be accounted for by - ! the surface fluxes divided by total mass in PSU. - real :: salin_mass_in ! The mass of salt input since the last call, kg. - real :: Heat ! The total amount of Heat in the ocean, in Joules. + ! the surface fluxes divided by total mass [ppt]. + real :: salin_mass_in ! The mass of salt input since the last call [kg]. + real :: Heat ! The total amount of Heat in the ocean [J]. real :: Heat_chg ! The change in total ocean heat since the last call - ! to this subroutine, in Joules. + ! to this subroutine [J]. real :: Heat_anom ! The change in heat that cannot be accounted for by - ! the surface fluxes, in Joules. + ! the surface fluxes [J]. real :: temp ! The mean potential temperature of the ocean [degC]. real :: temp_chg ! The change in total heat divided by total heat capacity ! of the ocean since the last call to this subroutine, degC. @@ -352,13 +353,13 @@ subroutine write_energy(u, v, h, tv, day, n, G, GV, US, CS, tracer_CSp, OBC, dt_ real :: CFL_trans ! A transport-based definition of the CFL number [nondim]. real :: CFL_lin ! A simpler definition of the CFL number [nondim]. real :: max_CFL(2) ! The maxima of the CFL numbers [nondim]. - real :: Irho0 ! The inverse of the reference density, in m3 kg-1. + real :: Irho0 ! The inverse of the reference density [m3 kg-1]. real, dimension(SZI_(G),SZJ_(G),SZK_(G)) :: & tmp1 ! A temporary array real, dimension(SZI_(G),SZJ_(G),SZK_(G)+1) :: & - PE_pt ! The potential energy at each point, in J. + PE_pt ! The potential energy at each point [J]. real, dimension(SZI_(G),SZJ_(G)) :: & - Temp_int, Salt_int ! Layer and cell integrated heat and salt, in J and g Salt. + Temp_int, Salt_int ! Layer and cell integrated heat and salt [J] and [g Salt]. real :: H_to_kg_m2 ! Local copy of a unit conversion factor. integer :: num_nc_fields ! The number of fields that will actually go into ! the NetCDF file. @@ -917,23 +918,23 @@ subroutine accumulate_net_input(fluxes, sfc_state, dt, G, CS) !! to MOM_sum_output_init. ! Local variables real, dimension(SZI_(G),SZJ_(G)) :: & - FW_in, & ! The net fresh water input, integrated over a timestep in kg. + FW_in, & ! The net fresh water input, integrated over a timestep [kg]. salt_in, & ! The total salt added by surface fluxes, integrated - ! over a time step in ppt*kg. + ! over a time step [ppt kg]. heat_in ! The total heat added by surface fluxes, integrated - ! over a time step in Joules. + ! over a time step [J]. real :: FW_input ! The net fresh water input, integrated over a timestep - ! and summed over space, in kg. + ! and summed over space [kg]. real :: salt_input ! The total salt added by surface fluxes, integrated - ! over a time step and summed over space, in ppt * kg. + ! over a time step and summed over space [ppt kg]. real :: heat_input ! The total heat added by boundary fluxes, integrated - ! over a time step and summed over space, in Joules. - real :: C_p ! The heat capacity of seawater, in J K-1 kg-1. + ! over a time step and summed over space [J]. + real :: C_p ! The heat capacity of seawater [J degC-1 kg-1]. type(EFP_type) :: & - FW_in_EFP, & ! Extended fixed point versions of FW_input, salt_input, and - salt_in_EFP, & ! heat_input, in kg, ppt*kg, and Joules. - heat_in_EFP + FW_in_EFP, & ! Extended fixed point version of FW_input [kg] + salt_in_EFP, & ! Extended fixed point version of salt_input [ppt kg] + heat_in_EFP ! Extended fixed point version of heat_input [J] real :: inputs(3) ! A mixed array for combining the sums integer :: i, j, is, ie, js, je @@ -1066,13 +1067,13 @@ subroutine create_depth_list(G, CS) ! Local variables real, dimension(G%Domain%niglobal*G%Domain%njglobal + 1) :: & Dlist, & !< The global list of bottom depths [Z ~> m]. - AreaList !< The global list of cell areas, in m2. + AreaList !< The global list of cell areas [m2]. integer, dimension(G%Domain%niglobal*G%Domain%njglobal+1) :: & indx2 !< The position of an element in the original unsorted list. real :: Dnow !< The depth now being considered for sorting [Z ~> m]. real :: Dprev !< The most recent depth that was considered [Z ~> m]. real :: vol !< The running sum of open volume below a deptn [Z m2 ~> m3]. - real :: area !< The open area at the current depth, in m2. + real :: area !< The open area at the current depth [m2]. real :: D_list_prev !< The most recent depth added to the list [Z ~> m]. logical :: add_to_list !< This depth should be included as an entry on the list. diff --git a/src/equation_of_state/MOM_EOS_TEOS10.F90 b/src/equation_of_state/MOM_EOS_TEOS10.F90 index 7c148443a5..fc14d5f892 100644 --- a/src/equation_of_state/MOM_EOS_TEOS10.F90 +++ b/src/equation_of_state/MOM_EOS_TEOS10.F90 @@ -222,9 +222,9 @@ subroutine calculate_specvol_derivs_teos10(T, S, pressure, dSV_dT, dSV_dS, start real, intent(in), dimension(:) :: S !< Absolute salinity [g kg-1]. real, intent(in), dimension(:) :: pressure !< pressure [Pa]. real, intent(out), dimension(:) :: dSV_dT !< The partial derivative of specific volume with - !! conservative temperature, in m3 kg-1 K-1. + !! conservative temperature [m3 kg-1 degC-1]. real, intent(out), dimension(:) :: dSV_dS !< The partial derivative of specific volume with - !! absolute salinity, in m3 kg-1 / (g/kg). + !! absolute salinity [m3 kg-1 (g/kg)-1]. integer, intent(in) :: start !< The starting point in the arrays. integer, intent(in) :: npts !< The number of values to calculate. diff --git a/src/ice_shelf/MOM_ice_shelf.F90 b/src/ice_shelf/MOM_ice_shelf.F90 index 0b64f38d75..affbed728c 100644 --- a/src/ice_shelf/MOM_ice_shelf.F90 +++ b/src/ice_shelf/MOM_ice_shelf.F90 @@ -96,8 +96,8 @@ module MOM_ice_shelf real :: Cp_ice !< The heat capacity of fresh ice [J kg-1 degC-1]. real :: gamma_t !< The (fixed) turbulent exchange velocity in the !< 2-equation formulation [m s-1]. - real :: Salin_ice !< The salinity of shelf ice [PSU]. - real :: Temp_ice !< The core temperature of shelf ice, in degC. + real :: Salin_ice !< The salinity of shelf ice [ppt]. + real :: Temp_ice !< The core temperature of shelf ice [degC]. real :: kv_ice !< The viscosity of ice [m2 s-1]. real :: density_ice !< A typical density of ice [kg m-3]. real :: rho_ice !< Nominal ice density in kg m-2 Z-1 @@ -131,10 +131,10 @@ module MOM_ice_shelf !! but any difference will be negligible) logical :: calve_to_mask !< If true, calve any ice that passes outside of a masked area real :: min_thickness_simple_calve !< min. ice shelf thickness criteria for calving [Z ~> m]. - real :: T0 !< temperature at ocean surface in the restoring region, in degC - real :: S0 !< Salinity at ocean surface in the restoring region, in ppt. + real :: T0 !< temperature at ocean surface in the restoring region [degC] + real :: S0 !< Salinity at ocean surface in the restoring region [ppt]. real :: input_flux !< Ice volume flux at an upstream open boundary [m3 s-1]. - real :: input_thickness !< Ice thickness at an upstream open boundary, in m. + real :: input_thickness !< Ice thickness at an upstream open boundary [m]. type(time_type) :: Time !< The component's time. type(EOS_type), pointer :: eqn_of_state => NULL() !< Type that indicates the diff --git a/src/ice_shelf/MOM_ice_shelf_dynamics.F90 b/src/ice_shelf/MOM_ice_shelf_dynamics.F90 index c61d8acc36..4ffdc6d255 100644 --- a/src/ice_shelf/MOM_ice_shelf_dynamics.F90 +++ b/src/ice_shelf/MOM_ice_shelf_dynamics.F90 @@ -3621,7 +3621,7 @@ subroutine ice_shelf_advect_temp_x(CS, G, time_step, hmask, h0, h_after_uflux, f !! the zonal mass fluxes, in m. real, dimension(SZDI_(G),SZDJ_(G),4), & intent(inout) :: flux_enter !< The integrated temperature flux into - !! the cell through the 4 cell boundaries, in degC Z m2 + !! the cell through the 4 cell boundaries [degC Z m2 ~> degC m3] ! use will be made of ISS%hmask here - its value at the boundary will be zero, just like uncovered cells @@ -3853,7 +3853,7 @@ subroutine ice_shelf_advect_temp_y(CS, G, time_step, hmask, h_after_uflux, h_aft !! the meridional mass fluxes [Z ~> m]. real, dimension(SZDI_(G),SZDJ_(G),4), & intent(inout) :: flux_enter !< The integrated temperature flux into - !! the cell through the 4 cell boundaries, in degC Z m2 + !! the cell through the 4 cell boundaries [degC Z m2 ~> degC m3] ! use will be made of ISS%hmask here - its value at the boundary will be zero, just like uncovered cells diff --git a/src/parameterizations/vertical/MOM_diabatic_aux.F90 b/src/parameterizations/vertical/MOM_diabatic_aux.F90 index bd514c3a1d..811cc15592 100644 --- a/src/parameterizations/vertical/MOM_diabatic_aux.F90 +++ b/src/parameterizations/vertical/MOM_diabatic_aux.F90 @@ -102,12 +102,12 @@ subroutine make_frazil(h, tv, G, GV, CS, p_surf, halo) ! Local variables real, dimension(SZI_(G)) :: & - fraz_col, & ! The accumulated heat requirement due to frazil, in J. - T_freeze, & ! The freezing potential temperature at the current salinity, C. + fraz_col, & ! The accumulated heat requirement due to frazil [J]. + T_freeze, & ! The freezing potential temperature at the current salinity [degC]. ps ! pressure real, dimension(SZI_(G),SZK_(G)) :: & - pressure ! The pressure at the middle of each layer in Pa. - real :: hc ! A layer's heat capacity in J m-2 K-1. + pressure ! The pressure at the middle of each layer [Pa]. + real :: hc ! A layer's heat capacity [J m-2 degC-1]. logical :: T_fr_set ! True if the freezing point has been calculated for a ! row of points. integer :: i, j, k, is, ie, js, je, nz @@ -659,15 +659,15 @@ subroutine diagnoseMLDbyDensityDifference(id_MLD, h, tv, densityDiff, G, GV, US, ! Local variables real, dimension(SZI_(G)) :: deltaRhoAtKm1, deltaRhoAtK ! Density differences [kg m-3]. - real, dimension(SZI_(G)) :: pRef_MLD, pRef_N2 ! Reference pressures in Pa. + real, dimension(SZI_(G)) :: pRef_MLD, pRef_N2 ! Reference pressures [Pa]. real, dimension(SZI_(G)) :: dK, dKm1, d1 ! Depths [Z ~> m]. real, dimension(SZI_(G)) :: rhoSurf, rhoAtK, rho1 ! Densities used for N2 [kg m-3]. real, dimension(SZI_(G), SZJ_(G)) :: MLD ! Diagnosed mixed layer depth [Z ~> m]. real, dimension(SZI_(G), SZJ_(G)) :: subMLN2 ! Diagnosed stratification below ML [s-2]. real, dimension(SZI_(G), SZJ_(G)) :: MLD2 ! Diagnosed MLD^2 [Z2 ~> m2]. real :: Rho_x_gE ! The product of density, gravitational acceleartion and a unit - ! conversion factor, in kg m-1 Z-1 s-2. - real :: gE_Rho0 ! The gravitational acceleration divided by a mean density, in m4 s-2 kg-1. + ! conversion factor [kg m-1 Z-1 s-2 ~> kg m-2 s-2]. + real :: gE_Rho0 ! The gravitational acceleration divided by a mean density [m4 s-2 kg-1]. real :: dz_subML ! Depth below ML over which to diagnose stratification [Z ~> m]. integer :: i, j, is, ie, js, je, k, nz, id_N2, id_SQ real :: aFac, ddRho @@ -768,7 +768,7 @@ subroutine applyBoundaryFluxesInOut(CS, G, GV, US, dt, fluxes, optics, h, tv, & type(ocean_grid_type), intent(in) :: G !< Grid structure type(verticalGrid_type), intent(in) :: GV !< ocean vertical grid structure type(unit_scale_type), intent(in) :: US !< A dimensional unit scaling type - real, intent(in) :: dt !< Time-step over which forcing is applied (s) + real, intent(in) :: dt !< Time-step over which forcing is applied [s] type(forcing), intent(inout) :: fluxes !< Surface fluxes container type(optics_type), pointer :: optics !< Optical properties container real, dimension(SZI_(G),SZJ_(G),SZK_(G)), & @@ -779,16 +779,16 @@ subroutine applyBoundaryFluxesInOut(CS, G, GV, US, dt, fluxes, optics, h, tv, & real, intent(in) :: evap_CFL_limit !< The largest fraction of a layer that !! can be evaporated in one time-step (non-dim). real, intent(in) :: minimum_forcing_depth !< The smallest depth over which - !! heat and freshwater fluxes is applied, in m. + !! heat and freshwater fluxes is applied [m]. real, dimension(SZI_(G),SZJ_(G),SZK_(G)), & optional, intent(out) :: cTKE !< Turbulent kinetic energy requirement to mix - !! forcing through each layer, in W m-2 + !! forcing through each layer [W m-2] real, dimension(SZI_(G),SZJ_(G),SZK_(G)), & optional, intent(out) :: dSV_dT !< Partial derivative of specific volume with - !! potential temperature, in m3 kg-1 K-1. + !! potential temperature [m3 kg-1 degC-1]. real, dimension(SZI_(G),SZJ_(G),SZK_(G)), & optional, intent(out) :: dSV_dS !< Partial derivative of specific volume with - !! salinity, in m3 kg-1 / (g kg-1). + !! salinity [m3 kg-1 ppt-1]. real, dimension(SZI_(G),SZJ_(G)), & optional, intent(out) :: SkinBuoyFlux !< Buoyancy flux at surface [Z2 s-3 ~> m2 s-3]. diff --git a/src/parameterizations/vertical/MOM_diapyc_energy_req.F90 b/src/parameterizations/vertical/MOM_diapyc_energy_req.F90 index 45dcca30c6..fe20811bc9 100644 --- a/src/parameterizations/vertical/MOM_diapyc_energy_req.F90 +++ b/src/parameterizations/vertical/MOM_diapyc_energy_req.F90 @@ -62,7 +62,7 @@ subroutine diapyc_energy_req_test(h_3d, dt, tv, G, GV, US, CS, Kd_int) ! Local variables real, dimension(GV%ke) :: & - T0, S0, & ! T0 & S0 are columns of initial temperatures and salinities, in degC and g/kg. + T0, S0, & ! T0 & S0 are columns of initial temperatures and salinities [degC] and g/kg. h_col ! h_col is a column of thicknesses h at tracer points [H ~> m or kg m-2]. real, dimension(GV%ke+1) :: & Kd, & ! A column of diapycnal diffusivities at interfaces [Z2 s-1 ~> m2 s-1]. @@ -125,12 +125,12 @@ subroutine diapyc_energy_req_calc(h_in, T_in, S_in, Kd, energy_Kd, dt, tv, & real, dimension(GV%ke), intent(in) :: h_in !< Layer thickness before entrainment, !! [H ~> m or kg m-2]. real, dimension(GV%ke), intent(in) :: T_in !< The layer temperatures [degC]. - real, dimension(GV%ke), intent(in) :: S_in !< The layer salinities, in g kg-1. + real, dimension(GV%ke), intent(in) :: S_in !< The layer salinities [ppt]. real, dimension(GV%ke+1), intent(in) :: Kd !< The interfaces diapycnal diffusivities !! [Z2 s-1 ~> m2 s-1]. real, intent(in) :: dt !< The amount of time covered by this call [s]. real, intent(out) :: energy_Kd !< The column-integrated rate of energy - !! consumption by diapycnal diffusion, in W m-2. + !! consumption by diapycnal diffusion [W m-2]. type(thermo_var_ptrs), intent(inout) :: tv !< A structure containing pointers to any !! available thermodynamic fields. !! Absent fields have NULL ptrs. @@ -148,34 +148,34 @@ subroutine diapyc_energy_req_calc(h_in, T_in, S_in, Kd, energy_Kd, dt, tv, & real, dimension(GV%ke) :: & p_lay, & ! Average pressure of a layer [Pa]. - dSV_dT, & ! Partial derivative of specific volume with temperature, in m3 kg-1 degC-1. - dSV_dS, & ! Partial derivative of specific volume with salinity, in m3 kg-1 / (g kg-1). - T0, S0, & ! Initial temperatures and salinities. - Te, Se, & ! Running incomplete estimates of the new temperatures and salinities. - Te_a, Se_a, & ! Running incomplete estimates of the new temperatures and salinities. - Te_b, Se_b, & ! Running incomplete estimates of the new temperatures and salinities. - Tf, Sf, & ! New final values of the temperatures and salinities. - dTe, dSe, & ! Running (1-way) estimates of temperature and salinity change. - dTe_a, dSe_a, & ! Running (1-way) estimates of temperature and salinity change. - dTe_b, dSe_b, & ! Running (1-way) estimates of temperature and salinity change. - Th_a, & ! An effective temperature times a thickness in the layer above, - ! including implicit mixing effects with other yet higher layers, in degC H. - Sh_a, & ! An effective salinity times a thickness in the layer above, - ! including implicit mixing effects with other yet higher layers, in ppt H. - Th_b, & ! An effective temperature times a thickness in the layer below, - ! including implicit mixing effects with other yet lower layers, in degC H. - Sh_b, & ! An effective salinity times a thickness in the layer below, - ! including implicit mixing effects with other yet lower layers, in ppt H. + dSV_dT, & ! Partial derivative of specific volume with temperature [m3 kg-1 degC-1]. + dSV_dS, & ! Partial derivative of specific volume with salinity [m3 kg-1 ppt-1]. + T0, S0, & ! Initial temperatures and salinities [degC] and [ppt]. + Te, Se, & ! Running incomplete estimates of the new temperatures and salinities [degC] and [ppt]. + Te_a, Se_a, & ! Running incomplete estimates of the new temperatures and salinities [degC] and [ppt]. + Te_b, Se_b, & ! Running incomplete estimates of the new temperatures and salinities [degC] and [ppt]. + Tf, Sf, & ! New final values of the temperatures and salinities [degC] and [ppt]. + dTe, dSe, & ! Running (1-way) estimates of temperature and salinity change [degC] and [ppt]. + dTe_a, dSe_a, & ! Running (1-way) estimates of temperature and salinity change [degC] and [ppt]. + dTe_b, dSe_b, & ! Running (1-way) estimates of temperature and salinity change [degC] and [ppt]. + Th_a, & ! An effective temperature times a thickness in the layer above, including implicit + ! mixing effects with other yet higher layers [degC H ~> degC m or degC kg m-2]. + Sh_a, & ! An effective salinity times a thickness in the layer above, including implicit + ! mixing effects with other yet higher layers [ppt H ~> ppt m or ppt kg m-2]. + Th_b, & ! An effective temperature times a thickness in the layer below, including implicit + ! mixing effects with other yet lower layers [degC H ~> degC m or degC kg m-2]. + Sh_b, & ! An effective salinity times a thickness in the layer below, including implicit + ! mixing effects with other yet lower layers [ppt H ~> ppt m or ppt kg m-2]. dT_to_dPE, & ! Partial derivative of column potential energy with the temperature - dS_to_dPE, & ! and salinity changes within a layer [J m-2 degC-1] and J m-2 / (g kg-1). + dS_to_dPE, & ! and salinity changes within a layer [J m-2 degC-1] and [J m-2 ppt-1]. dT_to_dColHt, & ! Partial derivatives of the total column height with the temperature - dS_to_dColHt, & ! and salinity changes within a layer [Z K-1 ~> m K-1] and [Z ppt-1 ~> m ppt-1]. + dS_to_dColHt, & ! and salinity changes within a layer [Z degC-1 ~> m degC-1] and [Z ppt-1 ~> m ppt-1]. dT_to_dColHt_a, & ! Partial derivatives of the total column height with the temperature dS_to_dColHt_a, & ! and salinity changes within a layer, including the implicit effects - ! of mixing with layers higher in the water colun [Z K-1 ~> m K-1] and [Z ppt-1 ~> m ppt-1]. + ! of mixing with layers higher in the water colun [Z degC-1 ~> m degC-1] and [Z ppt-1 ~> m ppt-1]. dT_to_dColHt_b, & ! Partial derivatives of the total column height with the temperature dS_to_dColHt_b, & ! and salinity changes within a layer, including the implicit effects - ! of mixing with layers lower in the water colun [Z K-1 ~> m K-1] and [Z ppt-1 ~> m ppt-1]. + ! of mixing with layers lower in the water colun [Z degC-1 ~> m degC-1] and [Z ppt-1 ~> m ppt-1]. dT_to_dPE_a, & ! Partial derivatives of column potential energy with the temperature dS_to_dPE_a, & ! and salinity changes within a layer, including the implicit effects ! of mixing with layers higher in the water column, in @@ -223,11 +223,11 @@ subroutine diapyc_energy_req_calc(h_in, T_in, S_in, Kd, energy_Kd, dt, tv, & real :: h_neglect ! A thickness that is so small it is usually lost ! in roundoff and can be neglected [H ~> m or kg m-2]. real :: dTe_term ! A diffusivity-independent term related to the temperature - ! change in the layer below the interface, in K H. + ! change in the layer below the interface [degC H ~> degC m or degC kg m-2]. real :: dSe_term ! A diffusivity-independent term related to the salinity - ! change in the layer below the interface, in ppt H. + ! change in the layer below the interface [ppt H ~> ppt m or ppt kg m-2]. real :: Kddt_h_guess ! A guess of the final value of Kddt_h [H ~> m or kg m-2]. - real :: dMass ! The mass per unit area within a layer, in kg m-2. + real :: dMass ! The mass per unit area within a layer [kg m-2]. real :: dPres ! The hydrostatic pressure change across a layer [Pa]. real :: dMKE_max ! The maximum amount of mean kinetic energy that could be ! converted to turbulent kinetic energy if the velocity in @@ -239,8 +239,8 @@ subroutine diapyc_energy_req_calc(h_in, T_in, S_in, Kd, energy_Kd, dt, tv, & real :: ColHt_cor ! The correction to PE_chg that is made due to a net ! change in the column height [J m-2]. real :: htot ! A running sum of thicknesses [H ~> m or kg m-2]. - real :: dTe_t2, dT_km1_t2, dT_k_t2 ! Temporary arrays describing temperature changes. - real :: dSe_t2, dS_km1_t2, dS_k_t2 ! Temporary arrays describing salinity changes. + real :: dTe_t2, dT_km1_t2, dT_k_t2 ! Temporary arrays describing temperature changes [degC]. + real :: dSe_t2, dS_km1_t2, dS_k_t2 ! Temporary arrays describing salinity changes [ppt]. logical :: do_print ! The following are a bunch of diagnostic arrays for debugging purposes. @@ -984,16 +984,16 @@ subroutine find_PE_chg(Kddt_h0, dKddt_h, hp_a, hp_b, Th_a, Sh_a, Th_b, Sh_b, & !! Kddt_h for the interface above [H ~> m or kg m-2]. real, intent(in) :: Th_a !< An effective temperature times a thickness in the layer !! above, including implicit mixing effects with other - !! yet higher layers, in K H. + !! yet higher layers [degC H ~> degC m or degC kg m-2]. real, intent(in) :: Sh_a !< An effective salinity times a thickness in the layer !! above, including implicit mixing effects with other - !! yet higher layers, in K H. + !! yet higher layers [ppt H ~> ppt m or ppt kg m-2]. real, intent(in) :: Th_b !< An effective temperature times a thickness in the layer !! below, including implicit mixing effects with other - !! yet lower layers, in K H. + !! yet lower layers [degC H ~> degC m or degC kg m-2]. real, intent(in) :: Sh_b !< An effective salinity times a thickness in the layer !! below, including implicit mixing effects with other - !! yet lower layers, in K H. + !! yet lower layers [ppt H ~> ppt m or ppt kg m-2]. real, intent(in) :: dT_to_dPE_a !< A factor (pres_lay*mass_lay*dSpec_vol/dT) relating !! a layer's temperature change to the change in column !! potential energy, including all implicit diffusive changes @@ -1016,7 +1016,7 @@ subroutine find_PE_chg(Kddt_h0, dKddt_h, hp_a, hp_b, Th_a, Sh_a, Th_b, Sh_b, & real, intent(in) :: dT_to_dColHt_a !< A factor (mass_lay*dSColHtc_vol/dT) relating !! a layer's temperature change to the change in column !! height, including all implicit diffusive changes - !! in the temperatures of all the layers above [Z K-1 ~> m K-1]. + !! in the temperatures of all the layers above [Z degC-1 ~> m degC-1]. real, intent(in) :: dS_to_dColHt_a !< A factor (mass_lay*dSColHtc_vol/dS) relating !! a layer's salinity change to the change in column !! height, including all implicit diffusive changes @@ -1024,7 +1024,7 @@ subroutine find_PE_chg(Kddt_h0, dKddt_h, hp_a, hp_b, Th_a, Sh_a, Th_b, Sh_b, & real, intent(in) :: dT_to_dColHt_b !< A factor (mass_lay*dSColHtc_vol/dT) relating !! a layer's temperature change to the change in column !! height, including all implicit diffusive changes - !! in the temperatures of all the layers below [Z K-1 ~> m K-1]. + !! in the temperatures of all the layers below [Z degC-1 ~> m degC-1]. real, intent(in) :: dS_to_dColHt_b !< A factor (mass_lay*dSColHtc_vol/dS) relating !! a layer's salinity change to the change in column !! height, including all implicit diffusive changes @@ -1044,14 +1044,14 @@ subroutine find_PE_chg(Kddt_h0, dKddt_h, hp_a, hp_b, Th_a, Sh_a, Th_b, Sh_b, & real :: hps ! The sum of the two effective pivot thicknesses [H ~> m or kg m-2]. real :: bdt1 ! A product of the two pivot thicknesses plus a diffusive term [H2 ~> m2 or kg2 m-4]. - real :: dT_c ! The core term in the expressions for the temperature changes [K H2 ~> K m2 or K kg2 m-4]. + real :: dT_c ! The core term in the expressions for the temperature changes [degC H2 ~> degC m2 or degC kg2 m-4]. real :: dS_c ! The core term in the expressions for the salinity changes [psu H2 ~> psu m2 or psu kg2 m-4]. real :: PEc_core ! The diffusivity-independent core term in the expressions - ! for the potential energy changes, J m-3. + ! for the potential energy changes [J m-3]. real :: ColHt_core ! The diffusivity-independent core term in the expressions - ! for the column height changes, J m-3. - real :: ColHt_chg ! The change in the column height, in m. - real :: y1 ! A local temporary term, in units of H-3 or H-4 in various contexts. + ! for the column height changes [J m-3]. + real :: ColHt_chg ! The change in the column height [Z ~> m]. + real :: y1 ! A local temporary term, in [H-3] or [H-4] in various contexts. ! The expression for the change in potential energy used here is derived ! from the expression for the final estimates of the changes in temperature @@ -1126,14 +1126,14 @@ subroutine find_PE_chg_orig(Kddt_h, h_k, b_den_1, dTe_term, dSe_term, & !! for the tridiagonal solver, given by h_k plus a term that !! is a fraction (determined from the tridiagonal solver) of !! Kddt_h for the interface above [H ~> m or kg m-2]. - real, intent(in) :: dTe_term !< A diffusivity-independent term related to the - !! temperature change in the layer below the interface, in K H. - real, intent(in) :: dSe_term !< A diffusivity-independent term related to the - !! salinity change in the layer below the interface, in ppt H. + real, intent(in) :: dTe_term !< A diffusivity-independent term related to the temperature change + !! in the layer below the interface [degC H ~> degC m or degC kg m-2]. + real, intent(in) :: dSe_term !< A diffusivity-independent term related to the salinity change + !! in the layer below the interface [ppt H ~> ppt m or ppt kg m-2]. real, intent(in) :: dT_km1_t2 !< A diffusivity-independent term related to the - !! temperature change in the layer above the interface, in K. + !! temperature change in the layer above the interface [degC]. real, intent(in) :: dS_km1_t2 !< A diffusivity-independent term related to the - !! salinity change in the layer above the interface, in ppt. + !! salinity change in the layer above the interface [ppt]. real, intent(in) :: pres_Z !< The hydrostatic interface pressure, which is used to relate !! the changes in column thickness to the energy that is radiated !! as gravity waves and unavailable to drive mixing [J m-2 Z-1 ~> J m-3]. @@ -1156,7 +1156,7 @@ subroutine find_PE_chg_orig(Kddt_h, h_k, b_den_1, dTe_term, dSe_term, & real, intent(in) :: dT_to_dColHt_k !< A factor (mass_lay*dSColHtc_vol/dT) relating !! a layer's temperature change to the change in column !! height, including all implicit diffusive changes - !! in the temperatures of all the layers below [Z K-1 ~> m K-1]. + !! in the temperatures of all the layers below [Z degC-1 ~> m degC-1]. real, intent(in) :: dS_to_dColHt_k !< A factor (mass_lay*dSColHtc_vol/dS) relating !! a layer's salinity change to the change in column !! height, including all implicit diffusive changes @@ -1164,7 +1164,7 @@ subroutine find_PE_chg_orig(Kddt_h, h_k, b_den_1, dTe_term, dSe_term, & real, intent(in) :: dT_to_dColHta !< A factor (mass_lay*dSColHtc_vol/dT) relating !! a layer's temperature change to the change in column !! height, including all implicit diffusive changes - !! in the temperatures of all the layers above [Z K-1 ~> m K-1]. + !! in the temperatures of all the layers above [Z degC-1 ~> m degC-1]. real, intent(in) :: dS_to_dColHta !< A factor (mass_lay*dSColHtc_vol/dS) relating !! a layer's salinity change to the change in column !! height, including all implicit diffusive changes diff --git a/src/parameterizations/vertical/MOM_energetic_PBL.F90 b/src/parameterizations/vertical/MOM_energetic_PBL.F90 index 43294f6538..ec5d7dc5c0 100644 --- a/src/parameterizations/vertical/MOM_energetic_PBL.F90 +++ b/src/parameterizations/vertical/MOM_energetic_PBL.F90 @@ -153,7 +153,7 @@ module MOM_energetic_PBL ! Additional output parameters also 2d ML_depth, & !< The mixed layer depth [Z ~> m]. (result after iteration step) ML_depth2, & !< The mixed layer depth [Z ~> m]. (guess for iteration step) - Enhance_M, & !< The enhancement to the turbulent velocity scale (non-dim) + Enhance_M, & !< The enhancement to the turbulent velocity scale [nondim] MSTAR_MIX, & !< Mstar used in EPBL MSTAR_LT, & !< Mstar for Langmuir turbulence MLD_EKMAN, & !< MLD over Ekman length @@ -192,18 +192,18 @@ subroutine energetic_PBL(h_3d, u_3d, v_3d, tv, fluxes, dt, Kd_int, G, GV, US, CS real, dimension(SZI_(G),SZJ_(G),SZK_(GV)), & intent(inout) :: h_3d !< Layer thicknesses [H ~> m or kg m-2]. real, dimension(SZI_(G),SZJ_(G),SZK_(GV)), & - intent(in) :: u_3d !< Zonal velocities interpolated to h points, - !! m s-1. + intent(in) :: u_3d !< Zonal velocities interpolated to h points + !! [m s-1]. real, dimension(SZI_(G),SZJ_(G),SZK_(GV)), & - intent(in) :: v_3d !< Zonal velocities interpolated to h points, - !! m s-1. + intent(in) :: v_3d !< Zonal velocities interpolated to h points + !! [m s-1]. real, dimension(SZI_(G),SZJ_(G),SZK_(GV)), & intent(in) :: dSV_dT !< The partial derivative of in-situ specific - !! volume with potential temperature, - !! in m3 kg-1 K-1. + !! volume with potential temperature + !! [m3 kg-1 K-1]. real, dimension(SZI_(G),SZJ_(G),SZK_(GV)), & intent(in) :: dSV_dS !< The partial derivative of in-situ specific - !! volume with salinity, in m3 kg-1 ppt-1. + !! volume with salinity [m3 kg-1 ppt-1]. real, dimension(SZI_(G),SZJ_(G),SZK_(GV)), & intent(in) :: TKE_forced !< The forcing requirements to homogenize the !! forcing that has been applied to each layer @@ -232,7 +232,7 @@ subroutine energetic_PBL(h_3d, u_3d, v_3d, tv, fluxes, dt, Kd_int, G, GV, US, CS real, dimension(SZI_(G),SZJ_(G),SZK_(GV)), & optional, intent(out) :: dT_expected !< The values of temperature change that !! should be expected when the returned - !! diffusivities are applied, in K. + !! diffusivities are applied [degC]. real, dimension(SZI_(G),SZJ_(G),SZK_(GV)), & optional, intent(out) :: dS_expected !< The values of salinity change that !! should be expected when the returned @@ -271,7 +271,7 @@ subroutine energetic_PBL(h_3d, u_3d, v_3d, tv, fluxes, dt, Kd_int, G, GV, US, CS v ! The meridional velocity [m s-1]. real, dimension(SZI_(G),SZK_(GV)+1) :: & Kd, & ! The diapycnal diffusivity, in m2 s-1. - pres, & ! Interface pressures in Pa. + pres, & ! Interface pressures [Pa]. pres_Z, & ! Interface pressures with a rescaling factor to convert interface height ! movements into changes in column potential energy [J m-2 Z-1 ~> J m-3]. hb_hs ! The distance from the bottom over the thickness of the @@ -332,7 +332,7 @@ subroutine energetic_PBL(h_3d, u_3d, v_3d, tv, fluxes, dt, Kd_int, G, GV, US, CS real :: b1 ! b1 is inverse of the pivot used by the tridiagonal solver [H-1 ~> m-1 or m2 kg-1]. real :: h_neglect ! A thickness that is so small it is usually lost ! in roundoff and can be neglected [H ~> m or kg m-2]. - real :: dMass ! The mass per unit area within a layer, in kg m-2. + real :: dMass ! The mass per unit area within a layer [kg m-2]. real :: dPres ! The hydrostatic pressure change across a layer [Pa]. real :: dMKE_max ! The maximum amount of mean kinetic energy that could be ! converted to turbulent kinetic energy if the velocity in @@ -355,13 +355,13 @@ subroutine energetic_PBL(h_3d, u_3d, v_3d, tv, fluxes, dt, Kd_int, G, GV, US, CS real :: C1_3 ! = 1/3. real :: vonKar ! The vonKarman constant. - real :: I_dtrho ! 1.0 / (dt * Rho0) in m3 kg-1 s-1. This is + real :: I_dtrho ! 1.0 / (dt * Rho0) in [m3 kg-1 s-1]. This is ! used convert TKE back into ustar^3. real :: U_star ! The surface friction velocity [Z s-1 ~> m s-1]. real :: U_Star_Mean ! The surface friction without gustiness [Z s-1 ~> m s-1]. real :: vstar ! An in-situ turbulent velocity [m s-1]. real :: Enhance_M ! An enhancement factor for vstar, based here on Langmuir impact. - real :: LA ! The Langmuir number (non-dim) + real :: LA ! The Langmuir number [nondim] real :: LAmod ! A modified Langmuir number accounting for other parameters. real :: hbs_here ! The local minimum of hb_hs and MixLen_shape, times a ! conversion factor from H to Z [Z H-1 ~> 1 or m3 kg-1]. @@ -371,20 +371,20 @@ subroutine energetic_PBL(h_3d, u_3d, v_3d, tv, fluxes, dt, Kd_int, G, GV, US, CS real :: tot_TKE ! The total TKE available to support mixing at interface K [J m-2]. real :: TKE_here ! The total TKE at this point in the algorithm [J m-2]. real :: dT_km1_t2 ! A diffusivity-independent term related to the temperature - ! change in the layer above the interface, in K. + ! change in the layer above the interface [degC]. real :: dS_km1_t2 ! A diffusivity-independent term related to the salinity - ! change in the layer above the interface, in ppt. + ! change in the layer above the interface [ppt]. real :: dTe_term ! A diffusivity-independent term related to the temperature - ! change in the layer below the interface, in K H. + ! change in the layer below the interface [degC H ~> degC m or degC kg m-2]. real :: dSe_term ! A diffusivity-independent term related to the salinity - ! change in the layer above the interface, in ppt H. - real :: dTe_t2 ! A part of dTe_term, in K H. - real :: dSe_t2 ! A part of dSe_term, in ppt H. + ! change in the layer above the interface [ppt H ~> ppt m or ppt kg m-2]. + real :: dTe_t2 ! A part of dTe_term [degC H ~> degC m or degC kg m-2]. + real :: dSe_t2 ! A part of dSe_term [ppt H ~> ppt m or ppt kg m-2]. real :: dPE_conv ! The convective change in column potential energy [J m-2]. real :: MKE_src ! The mean kinetic energy source of TKE due to Kddt_h(K) [J m-2]. real :: dMKE_src_dK ! The partial derivative of MKE_src with Kddt_h(K) [J m-2 H-1 ~> J m-3 or J kg-1]. real :: Kd_guess0 ! A first guess of the diapycnal diffusivity [Z2 s-1 ~> m2 s-1]. - real :: PE_chg_g0 ! The potential energy change when Kd is Kd_guess0 + real :: PE_chg_g0 ! The potential energy change when Kd is Kd_guess0 [J m-2] real :: dPEa_dKd_g0 real :: Kddt_h_g0 ! The first guess diapycnal diffusivity times a timestep divided ! by the average thicknesses around a layer [H ~> m or kg m-2]. @@ -397,7 +397,8 @@ subroutine energetic_PBL(h_3d, u_3d, v_3d, tv, fluxes, dt, Kd_int, G, GV, US, CS real :: TKE_left ! The amount of turbulent kinetic energy left for the most ! recent guess at Kddt_h(K) [J m-2]. real :: dPEc_dKd ! The partial derivative of PE_chg with Kddt_h(K) [J m-2 H-1 ~> J m-3 or J kg-1]. - real :: TKE_left_min, TKE_left_max, Kddt_h_max, Kddt_h_min + real :: TKE_left_min, TKE_left_max ! Maximum and minimum values of TKE_left [J m-2]. + real :: Kddt_h_max, Kddt_h_min ! Maximum and minimum values of Kddt_h(K) [H ~> m or kg m-2]. real :: Kddt_h_guess ! A guess at the value of Kddt_h(K) [H ~> m or kg m-2]. real :: Kddt_h_next ! The next guess at the value of Kddt_h(K) [H ~> m or kg m-2]. real :: dKddt_h ! The change between guesses at Kddt_h(K) [H ~> m or kg m-2]. @@ -414,7 +415,7 @@ subroutine energetic_PBL(h_3d, u_3d, v_3d, tv, fluxes, dt, Kd_int, G, GV, US, CS ! The following is only used as a diagnostic. real :: dt__diag ! A copy of dt_diag (if present) or dt [s]. - real :: IdtdR0 ! = 1.0 / (dt__diag * Rho0), in m3 kg-1 s-1. + real :: IdtdR0 ! = 1.0 / (dt__diag * Rho0) [m3 kg-1 s-1]. real, dimension(SZI_(G),SZJ_(G)) :: & Hsfc_used ! The thickness of the surface region [Z ~> m]. logical :: write_diags ! If true, write out diagnostics with this step. @@ -1571,16 +1572,16 @@ subroutine find_PE_chg(Kddt_h0, dKddt_h, hp_a, hp_b, Th_a, Sh_a, Th_b, Sh_b, & !! Kddt_h for the interface above [H ~> m or kg m-2]. real, intent(in) :: Th_a !< An effective temperature times a thickness in the layer !! above, including implicit mixing effects with other - !! yet higher layers, in K H. + !! yet higher layers [degC H ~> degC m or degC kg m-2]. real, intent(in) :: Sh_a !< An effective salinity times a thickness in the layer !! above, including implicit mixing effects with other - !! yet higher layers, in K H. + !! yet higher layers [degC H ~> degC m or degC kg m-2]. real, intent(in) :: Th_b !< An effective temperature times a thickness in the layer !! below, including implicit mixing effects with other - !! yet lower layers, in K H. + !! yet lower layers [degC H ~> degC m or degC kg m-2]. real, intent(in) :: Sh_b !< An effective salinity times a thickness in the layer !! below, including implicit mixing effects with other - !! yet lower layers, in K H. + !! yet lower layers [degC H ~> degC m or degC kg m-2]. real, intent(in) :: dT_to_dPE_a !< A factor (pres_lay*mass_lay*dSpec_vol/dT) relating !! a layer's temperature change to the change in column !! potential energy, including all implicit diffusive changes @@ -1631,7 +1632,7 @@ subroutine find_PE_chg(Kddt_h0, dKddt_h, hp_a, hp_b, Th_a, Sh_a, Th_b, Sh_b, & real :: hps ! The sum of the two effective pivot thicknesses [H ~> m or kg m-2]. real :: bdt1 ! A product of the two pivot thicknesses plus a diffusive term [H2 ~> m2 or kg2 m-4]. - real :: dT_c ! The core term in the expressions for the temperature changes, in K H2. + real :: dT_c ! The core term in the expressions for the temperature changes [degC H ~> degC m or degC kg m-2]2. real :: dS_c ! The core term in the expressions for the salinity changes, in psu H2. real :: PEc_core ! The diffusivity-independent core term in the expressions ! for the potential energy changes, J m-3. @@ -1712,14 +1713,14 @@ subroutine find_PE_chg_orig(Kddt_h, h_k, b_den_1, dTe_term, dSe_term, & !! for the tridiagonal solver, given by h_k plus a term that !! is a fraction (determined from the tridiagonal solver) of !! Kddt_h for the interface above [H ~> m or kg m-2]. - real, intent(in) :: dTe_term !< A diffusivity-independent term related to the - !! temperature change in the layer below the interface, in K H. - real, intent(in) :: dSe_term !< A diffusivity-independent term related to the - !! salinity change in the layer below the interface, in ppt H. + real, intent(in) :: dTe_term !< A diffusivity-independent term related to the temperature change + !! in the layer below the interface [degC H ~> degC m or degC kg m-2]. + real, intent(in) :: dSe_term !< A diffusivity-independent term related to the salinity change + !! in the layer below the interface [ppt H ~> ppt m or ppt kg m-2]. real, intent(in) :: dT_km1_t2 !< A diffusivity-independent term related to the - !! temperature change in the layer above the interface, in K. + !! temperature change in the layer above the interface [degC]. real, intent(in) :: dS_km1_t2 !< A diffusivity-independent term related to the - !! salinity change in the layer above the interface, in ppt. + !! salinity change in the layer above the interface [ppt]. real, intent(in) :: pres_Z !< The rescaled hydrostatic interface pressure, which relates !! the changes in column thickness to the energy that is radiated !! as gravity waves and unavailable to drive mixing [J m-2 Z-1 ~> J m-3]. diff --git a/src/parameterizations/vertical/MOM_entrain_diffusive.F90 b/src/parameterizations/vertical/MOM_entrain_diffusive.F90 index e31b078922..9a0a46ec67 100644 --- a/src/parameterizations/vertical/MOM_entrain_diffusive.F90 +++ b/src/parameterizations/vertical/MOM_entrain_diffusive.F90 @@ -103,7 +103,7 @@ subroutine entrainment_diffusive(u, v, h, tv, fluxes, dt, G, GV, US, CS, ea, eb, ! interactions between layers [H ~> m or kg m-2]. Fprev, &! The previous estimate of F [H ~> m or kg m-2]. dFdfm, &! The partial derivative of F with respect to changes in F of the - ! neighboring layers. Nondimensional. + ! neighboring layers. [nondim] h_guess ! An estimate of the layer thicknesses after entrainment, but ! before the entrainments are adjusted to drive the layer ! densities toward their target values [H ~> m or kg m-2]. @@ -164,17 +164,18 @@ subroutine entrainment_diffusive(u, v, h, tv, fluxes, dt, G, GV, US, CS, ea, eb, real, dimension(SZI_(G),SZK_(G)) :: & ds_dsp1, & ! The coordinate variable (sigma-2) difference across an ! interface divided by the difference across the interface - ! below it. Nondimensional. + ! below it. [nondim] dsp1_ds, & ! The inverse coordinate variable (sigma-2) difference ! across an interface times the difference across the - ! interface above it. Nondimensional. - I2p2dsp1_ds, & ! 1 / (2 + 2 * ds_k+1 / ds_k). Nondimensional. + ! interface above it. [nondim] + I2p2dsp1_ds, & ! 1 / (2 + 2 * ds_k+1 / ds_k). [nondim] grats ! 2*(2 + ds_k+1 / ds_k + ds_k / ds_k+1) = - ! 4*ds_Lay*(1/ds_k + 1/ds_k+1). Nondim. + ! 4*ds_Lay*(1/ds_k + 1/ds_k+1). [nondim] real :: dRHo ! The change in locally referenced potential density between ! the layers above and below an interface [kg m-3]. - real :: g_2dt ! 0.5 * G_Earth / dt, times unit conversion factors, in m3 H-2 s-3. + real :: g_2dt ! 0.5 * G_Earth / dt, times unit conversion factors + ! [m3 H-2 s-3 ~> m s-3 or m7 kg-2 s-3]. real, dimension(SZI_(G)) :: & pressure, & ! The pressure at an interface [Pa]. T_eos, S_eos, & ! The potential temperature and salinity at which to @@ -1262,9 +1263,9 @@ subroutine determine_dSkb(h_bl, Sref, Ent_bl, E_kb, is, ie, kmb, G, GV, limit, & real :: rat real :: dS_kbp1, IdS_kbp1 real :: deriv_dSLay - real :: Inv_term ! Nondimensional. - real :: f1, df1_drat ! Nondimensional temporary variables. - real :: z, dz_drat, f2, df2_dz, expz ! Nondimensional temporary variables. + real :: Inv_term ! [nondim] + real :: f1, df1_drat ! Temporary variables [nondim]. + real :: z, dz_drat, f2, df2_dz, expz ! Temporary variables [nondim]. real :: eps_dSLay, eps_dSkb ! Small nondimensional constants. integer :: i, k diff --git a/src/parameterizations/vertical/MOM_full_convection.F90 b/src/parameterizations/vertical/MOM_full_convection.F90 index 866dd16114..a47e113fc4 100644 --- a/src/parameterizations/vertical/MOM_full_convection.F90 +++ b/src/parameterizations/vertical/MOM_full_convection.F90 @@ -26,9 +26,9 @@ subroutine full_convection(G, GV, h, tv, T_adj, S_adj, p_surf, Kddt_smooth, & type(thermo_var_ptrs), intent(in) :: tv !< A structure pointing to various !! thermodynamic variables real, dimension(SZI_(G),SZJ_(G),SZK_(G)), & - intent(out) :: T_adj !< Adjusted potential temperature in degC. + intent(out) :: T_adj !< Adjusted potential temperature [degC]. real, dimension(SZI_(G),SZJ_(G),SZK_(G)), & - intent(out) :: S_adj !< Adjusted salinity in ppt. + intent(out) :: S_adj !< Adjusted salinity [ppt]. real, dimension(:,:), pointer :: p_surf !< The pressure at the ocean surface in Pa (or NULL). real, intent(in) :: Kddt_smooth !< A smoothing vertical !! diffusivity times a timestep [H2 ~> m2 or kg2 m-4]. @@ -45,20 +45,20 @@ subroutine full_convection(G, GV, h, tv, T_adj, S_adj, p_surf, Kddt_smooth, & ! logical :: use_EOS ! If true, density is calculated from T & S using an equation of state. real, dimension(SZI_(G),SZK0_(G)) :: & Te_a, & ! A partially updated temperature estimate including the influnce from - ! mixing with layers above rescaled by a factor of d_a, in degC. + ! mixing with layers above rescaled by a factor of d_a [degC]. ! This array is discreted on tracer cells, but contains an extra ! layer at the top for algorithmic convenience. Se_a ! A partially updated salinity estimate including the influnce from - ! mixing with layers above rescaled by a factor of d_a, in ppt. + ! mixing with layers above rescaled by a factor of d_a [ppt]. ! This array is discreted on tracer cells, but contains an extra ! layer at the top for algorithmic convenience. real, dimension(SZI_(G),SZK_(G)+1) :: & Te_b, & ! A partially updated temperature estimate including the influnce from - ! mixing with layers below rescaled by a factor of d_b, in degC. + ! mixing with layers below rescaled by a factor of d_b [degC]. ! This array is discreted on tracer cells, but contains an extra ! layer at the bottom for algorithmic convenience. Se_b ! A partially updated salinity estimate including the influnce from - ! mixing with layers below rescaled by a factor of d_b, in ppt. + ! mixing with layers below rescaled by a factor of d_b [ppt]. ! This array is discreted on tracer cells, but contains an extra ! layer at the bottom for algorithmic convenience. real, dimension(SZI_(G),SZK_(G)+1) :: & @@ -287,14 +287,14 @@ function is_unstable(dRho_dT, dRho_dS, h_a, h_b, mix_A, mix_B, T_a, T_b, S_a, S_ real, intent(in) :: h_b !< The thickness of the layer below [H ~> m or kg m-2] real, intent(in) :: mix_A !< The time integrated mixing rate of the interface above [H ~> m or kg m-2] real, intent(in) :: mix_B !< The time integrated mixing rate of the interface below [H ~> m or kg m-2] - real, intent(in) :: T_a !< The initial temperature of the layer above, in degC - real, intent(in) :: T_b !< The initial temperature of the layer below, in degC - real, intent(in) :: S_a !< The initial salinity of the layer below, in ppt - real, intent(in) :: S_b !< The initial salinity of the layer below, in ppt - real, intent(in) :: Te_aa !< The estimated temperature two layers above rescaled by d_A, in degC - real, intent(in) :: Te_bb !< The estimated temperature two layers below rescaled by d_B, in degC - real, intent(in) :: Se_aa !< The estimated salinity two layers above rescaled by d_A, in ppt - real, intent(in) :: Se_bb !< The estimated salinity two layers below rescaled by d_B, in ppt + real, intent(in) :: T_a !< The initial temperature of the layer above [degC] + real, intent(in) :: T_b !< The initial temperature of the layer below [degC] + real, intent(in) :: S_a !< The initial salinity of the layer below [ppt] + real, intent(in) :: S_b !< The initial salinity of the layer below [ppt] + real, intent(in) :: Te_aa !< The estimated temperature two layers above rescaled by d_A [degC] + real, intent(in) :: Te_bb !< The estimated temperature two layers below rescaled by d_B [degC] + real, intent(in) :: Se_aa !< The estimated salinity two layers above rescaled by d_A [ppt] + real, intent(in) :: Se_bb !< The estimated salinity two layers below rescaled by d_B [ppt] real, intent(in) :: d_A !< The rescaling dependency across the interface above, nondim. real, intent(in) :: d_B !< The rescaling dependency across the interface below, nondim. logical :: is_unstable !< The return value, true if the profile is statically unstable @@ -332,7 +332,7 @@ subroutine smoothed_dRdT_dRdS(h, tv, Kddt, dR_dT, dR_dS, G, GV, j, p_surf, halo) intent(out) :: dR_dS !< Derivative of locally referenced !! potential density with salinity [kg m-3 ppt-1] integer, intent(in) :: j !< The j-point to work on. - real, dimension(:,:), pointer :: p_surf !< The pressure at the ocean surface in Pa (or NULL). + real, dimension(:,:), pointer :: p_surf !< The pressure at the ocean surface [Pa]. integer, optional, intent(in) :: halo !< Halo width over which to compute ! Local variables @@ -340,11 +340,11 @@ subroutine smoothed_dRdT_dRdS(h, tv, Kddt, dR_dT, dR_dS, G, GV, j, p_surf, halo) ! between layers within in a timestep [H ~> m or kg m-2]. real :: b1(SZI_(G)), d1(SZI_(G)) ! b1, c1, and d1 are variables used by the real :: c1(SZI_(G),SZK_(G)) ! tridiagonal solver. - real :: T_f(SZI_(G),SZK_(G)) ! Filtered temperatures in degC - real :: S_f(SZI_(G),SZK_(G)) ! Filtered salinities in ppt - real :: pres(SZI_(G)) ! Interface pressures, in Pa. - real :: T_EOS(SZI_(G)) ! Filtered and vertically averaged temperatures in degC - real :: S_EOS(SZI_(G)) ! Filtered and vertically averaged salinities in ppt + real :: T_f(SZI_(G),SZK_(G)) ! Filtered temperatures [degC] + real :: S_f(SZI_(G),SZK_(G)) ! Filtered salinities [ppt] + real :: pres(SZI_(G)) ! Interface pressures [Pa]. + real :: T_EOS(SZI_(G)) ! Filtered and vertically averaged temperatures [degC] + real :: S_EOS(SZI_(G)) ! Filtered and vertically averaged salinities [ppt] real :: kap_dt_x2 ! The product of 2*kappa*dt [H2 ~> m2 or kg2 m-4]. real :: h_neglect, h0 ! Negligible thicknesses to allow for zero thicknesses, ! [H ~> m or kg m-2]. diff --git a/src/parameterizations/vertical/MOM_internal_tide_input.F90 b/src/parameterizations/vertical/MOM_internal_tide_input.F90 index daf6ae043c..773a7a4835 100644 --- a/src/parameterizations/vertical/MOM_internal_tide_input.F90 +++ b/src/parameterizations/vertical/MOM_internal_tide_input.F90 @@ -36,11 +36,11 @@ module MOM_int_tide_input logical :: debug !< If true, write verbose checksums for debugging. type(diag_ctrl), pointer :: diag => NULL() !< A structure that is used to !! regulate the timing of diagnostic output. - real :: TKE_itide_max !< Maximum Internal tide conversion (W m-2) - !! available to mix above the BBL + real :: TKE_itide_max !< Maximum Internal tide conversion + !! available to mix above the BBL [W m-2] real, allocatable, dimension(:,:) :: TKE_itidal_coef - !< The time-invariant field that enters the TKE_itidal input calculation, in J m-2. + !< The time-invariant field that enters the TKE_itidal input calculation [J m-2]. character(len=200) :: inputdir !< The directory for input files. !>@{ Diagnostic IDs @@ -133,9 +133,9 @@ subroutine find_N2_bottom(h, tv, T_f, S_f, h2, fluxes, G, GV, US, N2_bot) type(thermo_var_ptrs), intent(in) :: tv !< A structure containing pointers to the !! thermodynamic fields real, dimension(SZI_(G),SZJ_(G),SZK_(G)), intent(in) :: T_f !< Temperature after vertical filtering to - !! smooth out the values in thin layers, in degC. + !! smooth out the values in thin layers [degC]. real, dimension(SZI_(G),SZJ_(G),SZK_(G)), intent(in) :: S_f !< Salinity after vertical filtering to - !! smooth out the values in thin layers, in PSU. + !! smooth out the values in thin layers [ppt]. real, dimension(SZI_(G),SZJ_(G)), intent(in) :: h2 !< Bottom topographic roughness [Z2 ~> m2]. type(forcing), intent(in) :: fluxes !< A structure of thermodynamic surface fluxes type(int_tide_input_CS), pointer :: CS !< This module's control structure. @@ -145,9 +145,9 @@ subroutine find_N2_bottom(h, tv, T_f, S_f, h2, fluxes, G, GV, US, N2_bot) real, dimension(SZI_(G),SZK_(G)+1) :: & dRho_int ! The unfiltered density differences across interfaces. real, dimension(SZI_(G)) :: & - pres, & ! The pressure at each interface, in Pa. - Temp_int, & ! The temperature at each interface, in degC. - Salin_int, & ! The salinity at each interface, in PSU. + pres, & ! The pressure at each interface [Pa]. + Temp_int, & ! The temperature at each interface [degC]. + Salin_int, & ! The salinity at each interface [ppt]. drho_bot, & h_amp, & ! The amplitude of topographic roughness [Z ~> m]. hb, & ! The depth below a layer [Z ~> m]. diff --git a/src/parameterizations/vertical/MOM_set_diffusivity.F90 b/src/parameterizations/vertical/MOM_set_diffusivity.F90 index c717689140..1646a6650b 100644 --- a/src/parameterizations/vertical/MOM_set_diffusivity.F90 +++ b/src/parameterizations/vertical/MOM_set_diffusivity.F90 @@ -71,8 +71,8 @@ module MOM_set_diffusivity logical :: use_LOTW_BBL_diffusivity !< If true, use simpler/less precise, BBL diffusivity. logical :: LOTW_BBL_use_omega !< If true, use simpler/less precise, BBL diffusivity. real :: BBL_effic !< efficiency with which the energy extracted - !! by bottom drag drives BBL diffusion (nondim) - real :: cdrag !< quadratic drag coefficient (nondim) + !! by bottom drag drives BBL diffusion [nondim] + real :: cdrag !< quadratic drag coefficient [nondim] real :: IMax_decay !< inverse of a maximum decay scale for !! bottom-drag driven turbulence [Z-1 ~> m-1]. real :: Kv !< The interior vertical viscosity [Z2 s-1 ~> m2 s-1]. @@ -84,8 +84,7 @@ module MOM_set_diffusivity !! filtering or scaling [Z2 s-1 ~> m2 s-1]. real :: Kdml !< mixed layer diapycnal diffusivity [Z2 s-1 ~> m2 s-1]. !! when bulkmixedlayer==.false. - real :: Hmix !< mixed layer thickness (meter) when - !! bulkmixedlayer==.false. + real :: Hmix !< mixed layer thickness [meter] when BULKMIXEDLAYER==.false. type(diag_ctrl), pointer :: diag => NULL() !< structure to regulate diagnostic output timing logical :: limit_dissipation !< If enabled, dissipation is limited to be larger @@ -96,7 +95,7 @@ module MOM_set_diffusivity real :: dissip_N2 !< Coefficient c in minimum dissipation = c*N2 [Z2 m-2 W m-3 s2 ~> J s m-3] real :: dissip_Kd_min !< Minimum Kd [Z2 s-1 ~> m2 s-1], with dissipation Rho0*Kd_min*N^2 - real :: TKE_itide_max !< maximum internal tide conversion (W m-2) + real :: TKE_itide_max !< maximum internal tide conversion [W m-2] !! available to mix above the BBL real :: omega !< Earth's rotation frequency [s-1] logical :: ML_radiation !< allow a fraction of TKE available from wind work @@ -110,23 +109,23 @@ module MOM_set_diffusivity !! of exp(-h_ML*Idecay_len_TkE), where Idecay_len_TKE is !! calculated the same way as in the mixed layer code. !! The diapycnal diffusivity is KD(k) = E/(N2(k)+OMEGA2), - !! where N2 is the squared buoyancy frequency (s-2) and OMEGA2 + !! where N2 is the squared buoyancy frequency [s-2] and OMEGA2 !! is the rotation rate of the earth squared. real :: ML_rad_kd_max !< Maximum diapycnal diffusivity due to turbulence !! radiated from the base of the mixed layer [Z2 s-1 ~> m2 s-1]. real :: ML_rad_efold_coeff !< non-dim coefficient to scale penetration depth real :: ML_rad_coeff !< coefficient, which scales MSTAR*USTAR^3 to !! obtain energy available for mixing below - !! mixed layer base (nondimensional) + !! mixed layer base [nondim] logical :: ML_rad_TKE_decay !< If true, apply same exponential decay !! to ML_rad as applied to the other surface !! sources of TKE in the mixed layer code. real :: ustar_min !< A minimum value of ustar to avoid numerical !! problems [Z s-1 ~> m s-1]. If the value is small enough, !! this parameter should not affect the solution. - real :: TKE_decay !< ratio of natural Ekman depth to TKE decay scale (nondim) + real :: TKE_decay !< ratio of natural Ekman depth to TKE decay scale [nondim] real :: mstar !< ratio of friction velocity cubed to - !! TKE input to the mixed layer (nondim) + !! TKE input to the mixed layer [nondim] logical :: ML_use_omega !< If true, use absolute rotation rate instead !! of the vertical component of rotation when !! setting the decay scale for mixed layer turbulence. @@ -145,8 +144,8 @@ module MOM_set_diffusivity logical :: simple_TKE_to_Kd !< If true, uses a simple estimate of Kd/TKE that !! does not rely on a layer-formulation. real :: Max_Rrho_salt_fingers !< max density ratio for salt fingering - real :: Max_salt_diff_salt_fingers !< max salt diffusivity for salt fingers (m2/s) - real :: Kv_molecular !< molecular visc for double diff convect (m2/s) + real :: Max_salt_diff_salt_fingers !< max salt diffusivity for salt fingers [Z2 s-1 ~> m2 s-1] + real :: Kv_molecular !< molecular visc for double diff convect [Z2 s-1 ~> m2 s-1] character(len=200) :: inputdir !< The directory in which input files are found type(user_change_diff_CS), pointer :: user_change_diff_CSp => NULL() !< Control structure for a child module @@ -171,11 +170,11 @@ module MOM_set_diffusivity !> This structure has memory for used in calculating diagnostics of diffusivity type diffusivity_diags real, pointer, dimension(:,:,:) :: & - N2_3d => NULL(), & !< squared buoyancy frequency at interfaces (1/s2) - Kd_user => NULL(), & !< user-added diffusivity at interfaces (m2/s) - Kd_BBL => NULL(), & !< BBL diffusivity at interfaces (m2/s) - Kd_work => NULL(), & !< layer integrated work by diapycnal mixing (W/m2) - maxTKE => NULL(), & !< energy required to entrain to h_max (m3/s3) + N2_3d => NULL(), & !< squared buoyancy frequency at interfaces [s-2] + Kd_user => NULL(), & !< user-added diffusivity at interfaces [Z2 s-1 ~> m2 s-1] + Kd_BBL => NULL(), & !< BBL diffusivity at interfaces [Z2 s-1 ~> m2 s-1] + Kd_work => NULL(), & !< layer integrated work by diapycnal mixing [W m-2] + maxTKE => NULL(), & !< energy required to entrain to h_max [m3 s-3] KT_extra => NULL(), & !< double diffusion diffusivity for temp [Z2 s-1 ~> m2 s-1]. KS_extra => NULL() !< double diffusion diffusivity for saln [Z2 s-1 ~> m2 s-1]. real, pointer, dimension(:,:,:) :: TKE_to_Kd => NULL() @@ -223,42 +222,42 @@ subroutine set_diffusivity(u, v, h, u_h, v_h, tv, fluxes, optics, visc, dt, & !! properties of the ocean. type(vertvisc_type), intent(inout) :: visc !< Structure containing vertical viscosities, bottom !! boundary layer properies, and related fields. - real, intent(in) :: dt !< Time increment (sec). + real, intent(in) :: dt !< Time increment [s]. type(set_diffusivity_CS), pointer :: CS !< Module control structure. real, dimension(SZI_(G),SZJ_(G),SZK_(G)), & - intent(out) :: Kd_lay !< Diapycnal diffusivity of each layer (m2/sec). + intent(out) :: Kd_lay !< Diapycnal diffusivity of each layer [Z2 s-1 ~> m2 s-1]. real, dimension(SZI_(G),SZJ_(G),SZK_(G)+1), & - optional, intent(out) :: Kd_int !< Diapycnal diffusivity at each interface (m2/sec). + optional, intent(out) :: Kd_int !< Diapycnal diffusivity at each interface [Z2 s-1 ~> m2 s-1]. ! local variables real, dimension(SZI_(G)) :: & - N2_bot ! bottom squared buoyancy frequency (1/s2) + N2_bot ! bottom squared buoyancy frequency [s-2] type(diffusivity_diags) :: dd ! structure w/ arrays of pointers to avail diags real, dimension(SZI_(G),SZJ_(G),SZK_(G)) :: & - T_f, S_f ! Temperature and salinity (in deg C and ppt) with + T_f, S_f ! Temperature and salinity [degC] and [ppt] with ! massless layers filled vertically by diffusion. real, dimension(SZI_(G),SZJ_(G),SZK_(G)) :: & - T_adj, S_adj ! Temperature and salinity (in deg C and ppt) + T_adj, S_adj ! Temperature and salinity [degC] and [ppt] ! after full convective adjustment. real, dimension(SZI_(G),SZK_(G)) :: & - N2_lay, & !< squared buoyancy frequency associated with layers (1/s2) - maxTKE, & !< energy required to entrain to h_max (m3/s3) + N2_lay, & !< squared buoyancy frequency associated with layers [s-2] + maxTKE, & !< energy required to entrain to h_max [m3 s-3] TKE_to_Kd !< conversion rate (~1.0 / (G_Earth + dRho_lay)) between !< TKE dissipated within a layer and Kd in that layer, in - !< m2 s-1 / m3 s-3 = s2 m-1. + !< m2 s-1 / m3 s-3 = [s2 m-1]. real, dimension(SZI_(G),SZK_(G)+1) :: & - N2_int, & !< squared buoyancy frequency associated at interfaces (1/s2) - dRho_int, & !< locally ref potential density difference across interfaces (kg/m3) - KT_extra, & !< double difusion diffusivity of temperature (Z2/sec) - KS_extra !< double difusion diffusivity of salinity (Z2/sec) + N2_int, & !< squared buoyancy frequency associated at interfaces [s-2] + dRho_int, & !< locally ref potential density difference across interfaces [kg m-3] + KT_extra, & !< double difusion diffusivity of temperature [Z2 s-1 ~> m2 s-1] + KS_extra !< double difusion diffusivity of salinity [Z2 s-1 ~> m2 s-1] - real :: I_Rho0 ! inverse of Boussinesq density (m3/kg) - real :: dissip ! local variable for dissipation calculations (Z2 W/m5) - real :: Omega2 ! squared absolute rotation rate (1/s2) + real :: I_Rho0 ! inverse of Boussinesq density [m3 kg-1] + real :: dissip ! local variable for dissipation calculations [Z2 W m-5 ~> W m-3] + real :: Omega2 ! squared absolute rotation rate [s-2] logical :: use_EOS ! If true, compute density from T/S using equation of state. type(p3d) :: z_ptrs(6) ! pointers to diagns to be interpolated into depth space @@ -681,18 +680,18 @@ subroutine find_TKE_to_Kd(h, tv, dRho_int, N2_lay, j, dt, G, GV, US, CS, & !! usually (~Rho_0 / (G_Earth * dRho_lay)) !! [Z2 s-1 / m3 s-3 = Z2 s2 m-3 ~> s2 m-1] real, dimension(SZI_(G),SZK_(G)), intent(out) :: maxTKE !< The energy required to for a layer to entrain - !! to its maximum realizable thickness, in m3 s-3 + !! to its maximum realizable thickness [m3 s-3] integer, dimension(SZI_(G)), intent(out) :: kb !< Index of lightest layer denser than the buffer !! layer, or -1 without a bulk mixed layer. ! Local variables real, dimension(SZI_(G),SZK_(G)) :: & ds_dsp1, & ! coordinate variable (sigma-2) difference across an ! interface divided by the difference across the interface - ! below it (nondimensional) + ! below it [nondim] dsp1_ds, & ! inverse coordinate variable (sigma-2) difference ! across an interface times the difference across the - ! interface above it (nondimensional) - rho_0, & ! Layer potential densities relative to surface pressure (kg/m3) + ! interface above it [nondim] + rho_0, & ! Layer potential densities relative to surface pressure [kg m-3] maxEnt ! maxEnt is the maximum value of entrainment from below (with ! compensating entrainment from above to keep the layer ! density from changing) that will not deplete all of the @@ -709,13 +708,13 @@ subroutine find_TKE_to_Kd(h, tv, dRho_int, N2_lay, j, dt, G, GV, US, CS, & real :: dh_max ! maximum amount of entrainment a layer could ! undergo before entraining all fluid in the layers ! above or below [Z ~> m]. - real :: dRho_lay ! density change across a layer (kg/m3) - real :: Omega2 ! rotation rate squared (1/s2) - real :: G_Rho0 ! gravitation accel divided by Bouss ref density (m4 s-2 kg-1) - real :: I_Rho0 ! inverse of Boussinesq reference density (m3/kg) - real :: I_dt ! 1/dt (1/sec) - real :: H_neglect ! negligibly small thickness (units as h) - real :: hN2pO2 ! h * (N^2 + Omega^2), in m3 s-2 Z-2. + real :: dRho_lay ! density change across a layer [kg m-3] + real :: Omega2 ! rotation rate squared [s-2] + real :: G_Rho0 ! gravitation accel divided by Bouss ref density [m4 s-2 kg-1] + real :: I_Rho0 ! inverse of Boussinesq reference density [m3 kg-1] + real :: I_dt ! 1/dt [s-1] + real :: H_neglect ! negligibly small thickness [H ~> m or kg m-2] + real :: hN2pO2 ! h (N^2 + Omega^2), in [m3 s-2 Z-2 ~> m s-2]. logical :: do_i(SZI_(G)) integer :: i, k, is, ie, nz, i_rem, kmb, kb_min @@ -896,9 +895,9 @@ subroutine find_N2(h, tv, T_f, S_f, fluxes, j, G, GV, US, CS, dRho_int, & dRho_dS ! partial derivative of density wrt saln [kg m-3 ppt-1] real, dimension(SZI_(G)) :: & - pres, & ! pressure at each interface (Pa) - Temp_int, & ! temperature at each interface (degC) - Salin_int, & ! salinity at each interface (PPT) + pres, & ! pressure at each interface [Pa] + Temp_int, & ! temperature at each interface [degC] + Salin_int, & ! salinity at each interface [ppt] drho_bot, & h_amp, & ! The topographic roughness amplitude [Z ~> m]. hb, & ! The thickness of the bottom layer [Z ~> m]. @@ -1065,19 +1064,19 @@ subroutine double_diffusion(tv, h, T_f, S_f, j, G, GV, US, CS, Kd_T_dd, Kd_S_dd) real, dimension(SZI_(G)) :: & dRho_dT, & ! partial derivatives of density wrt temp [kg m-3 degC-1] dRho_dS, & ! partial derivatives of density wrt saln [kg m-3 ppt-1] - pres, & ! pressure at each interface (Pa) - Temp_int, & ! temp and saln at interfaces - Salin_int + pres, & ! pressure at each interface [Pa] + Temp_int, & ! temperature at interfaces [degC] + Salin_int ! Salinity at interfaces [ppt] - real :: alpha_dT ! density difference between layers due to temp diffs (kg/m3) - real :: beta_dS ! density difference between layers due to saln diffs (kg/m3) + real :: alpha_dT ! density difference between layers due to temp diffs [kg m-3] + real :: beta_dS ! density difference between layers due to saln diffs [kg m-3] - real :: Rrho ! vertical density ratio - real :: diff_dd ! factor for double-diffusion (nondim) + real :: Rrho ! vertical density ratio [nondim] + real :: diff_dd ! factor for double-diffusion [nondim] real :: Kd_dd ! The dominant double diffusive diffusivity [Z2 s-1 ~> m2 s-1] real :: prandtl ! flux ratio for diffusive convection regime - real, parameter :: Rrho0 = 1.9 ! limit for double-diffusive density ratio + real, parameter :: Rrho0 = 1.9 ! limit for double-diffusive density ratio [nondim] real :: dsfmax ! max diffusivity in case of salt fingering [Z2 s-1 ~> m2 s-1] real :: Kv_molecular ! molecular viscosity [Z2 s-1 ~> m2 s-1] @@ -1085,8 +1084,8 @@ subroutine double_diffusion(tv, h, T_f, S_f, j, G, GV, US, CS, Kd_T_dd, Kd_S_dd) is = G%isc ; ie = G%iec ; nz = G%ke if (associated(tv%eqn_of_state)) then - dsfmax = US%m_to_Z**2 * 1.e-4 ! max salt fingering diffusivity rescaled to (Z2/sec) - Kv_molecular = US%m_to_Z**2 * 1.5e-6 ! molecular viscosity rescaled to (Z2/sec) + dsfmax = US%m_to_Z**2 * 1.e-4 ! max salt fingering diffusivity rescaled to [Z2 s-1 ~> m2 s-1] + Kv_molecular = US%m_to_Z**2 * 1.5e-6 ! molecular viscosity rescaled to [Z2 s-1 ~> m2 s-1] do i=is,ie pres(i) = 0.0 ; Kd_T_dd(i,1) = 0.0 ; Kd_S_dd(i,1) = 0.0 @@ -1151,7 +1150,7 @@ subroutine add_drag_diffusivity(h, u, v, tv, fluxes, visc, j, TKE_to_Kd, & !! usually (~Rho_0 / (G_Earth * dRho_lay)) !! [Z2 s-1 / m3 s-3 = Z2 s2 m-3 ~> s2 m-1] real, dimension(SZI_(G),SZK_(G)), intent(in) :: maxTKE !< The energy required to for a layer to entrain - !! to its maximum realizable thickness, in m3 s-3 + !! to its maximum realizable thickness [m3 s-3] integer, dimension(SZI_(G)), intent(in) :: kb !< Index of lightest layer denser than the buffer !! layer, or -1 without a bulk mixed layer type(set_diffusivity_CS), pointer :: CS !< Diffusivity control structure @@ -1166,27 +1165,27 @@ subroutine add_drag_diffusivity(h, u, v, tv, fluxes, visc, j, TKE_to_Kd, & ! This routine adds diffusion sustained by flow energy extracted by bottom drag. real, dimension(SZK_(G)+1) :: & - Rint ! coordinate density of an interface (kg/m3) + Rint ! coordinate density of an interface [kg m-3] real, dimension(SZI_(G)) :: & htot, & ! total thickness above or below a layer, or the ! integrated thickness in the BBL [Z ~> m]. - rho_htot, & ! running integral with depth of density (Z kg/m3) + rho_htot, & ! running integral with depth of density [Z kg m-3 ~> kg m-2] gh_sum_top, & ! BBL value of g'h that can be supported by - ! the local ustar, times R0_g (kg/m2) - Rho_top, & ! density at top of the BBL (kg/m3) + ! the local ustar, times R0_g [kg m-2] + Rho_top, & ! density at top of the BBL [kg m-3] TKE, & ! turbulent kinetic energy available to drive - ! bottom-boundary layer mixing in a layer (m3/s3) + ! bottom-boundary layer mixing in a layer [m3 s-3] I2decay ! inverse of twice the TKE decay scale [Z-1 ~> m-1]. - real :: TKE_to_layer ! TKE used to drive mixing in a layer (m3/s3) - real :: TKE_Ray ! TKE from layer Rayleigh drag used to drive mixing in layer (m3/s3) - real :: TKE_here ! TKE that goes into mixing in this layer (m3/s3) - real :: dRl, dRbot ! temporaries holding density differences (kg/m3) - real :: cdrag_sqrt ! square root of the drag coefficient (nondimensional) + real :: TKE_to_layer ! TKE used to drive mixing in a layer [m3 s-3] + real :: TKE_Ray ! TKE from layer Rayleigh drag used to drive mixing in layer [m3 s-3] + real :: TKE_here ! TKE that goes into mixing in this layer [m3 s-3] + real :: dRl, dRbot ! temporaries holding density differences [kg m-3] + real :: cdrag_sqrt ! square root of the drag coefficient [nondim] real :: ustar_h ! value of ustar at a thickness point [Z s-1 ~> m s-1]. real :: absf ! average absolute Coriolis parameter around a thickness point [s-1] - real :: R0_g ! Rho0 / G_Earth (kg s2 Z-1 m-4) - real :: I_rho0 ! 1 / RHO0 + real :: R0_g ! Rho0 / G_Earth [kg s2 Z-1 m-4 ~> kg s2 m-5] + real :: I_rho0 ! 1 / RHO0 [m3 kg-1] real :: delta_Kd ! increment to Kd from the bottom boundary layer mixing [Z2 s-1 ~> m2 s-1]. logical :: Rayleigh_drag ! Set to true if Rayleigh drag velocities ! defined in visc, on the assumption that this @@ -1383,24 +1382,24 @@ subroutine add_LOTW_BBL_diffusivity(h, u, v, tv, fluxes, visc, j, N2_int, & !! boundary layer properies, and related fields. integer, intent(in) :: j !< j-index of row to work on real, dimension(SZI_(G),SZK_(G)+1), & - intent(in) :: N2_int !< Square of Brunt-Vaisala at interfaces (s-2) + intent(in) :: N2_int !< Square of Brunt-Vaisala at interfaces [s-2] type(set_diffusivity_CS), pointer :: CS !< Diffusivity control structure real, dimension(SZI_(G),SZJ_(G),SZK_(G)), & - intent(inout) :: Kd_lay !< Layer net diffusivity (m2 s-1) + intent(inout) :: Kd_lay !< Layer net diffusivity [Z2 s-1 ~> m2 s-1] real, dimension(SZI_(G),SZJ_(G),SZK_(G)+1), & - intent(inout) :: Kd_int !< Interface net diffusivity (m2 s-1) - real, dimension(:,:,:), pointer :: Kd_BBL !< Interface BBL diffusivity (m2 s-1) + intent(inout) :: Kd_int !< Interface net diffusivity [Z2 s-1 ~> m2 s-1] + real, dimension(:,:,:), pointer :: Kd_BBL !< Interface BBL diffusivity [Z2 s-1 ~> m2 s-1] ! Local variables - real :: TKE_column ! net TKE input into the column (m3 s-3) - real :: TKE_to_layer ! TKE used to drive mixing in a layer (m3 s-3) - real :: TKE_Ray ! TKE from a layer Rayleigh drag used to drive mixing in that layer (m3 s-3) - real :: TKE_remaining ! remaining TKE available for mixing in this layer and above (m3 s-3) - real :: TKE_consumed ! TKE used for mixing in this layer (m3 s-3) - real :: TKE_Kd_wall ! TKE associated with unlimited law of the wall mixing (m3 s-3) - real :: cdrag_sqrt ! square root of the drag coefficient (nondimensional) + real :: TKE_column ! net TKE input into the column [m3 s-3] + real :: TKE_to_layer ! TKE used to drive mixing in a layer [m3 s-3] + real :: TKE_Ray ! TKE from a layer Rayleigh drag used to drive mixing in that layer [m3 s-3] + real :: TKE_remaining ! remaining TKE available for mixing in this layer and above [m3 s-3] + real :: TKE_consumed ! TKE used for mixing in this layer [m3 s-3] + real :: TKE_Kd_wall ! TKE associated with unlimited law of the wall mixing [m3 s-3] + real :: cdrag_sqrt ! square root of the drag coefficient [nondim] real :: ustar ! value of ustar at a thickness point [Z s-1 ~> m s-1]. - real :: ustar2 ! square of ustar, for convenience (Z2/s2) + real :: ustar2 ! square of ustar, for convenience [Z2 s-2 ~> m2 s-2] real :: absf ! average absolute value of Coriolis parameter around a thickness point (1/sec) real :: dh, dhm1 ! thickness of layers k and k-1, respecitvely [Z ~> m]. real :: z_bot ! distance to interface k from bottom [Z ~> m]. @@ -1408,10 +1407,10 @@ subroutine add_LOTW_BBL_diffusivity(h, u, v, tv, fluxes, visc, j, N2_int, & real :: total_thickness ! total thickness of water column [Z ~> m]. real :: Idecay ! inverse of decay scale used for "Joule heating" loss of TKE with height [Z-1 ~> m-1]. real :: Kd_wall ! Law of the wall diffusivity [Z2 s-1 ~> m2 s-1]. - real :: Kd_lower ! diffusivity for lower interface (Z2/sec) + real :: Kd_lower ! diffusivity for lower interface [Z2 s-1 ~> m2 s-1] real :: ustar_D ! u* x D [Z2 s-1 ~> m2 s-1]. real :: I_Rho0 ! 1 / rho0 - real :: N2_min ! Minimum value of N2 to use in calculation of TKE_Kd_wall (1/s2) + real :: N2_min ! Minimum value of N2 to use in calculation of TKE_Kd_wall [s-2] logical :: Rayleigh_drag ! Set to true if there are Rayleigh drag velocities defined in visc, on ! the assumption that this extracted energy also drives diapycnal mixing. integer :: i, k, km1 @@ -1449,11 +1448,11 @@ subroutine add_LOTW_BBL_diffusivity(h, u, v, tv, fluxes, visc, j, N2_int, & Idecay = CS%IMax_decay if ((ustar > 0.0) .and. (absf > CS%IMax_decay*ustar)) Idecay = absf / ustar - ! Energy input at the bottom, in m3 s-3. + ! Energy input at the bottom [m3 s-3]. ! (Note that visc%TKE_BBL is in m3 s-3, set in set_BBL_TKE().) ! I am still unsure about sqrt(cdrag) in this expressions - AJA TKE_column = cdrag_sqrt * visc%TKE_BBL(i,j) - ! Add in tidal dissipation energy at the bottom, in m3 s-3. + ! Add in tidal dissipation energy at the bottom [m3 s-3]. ! Note that TKE_tidal is in W m-2. if (associated(fluxes%TKE_tidal)) TKE_column = TKE_column + fluxes%TKE_tidal(i,j) * I_Rho0 TKE_column = CS%BBL_effic * TKE_column ! Only use a fraction of the mechanical dissipation for mixing. @@ -1495,7 +1494,7 @@ subroutine add_LOTW_BBL_diffusivity(h, u, v, tv, fluxes, visc, j, N2_int, & ( ustar_D + absf * ( z_bot * D_minus_z ) ) endif - ! TKE associated with Kd_wall, in m3 s-2. + ! TKE associated with Kd_wall [m3 s-2]. ! This calculation if for the volume spanning the interface. TKE_Kd_wall = US%Z_to_m**3*Kd_wall * 0.5 * (dh + dhm1) * max(N2_int(i,k), N2_min) @@ -1560,7 +1559,7 @@ subroutine add_MLrad_diffusivity(h, fluxes, j, G, GV, US, CS, Kd_lay, TKE_to_Kd, real :: Kd_mlr ! A diffusivity associated with mixed layer turbulence radiation [Z2 s-1 ~> m2 s-1]. real :: C1_6 ! 1/6 real :: Omega2 ! rotation rate squared [s-2]. - real :: z1 ! layer thickness times I_decay (nondim) + real :: z1 ! layer thickness times I_decay [nondim] real :: dzL ! thickness converted to heights [Z ~> m]. real :: I_decay_len2_TKE ! squared inverse decay lengthscale for ! TKE, as used in the mixed layer code [Z-2 ~> m-2]. @@ -1681,17 +1680,17 @@ subroutine set_BBL_TKE(u, v, h, fluxes, visc, G, GV, US, CS) ! integrated thickness in the BBL [Z ~> m]. real, dimension(SZIB_(G)) :: & - uhtot, & ! running integral of u in the BBL (Z m/s) + uhtot, & ! running integral of u in the BBL [Z m s-1 ~> m2 s-1] ustar, & ! bottom boundary layer turbulence speed [Z s-1 ~> m s-1]. - u2_bbl ! square of the mean zonal velocity in the BBL (m2/s2) + u2_bbl ! square of the mean zonal velocity in the BBL [m2 s-2] - real :: vhtot(SZI_(G)) ! running integral of v in the BBL (Z m/sec) + real :: vhtot(SZI_(G)) ! running integral of v in the BBL [Z m s-1 ~> m2 s-1] real, dimension(SZI_(G),SZJB_(G)) :: & vstar, & ! ustar at at v-points [Z s-1 ~> m s-1]. - v2_bbl ! square of average meridional velocity in BBL (m2/s2) + v2_bbl ! square of average meridional velocity in BBL [m2 s-2] - real :: cdrag_sqrt ! square root of the drag coefficient (nondim) + real :: cdrag_sqrt ! square root of the drag coefficient [nondim] real :: hvel ! thickness at velocity points [Z ~> m]. logical :: domore, do_i(SZI_(G)) @@ -1811,31 +1810,18 @@ subroutine set_density_ratios(h, tv, kb, G, GV, CS, j, ds_dsp1, rho_0) real, dimension(SZI_(G),SZK_(G)), intent(out) :: ds_dsp1 !< Coordinate variable (sigma-2) !! difference across an interface divided by !! the difference across the interface below - !! it (nondimensional) + !! it [nondim] real, dimension(SZI_(G),SZK_(G)), & optional, intent(in) :: rho_0 !< Layer potential densities relative to - !! surface press (kg/m3). - -! Arguments: -! (in) h - layer thickness (meter) -! (in) tv - structure containing pointers to any available -! thermodynamic fields; absent fields have NULL ptrs -! (in) kb - index of lightest layer denser than the buffer layer -! (in) G - ocean grid structure -! (in) GV - The ocean's vertical grid structure. -! (in) CS - control structure returned by previous call to diabatic_entrain_init -! (in) j - meridional index upon which to work -! (in) ds_dsp1 - coordinate variable (sigma-2) difference across an -! interface divided by the difference across the interface -! below it (nondimensional) -! (in) rho_0 - layer potential densities relative to surface press (kg/m3) - - real :: g_R0 ! g_R0 is g/Rho (m5 Z-1 kg-1 s-2) + !! surface press [kg m-3]. + + ! Local variables + real :: g_R0 ! g_R0 is g/Rho [m5 Z-1 kg-1 s-2 ~> m4 kg-1 s-2] real :: eps, tmp ! nondimensional temproray variables real :: a(SZK_(G)), a_0(SZK_(G)) ! nondimensional temporary variables real :: p_ref(SZI_(G)) ! an array of tv%P_Ref pressures - real :: Rcv(SZI_(G),SZK_(G)) ! coordinate density in the mixed and buffer layers (kg/m3) - real :: I_Drho ! temporary variable (m3/kg) + real :: Rcv(SZI_(G),SZK_(G)) ! coordinate density in the mixed and buffer layers [kg m-3] + real :: I_Drho ! temporary variable [m3 kg-1] integer :: i, k, k3, is, ie, nz, kmb is = G%isc ; ie = G%iec ; nz = G%ke diff --git a/src/parameterizations/vertical/MOM_shortwave_abs.F90 b/src/parameterizations/vertical/MOM_shortwave_abs.F90 index 991ebc84d5..6666658f08 100644 --- a/src/parameterizations/vertical/MOM_shortwave_abs.F90 +++ b/src/parameterizations/vertical/MOM_shortwave_abs.F90 @@ -89,9 +89,9 @@ subroutine absorbRemainingSW(G, GV, h, opacity_band, nsw, j, dt, H_limit_fluxes, real, dimension(SZI_(G)), optional, intent(inout) :: Ttot !< Depth integrated mixed layer !! temperature [degC H ~> degC m or degC kg m-2] real, dimension(SZI_(G),SZK_(G)), optional, intent(in) :: dSV_dT !< The partial derivative of specific - !! volume with temperature, in m3 kg-1 K-1. + !! volume with temperature [m3 kg-1 degC-1]. real, dimension(SZI_(G),SZK_(G)), optional, intent(inout) :: TKE !< The TKE sink from mixing the heating - !! throughout a layer, in J m-2. + !! throughout a layer [J m-2]. ! Local variables real, dimension(SZI_(G),SZK_(G)) :: & T_chg_above ! A temperature change that will be applied to all the thick @@ -105,7 +105,7 @@ subroutine absorbRemainingSW(G, GV, h, opacity_band, nsw, j, dt, H_limit_fluxes, h_heat, & ! The thickness of the water column that will be heated by ! any remaining shortwave radiation [H ~> m or kg m-2]. T_chg, & ! The temperature change of thick layers due to the remaining - ! shortwave radiation and contributions from T_chg_above, in K. + ! shortwave radiation and contributions from T_chg_above [degC]. Pen_SW_rem ! The sum across all wavelength bands of the penetrating shortwave ! heating that hits the bottom and will be redistributed through ! the water column [degC H ~> degC m or degC kg m-2] diff --git a/src/parameterizations/vertical/MOM_tidal_mixing.F90 b/src/parameterizations/vertical/MOM_tidal_mixing.F90 index b0e59346e4..fdda545d0b 100644 --- a/src/parameterizations/vertical/MOM_tidal_mixing.F90 +++ b/src/parameterizations/vertical/MOM_tidal_mixing.F90 @@ -672,7 +672,7 @@ subroutine calculate_tidal_mixing(h, N2_bot, j, TKE_to_Kd, max_TKE, G, GV, US, C !! usually (~Rho_0 / (G_Earth * dRho_lay)) !! [Z2 s-1 / m3 s-3 = Z2 s2 m-3 ~> s2 m-1] real, dimension(SZI_(G),SZK_(G)), intent(in) :: max_TKE !< The energy required to for a layer to entrain - !! to its maximum realizable thickness, in m3 s-3 + !! to its maximum realizable thickness [m3 s-3] type(tidal_mixing_cs), pointer :: CS !< The control structure for this module real, dimension(SZI_(G),SZJ_(G),SZK_(G)), & intent(inout) :: Kd_lay !< The diapycnal diffusvity in layers [Z2 s-1 ~> m2 s-1]. @@ -942,7 +942,7 @@ subroutine add_int_tide_diffusivity(h, N2_bot, j, TKE_to_Kd, max_TKE, G, GV, US, !! usually (~Rho_0 / (G_Earth * dRho_lay)) !! [Z2 s-1 / m3 s-3 = Z2 s2 m-3 ~> s2 m-1] real, dimension(SZI_(G),SZK_(G)), intent(in) :: max_TKE !< The energy required to for a layer to entrain - !! to its maximum realizable thickness, in m3 s-3 + !! to its maximum realizable thickness [m3 s-3] type(tidal_mixing_cs), pointer :: CS !< The control structure for this module real, dimension(SZI_(G),SZJ_(G),SZK_(G)), & intent(inout) :: Kd_lay !< The diapycnal diffusvity in layers [Z2 s-1 ~> m2 s-1]. diff --git a/src/user/dumbbell_initialization.F90 b/src/user/dumbbell_initialization.F90 index 3c9038a228..54a060841c 100644 --- a/src/user/dumbbell_initialization.F90 +++ b/src/user/dumbbell_initialization.F90 @@ -90,7 +90,7 @@ subroutine dumbbell_initialize_thickness ( h, G, GV, US, param_file, just_read_p real :: eta1D(SZK_(G)+1)! Interface height relative to the sea surface ! positive upward [Z ~> m]. real :: min_thickness ! The minimum layer thicknesses [Z ~> m]. - real :: S_surf, S_range, S_ref, S_light, S_dense ! Various salinities, in ppt. + real :: S_surf, S_range, S_ref, S_light, S_dense ! Various salinities [ppt]. real :: eta_IC_quanta ! The granularity of quantization of intial interface heights [Z-1 ~> m-1]. ! This include declares and sets the variable "version". # include "version_variable.h" diff --git a/src/user/seamount_initialization.F90 b/src/user/seamount_initialization.F90 index ea26d12b58..2c7dc2f530 100644 --- a/src/user/seamount_initialization.F90 +++ b/src/user/seamount_initialization.F90 @@ -93,7 +93,7 @@ subroutine seamount_initialize_thickness ( h, G, GV, US, param_file, just_read_p real :: eta1D(SZK_(G)+1)! Interface height relative to the sea surface ! positive upward [Z ~> m]. real :: min_thickness ! The minimum layer thicknesses [Z ~> m]. - real :: S_surf, S_range, S_ref, S_light, S_dense ! Various salinities, in ppt. + real :: S_surf, S_range, S_ref, S_light, S_dense ! Various salinities [ppt]. real :: eta_IC_quanta ! The granularity of quantization of intial interface heights [Z-1 ~> m-1]. character(len=20) :: verticalCoordinate logical :: just_read ! If true, just read parameters but set nothing.