38 real (r8),
intent(in) :: sa, ct
39 real (r8),
intent(out),
optional :: eta_sa_sa, eta_sa_ct, eta_ct_ct
41 real (r8) :: abs_pt, ct_pt, ct_sa, pt, ct_ct
43 integer,
parameter :: n0=0, n1=1, n2=2
44 real (r8),
parameter :: pr0 = 0.0_r8
51 ct_ct = -
gsw_cp0/(ct_pt*abs_pt*abs_pt)
53 if (
present(eta_sa_ct) .or.
present(eta_sa_sa))
then 55 ct_sa = (
gsw_gibbs(n1,n0,n0,sa,pt,pr0) - &
58 if (
present(eta_sa_ct)) eta_sa_ct = -ct_sa*ct_ct
60 if (
present(eta_sa_sa)) eta_sa_sa = -
gsw_gibbs(n2,n0,n0,sa,pt,pr0)/abs_pt +&
64 if (
present(eta_ct_ct)) eta_ct_ct = ct_ct
real(r8), parameter gsw_cp0
real(r8), parameter gsw_t0
elemental subroutine gsw_entropy_second_derivatives(sa, ct, eta_sa_sa, eta_sa_ct, eta_ct_ct)