MOM6
mom_eos_linear::calculate_density_second_derivs_linear Interface Reference

Detailed Description

For a given thermodynamic state, return the second derivatives of density with various combinations of temperature, salinity, and pressure. Note that with a simple linear equation of state these second derivatives are all 0.

Definition at line 47 of file MOM_EOS_linear.F90.

Private functions

subroutine calculate_density_second_derivs_scalar_linear (T, S, pressure, drho_dS_dS, drho_dS_dT, drho_dT_dT, drho_dS_dP, drho_dT_dP)
 This subroutine calculates the five, partial second derivatives of density w.r.t. potential temperature and salinity and pressure which for a linear equation of state should all be 0. More...
 
subroutine calculate_density_second_derivs_array_linear (T, S, pressure, drho_dS_dS, drho_dS_dT, drho_dT_dT, drho_dS_dP, drho_dT_dP, start, npts)
 This subroutine calculates the five, partial second derivatives of density w.r.t. potential temperature and salinity and pressure which for a linear equation of state should all be 0. More...
 

Functions and subroutines

◆ calculate_density_second_derivs_array_linear()

subroutine mom_eos_linear::calculate_density_second_derivs_linear::calculate_density_second_derivs_array_linear ( real, dimension(:), intent(in)  T,
real, dimension(:), intent(in)  S,
real, dimension(:), intent(in)  pressure,
real, dimension(:), intent(out)  drho_dS_dS,
real, dimension(:), intent(out)  drho_dS_dT,
real, dimension(:), intent(out)  drho_dT_dT,
real, dimension(:), intent(out)  drho_dS_dP,
real, dimension(:), intent(out)  drho_dT_dP,
integer, intent(in)  start,
integer, intent(in)  npts 
)
private

This subroutine calculates the five, partial second derivatives of density w.r.t. potential temperature and salinity and pressure which for a linear equation of state should all be 0.

Parameters
[in]tPotential temperature relative to the surface [degC].
[in]sSalinity [PSU].
[in]pressurepressure [Pa].
[out]drho_ds_dsThe second derivative of density with salinity [kg m-3 PSU-2].
[out]drho_ds_dtThe second derivative of density with temperature and salinity [kg m-3 ppt-1 degC-1].
[out]drho_dt_dtThe second derivative of density with temperature [kg m-3 degC-2].
[out]drho_ds_dpThe second derivative of density with salinity and pressure [kg m-3 PSU-1 Pa-1].
[out]drho_dt_dpThe second derivative of density with temperature and pressure [kg m-3 degC-1 Pa-1].
[in]startThe starting point in the arrays.
[in]nptsThe number of values to calculate.

Definition at line 238 of file MOM_EOS_linear.F90.

238  real, dimension(:), intent(in) :: T !< Potential temperature relative to the surface [degC].
239  real, dimension(:), intent(in) :: S !< Salinity [PSU].
240  real, dimension(:), intent(in) :: pressure !< pressure [Pa].
241  real, dimension(:), intent(out) :: drho_dS_dS !< The second derivative of density with
242  !! salinity [kg m-3 PSU-2].
243  real, dimension(:), intent(out) :: drho_dS_dT !< The second derivative of density with
244  !! temperature and salinity [kg m-3 ppt-1 degC-1].
245  real, dimension(:), intent(out) :: drho_dT_dT !< The second derivative of density with
246  !! temperature [kg m-3 degC-2].
247  real, dimension(:), intent(out) :: drho_dS_dP !< The second derivative of density with
248  !! salinity and pressure [kg m-3 PSU-1 Pa-1].
249  real, dimension(:), intent(out) :: drho_dT_dP !< The second derivative of density with
250  !! temperature and pressure [kg m-3 degC-1 Pa-1].
251  integer, intent(in) :: start !< The starting point in the arrays.
252  integer, intent(in) :: npts !< The number of values to calculate.
253  ! Local variables
254  integer :: j
255  do j=start,start+npts-1
256  drho_ds_ds(j) = 0.
257  drho_ds_dt(j) = 0.
258  drho_dt_dt(j) = 0.
259  drho_ds_dp(j) = 0.
260  drho_dt_dp(j) = 0.
261  enddo
262 

◆ calculate_density_second_derivs_scalar_linear()

subroutine mom_eos_linear::calculate_density_second_derivs_linear::calculate_density_second_derivs_scalar_linear ( real, intent(in)  T,
real, intent(in)  S,
real, intent(in)  pressure,
real, intent(out)  drho_dS_dS,
real, intent(out)  drho_dS_dT,
real, intent(out)  drho_dT_dT,
real, intent(out)  drho_dS_dP,
real, intent(out)  drho_dT_dP 
)
private

This subroutine calculates the five, partial second derivatives of density w.r.t. potential temperature and salinity and pressure which for a linear equation of state should all be 0.

Parameters
[in]tPotential temperature relative to the surface [degC].
[in]sSalinity [PSU].
[in]pressurepressure [Pa].
[out]drho_ds_dsThe second derivative of density with salinity [kg m-3 PSU-2].
[out]drho_ds_dtThe second derivative of density with temperature and salinity [kg m-3 ppt-1 degC-1].
[out]drho_dt_dtThe second derivative of density with temperature [kg m-3 degC-2].
[out]drho_ds_dpThe second derivative of density with salinity and pressure [kg m-3 PSU-1 Pa-1].
[out]drho_dt_dpThe second derivative of density with temperature and pressure [kg m-3 degC-1 Pa-1].

Definition at line 212 of file MOM_EOS_linear.F90.

212  real, intent(in) :: T !< Potential temperature relative to the surface [degC].
213  real, intent(in) :: S !< Salinity [PSU].
214  real, intent(in) :: pressure !< pressure [Pa].
215  real, intent(out) :: drho_dS_dS !< The second derivative of density with
216  !! salinity [kg m-3 PSU-2].
217  real, intent(out) :: drho_dS_dT !< The second derivative of density with
218  !! temperature and salinity [kg m-3 ppt-1 degC-1].
219  real, intent(out) :: drho_dT_dT !< The second derivative of density with
220  !! temperature [kg m-3 degC-2].
221  real, intent(out) :: drho_dS_dP !< The second derivative of density with
222  !! salinity and pressure [kg m-3 PSU-1 Pa-1].
223  real, intent(out) :: drho_dT_dP !< The second derivative of density with
224  !! temperature and pressure [kg m-3 degC-1 Pa-1].
225 
226  drho_ds_ds = 0.
227  drho_ds_dt = 0.
228  drho_dt_dt = 0.
229  drho_ds_dp = 0.
230  drho_dt_dp = 0.
231 

The documentation for this interface was generated from the following file: