MOM6
Data Types | Modules | Functions/Subroutines | Variables
MOM_EOS.F90 File Reference
#include <MOM_memory.h>
#include "version_variable.h"

Go to the source code of this file.

Data Types

interface  mom_eos::calculate_density
 Calculates density of sea water from T, S and P. More...
 
interface  mom_eos::calculate_spec_vol
 Calculates specific volume of sea water from T, S and P. More...
 
interface  mom_eos::calculate_density_derivs
 Calculate the derivatives of density with temperature and salinity from T, S, and P. More...
 
interface  mom_eos::calculate_specific_vol_derivs
 Calculate the derivatives of specific volume with temperature and salinity from T, S, and P. More...
 
interface  mom_eos::calculate_density_second_derivs
 Calculates the second derivatives of density with various combinations of temperature, salinity, and pressure from T, S and P. More...
 
interface  mom_eos::calculate_tfreeze
 Calculates the freezing point of sea water from T, S and P. More...
 
interface  mom_eos::calculate_compress
 Calculates the compressibility of water from T, S, and P. More...
 
type  mom_eos::eos_type
 A control structure for the equation of state. More...
 

Modules

module  mom_eos
 Provides subroutines for quantities specific to the equation of state.
 

Functions/Subroutines

subroutine mom_eos::calculate_density_scalar (T, S, pressure, rho, EOS, rho_ref, scale)
 Calls the appropriate subroutine to calculate density of sea water for scalar inputs. If rho_ref is present, the anomaly with respect to rho_ref is returned. The pressure and density can be rescaled with the US. If both the US and scale arguments are present the density scaling uses the product of the two scaling factors. More...
 
subroutine mom_eos::calculate_stanley_density_scalar (T, S, pressure, Tvar, TScov, Svar, rho, EOS, rho_ref, scale)
 Calls the appropriate subroutine to calculate density of sea water for scalar inputs including the variance of T, S and covariance of T-S. The calculation uses only the second order correction in a series as discussed in Stanley et al., 2020. If rho_ref is present, the anomaly with respect to rho_ref is returned. The density can be rescaled using rho_ref. More...
 
subroutine mom_eos::calculate_density_array (T, S, pressure, rho, start, npts, EOS, rho_ref, scale)
 Calls the appropriate subroutine to calculate the density of sea water for 1-D array inputs. If rho_ref is present, the anomaly with respect to rho_ref is returned. More...
 
subroutine mom_eos::calculate_stanley_density_array (T, S, pressure, Tvar, TScov, Svar, rho, start, npts, EOS, rho_ref, scale)
 Calls the appropriate subroutine to calculate the density of sea water for 1-D array inputs including the variance of T, S and covariance of T-S. The calculation uses only the second order correction in a series as discussed in Stanley et al., 2020. If rho_ref is present, the anomaly with respect to rho_ref is returned. More...
 
subroutine mom_eos::calculate_density_1d (T, S, pressure, rho, EOS, dom, rho_ref, scale)
 Calls the appropriate subroutine to calculate the density of sea water for 1-D array inputs, potentially limiting the domain of indices that are worked on. If rho_ref is present, the anomaly with respect to rho_ref is returned. More...
 
subroutine mom_eos::calculate_stanley_density_1d (T, S, pressure, Tvar, TScov, Svar, rho, EOS, dom, rho_ref, scale)
 Calls the appropriate subroutine to calculate the density of sea water for 1-D array inputs including the variance of T, S and covariance of T-S, potentially limiting the domain of indices that are worked on. The calculation uses only the second order correction in a series as discussed in Stanley et al., 2020. If rho_ref is present, the anomaly with respect to rho_ref is returned. More...
 
subroutine mom_eos::calculate_spec_vol_array (T, S, pressure, specvol, start, npts, EOS, spv_ref, scale)
 Calls the appropriate subroutine to calculate the specific volume of sea water for 1-D array inputs. More...
 
subroutine mom_eos::calc_spec_vol_scalar (T, S, pressure, specvol, EOS, spv_ref, scale)
 Calls the appropriate subroutine to calculate specific volume of sea water for scalar inputs. More...
 
subroutine mom_eos::calc_spec_vol_1d (T, S, pressure, specvol, EOS, dom, spv_ref, scale)
 Calls the appropriate subroutine to calculate the specific volume of sea water for 1-D array inputs, potentially limiting the domain of indices that are worked on. More...
 
subroutine mom_eos::calculate_tfreeze_scalar (S, pressure, T_fr, EOS, pres_scale)
 Calls the appropriate subroutine to calculate the freezing point for scalar inputs. More...
 
subroutine mom_eos::calculate_tfreeze_array (S, pressure, T_fr, start, npts, EOS, pres_scale)
 Calls the appropriate subroutine to calculate the freezing point for a 1-D array. More...
 
subroutine mom_eos::calculate_density_derivs_array (T, S, pressure, drho_dT, drho_dS, start, npts, EOS, scale)
 Calls the appropriate subroutine to calculate density derivatives for 1-D array inputs. More...
 
subroutine mom_eos::calculate_density_derivs_1d (T, S, pressure, drho_dT, drho_dS, EOS, dom, scale)
 Calls the appropriate subroutine to calculate density derivatives for 1-D array inputs. More...
 
subroutine mom_eos::calculate_density_derivs_scalar (T, S, pressure, drho_dT, drho_dS, EOS, scale)
 Calls the appropriate subroutines to calculate density derivatives by promoting a scalar to a one-element array. More...
 
subroutine mom_eos::calculate_density_second_derivs_array (T, S, pressure, drho_dS_dS, drho_dS_dT, drho_dT_dT, drho_dS_dP, drho_dT_dP, start, npts, EOS, scale)
 Calls the appropriate subroutine to calculate density second derivatives for 1-D array inputs. More...
 
subroutine mom_eos::calculate_density_second_derivs_scalar (T, S, pressure, drho_dS_dS, drho_dS_dT, drho_dT_dT, drho_dS_dP, drho_dT_dP, EOS, scale)
 Calls the appropriate subroutine to calculate density second derivatives for scalar nputs. More...
 
subroutine mom_eos::calculate_spec_vol_derivs_array (T, S, pressure, dSV_dT, dSV_dS, start, npts, EOS)
 Calls the appropriate subroutine to calculate specific volume derivatives for an array. More...
 
subroutine mom_eos::calc_spec_vol_derivs_1d (T, S, pressure, dSV_dT, dSV_dS, EOS, dom, scale)
 Calls the appropriate subroutine to calculate specific volume derivatives for 1-d array inputs, potentially limiting the domain of indices that are worked on. More...
 
subroutine mom_eos::calculate_compress_array (T, S, press, rho, drho_dp, start, npts, EOS)
 Calls the appropriate subroutine to calculate the density and compressibility for 1-D array inputs. If US is present, the units of the inputs and outputs are rescaled. More...
 
subroutine mom_eos::calculate_compress_scalar (T, S, pressure, rho, drho_dp, EOS)
 Calculate density and compressibility for a scalar. This just promotes the scalar to an array with a singleton dimension and calls calculate_compress_array. If US is present, the units of the inputs and outputs are rescaled. More...
 
integer function, dimension(2), public mom_eos::eos_domain (HI, halo)
 This subroutine returns a two point integer array indicating the domain of i-indices to work on in EOS calls based on information from a hor_index type. More...
 
subroutine, public mom_eos::analytic_int_specific_vol_dp (T, S, p_t, p_b, alpha_ref, HI, EOS, dza, intp_dza, intx_dza, inty_dza, halo_size, bathyP, dP_tiny, useMassWghtInterp)
 Calls the appropriate subroutine to calculate analytical and nearly-analytical integrals in pressure across layers of geopotential anomalies, which are required for calculating the finite-volume form pressure accelerations in a non-Boussinesq model. There are essentially no free assumptions, apart from the use of Boole's rule to do the horizontal integrals, and from a truncation in the series for log(1-eps/1+eps) that assumes that |eps| < 0.34. More...
 
subroutine, public mom_eos::analytic_int_density_dz (T, S, z_t, z_b, rho_ref, rho_0, G_e, HI, EOS, dpa, intz_dpa, intx_dpa, inty_dpa, bathyT, dz_neglect, useMassWghtInterp)
 This subroutine calculates analytical and nearly-analytical integrals of pressure anomalies across layers, which are required for calculating the finite-volume form pressure accelerations in a Boussinesq model. More...
 
logical function, public mom_eos::query_compressible (EOS)
 Returns true if the equation of state is compressible (i.e. has pressure dependence) More...
 
subroutine, public mom_eos::eos_init (param_file, EOS, US)
 Initializes EOS_type by allocating and reading parameters. More...
 
subroutine, public mom_eos::eos_manual_init (EOS, form_of_EOS, form_of_TFreeze, EOS_quadrature, Compressible, Rho_T0_S0, drho_dT, dRho_dS, TFr_S0_P0, dTFr_dS, dTFr_dp)
 Manually initialized an EOS type (intended for unit testing of routines which need a specific EOS) More...
 
subroutine, public mom_eos::eos_allocate (EOS)
 Allocates EOS_type. More...
 
subroutine, public mom_eos::eos_end (EOS)
 Deallocates EOS_type. More...
 
subroutine, public mom_eos::eos_use_linear (Rho_T0_S0, dRho_dT, dRho_dS, EOS, use_quadrature)
 Set equation of state structure (EOS) to linear with given coefficients. More...
 
subroutine, public mom_eos::convert_temp_salt_for_teos10 (T, S, HI, kd, mask_z, EOS)
 Convert T&S to Absolute Salinity and Conservative Temperature if using TEOS10. More...
 
logical function, public mom_eos::eos_quadrature (EOS)
 Return value of EOS_quadrature. More...
 
subroutine, public mom_eos::extract_member_eos (EOS, form_of_EOS, form_of_TFreeze, EOS_quadrature, Compressible, Rho_T0_S0, drho_dT, dRho_dS, TFr_S0_P0, dTFr_dS, dTFr_dp)
 Extractor routine for the EOS type if the members need to be accessed outside this module. More...
 

Variables

integer, parameter, public mom_eos::eos_linear = 1
 A named integer specifying an equation of state. More...
 
integer, parameter, public mom_eos::eos_unesco = 2
 A named integer specifying an equation of state. More...
 
integer, parameter, public mom_eos::eos_wright = 3
 A named integer specifying an equation of state. More...
 
integer, parameter, public mom_eos::eos_teos10 = 4
 A named integer specifying an equation of state. More...
 
integer, parameter, public mom_eos::eos_nemo = 5
 A named integer specifying an equation of state. More...
 
character *(10), parameter mom_eos::eos_linear_string = "LINEAR"
 A string for specifying the equation of state. More...
 
character *(10), parameter mom_eos::eos_unesco_string = "UNESCO"
 A string for specifying the equation of state. More...
 
character *(10), parameter mom_eos::eos_wright_string = "WRIGHT"
 A string for specifying the equation of state. More...
 
character *(10), parameter mom_eos::eos_teos10_string = "TEOS10"
 A string for specifying the equation of state. More...
 
character *(10), parameter mom_eos::eos_nemo_string = "NEMO"
 A string for specifying the equation of state. More...
 
character *(10), parameter mom_eos::eos_default = EOS_WRIGHT_STRING
 The default equation of state. More...
 
integer, parameter mom_eos::tfreeze_linear = 1
 A named integer specifying a freezing point expression. More...
 
integer, parameter mom_eos::tfreeze_millero = 2
 A named integer specifying a freezing point expression. More...
 
integer, parameter mom_eos::tfreeze_teos10 = 3
 A named integer specifying a freezing point expression. More...
 
character *(10), parameter mom_eos::tfreeze_linear_string = "LINEAR"
 A string for specifying the freezing point expression. More...
 
character *(10), parameter mom_eos::tfreeze_millero_string = "MILLERO_78"
 A string for specifying freezing point expression. More...
 
character *(10), parameter mom_eos::tfreeze_teos10_string = "TEOS10"
 A string for specifying the freezing point expression. More...
 
character *(10), parameter mom_eos::tfreeze_default = TFREEZE_LINEAR_STRING
 The default freezing point expression. More...