\hypertarget{interfacemom__eos__teos10_1_1calculate__density__second__derivs__teos10}{}\section{mom\+\_\+eos\+\_\+teos10\+::calculate\+\_\+density\+\_\+second\+\_\+derivs\+\_\+teos10 Interface Reference}
\label{interfacemom__eos__teos10_1_1calculate__density__second__derivs__teos10}\index{mom\_eos\_teos10::calculate\_density\_second\_derivs\_teos10@{mom\_eos\_teos10::calculate\_density\_second\_derivs\_teos10}}


\subsection{Detailed Description}
For a given thermodynamic state, return the second derivatives of density with various combinations of conservative temperature, absolute salinity, and pressure, using the T\+E\+O\+S10 expressions. 

Definition at line 47 of file M\+O\+M\+\_\+\+E\+O\+S\+\_\+\+T\+E\+O\+S10.\+F90.

\subsection*{Private functions}
\begin{DoxyCompactItemize}
\item 
subroutine \mbox{\hyperlink{interfacemom__eos__teos10_1_1calculate__density__second__derivs__teos10_aa000cb77e5fa422e3d9cb7033c6fe4f4}{calculate\+\_\+density\+\_\+second\+\_\+derivs\+\_\+scalar\+\_\+teos10}} (T, S, pressure, drho\+\_\+d\+S\+\_\+dS, drho\+\_\+d\+S\+\_\+dT, drho\+\_\+d\+T\+\_\+dT, drho\+\_\+d\+S\+\_\+dP, drho\+\_\+d\+T\+\_\+dP)
\begin{DoxyCompactList}\small\item\em Calculate the 5 second derivatives of the equation of state for scalar inputs. \end{DoxyCompactList}\item 
subroutine \mbox{\hyperlink{interfacemom__eos__teos10_1_1calculate__density__second__derivs__teos10_ac2cb9136a203096cf2e1c32a177fcf51}{calculate\+\_\+density\+\_\+second\+\_\+derivs\+\_\+array\+\_\+teos10}} (T, S, pressure, drho\+\_\+d\+S\+\_\+dS, drho\+\_\+d\+S\+\_\+dT, drho\+\_\+d\+T\+\_\+dT, drho\+\_\+d\+S\+\_\+dP, drho\+\_\+d\+T\+\_\+dP, start, npts)
\begin{DoxyCompactList}\small\item\em Calculate the 5 second derivatives of the equation of state for scalar inputs. \end{DoxyCompactList}\end{DoxyCompactItemize}


\subsection{Detailed Description}
For a given thermodynamic state, return the second derivatives of density with various combinations of conservative temperature, absolute salinity, and pressure, using the T\+E\+O\+S10 expressions. 

Definition at line 47 of file M\+O\+M\+\_\+\+E\+O\+S\+\_\+\+T\+E\+O\+S10.\+F90.



\subsection{Functions and subroutines}
\mbox{\Hypertarget{interfacemom__eos__teos10_1_1calculate__density__second__derivs__teos10_ac2cb9136a203096cf2e1c32a177fcf51}\label{interfacemom__eos__teos10_1_1calculate__density__second__derivs__teos10_ac2cb9136a203096cf2e1c32a177fcf51}} 
\index{mom\_eos\_teos10::calculate\_density\_second\_derivs\_teos10@{mom\_eos\_teos10::calculate\_density\_second\_derivs\_teos10}!calculate\_density\_second\_derivs\_array\_teos10@{calculate\_density\_second\_derivs\_array\_teos10}}
\index{calculate\_density\_second\_derivs\_array\_teos10@{calculate\_density\_second\_derivs\_array\_teos10}!mom\_eos\_teos10::calculate\_density\_second\_derivs\_teos10@{mom\_eos\_teos10::calculate\_density\_second\_derivs\_teos10}}
\subsubsection{\texorpdfstring{calculate\_density\_second\_derivs\_array\_teos10()}{calculate\_density\_second\_derivs\_array\_teos10()}}
{\footnotesize\ttfamily subroutine mom\+\_\+eos\+\_\+teos10\+::calculate\+\_\+density\+\_\+second\+\_\+derivs\+\_\+teos10\+::calculate\+\_\+density\+\_\+second\+\_\+derivs\+\_\+array\+\_\+teos10 (\begin{DoxyParamCaption}\item[{real, dimension(\+:), intent(in)}]{T,  }\item[{real, dimension(\+:), intent(in)}]{S,  }\item[{real, dimension(\+:), intent(in)}]{pressure,  }\item[{real, dimension(\+:), intent(out)}]{drho\+\_\+d\+S\+\_\+dS,  }\item[{real, dimension(\+:), intent(out)}]{drho\+\_\+d\+S\+\_\+dT,  }\item[{real, dimension(\+:), intent(out)}]{drho\+\_\+d\+T\+\_\+dT,  }\item[{real, dimension(\+:), intent(out)}]{drho\+\_\+d\+S\+\_\+dP,  }\item[{real, dimension(\+:), intent(out)}]{drho\+\_\+d\+T\+\_\+dP,  }\item[{integer, intent(in)}]{start,  }\item[{integer, intent(in)}]{npts }\end{DoxyParamCaption})\hspace{0.3cm}{\ttfamily [private]}}



Calculate the 5 second derivatives of the equation of state for scalar inputs. 


\begin{DoxyParams}[1]{Parameters}
\mbox{\texttt{ in}}  & {\em t} & Conservative temperature \mbox{[}degC\mbox{]} \\
\hline
\mbox{\texttt{ in}}  & {\em s} & Absolute Salinity \mbox{[}g kg-\/1\mbox{]} \\
\hline
\mbox{\texttt{ in}}  & {\em pressure} & pressure \mbox{[}Pa\mbox{]}. \\
\hline
\mbox{\texttt{ out}}  & {\em drho\+\_\+ds\+\_\+ds} & Partial derivative of beta with respect to S \\
\hline
\mbox{\texttt{ out}}  & {\em drho\+\_\+ds\+\_\+dt} & Partial derivative of beta with resepct to T \\
\hline
\mbox{\texttt{ out}}  & {\em drho\+\_\+dt\+\_\+dt} & Partial derivative of alpha with respect to T \\
\hline
\mbox{\texttt{ out}}  & {\em drho\+\_\+ds\+\_\+dp} & Partial derivative of beta with respect to pressure \\
\hline
\mbox{\texttt{ out}}  & {\em drho\+\_\+dt\+\_\+dp} & Partial derivative of alpha with respect to pressure \\
\hline
\mbox{\texttt{ in}}  & {\em start} & The starting point in the arrays. \\
\hline
\mbox{\texttt{ in}}  & {\em npts} & The number of values to calculate. \\
\hline
\end{DoxyParams}


Definition at line 277 of file M\+O\+M\+\_\+\+E\+O\+S\+\_\+\+T\+E\+O\+S10.\+F90.


\begin{DoxyCode}{0}
\DoxyCodeLine{277 \textcolor{keywordtype}{  real}, \textcolor{keywordtype}{dimension(:)}, \textcolor{keywordtype}{intent(in)}     :: T\textcolor{comment}{          !< Conservative temperature [degC]}}
\DoxyCodeLine{278 \textcolor{keywordtype}{  real}, \textcolor{keywordtype}{dimension(:)}, \textcolor{keywordtype}{intent(in)}     :: S\textcolor{comment}{          !< Absolute Salinity [g kg-1]}}
\DoxyCodeLine{279 \textcolor{keywordtype}{  real}, \textcolor{keywordtype}{dimension(:)}, \textcolor{keywordtype}{intent(in)}     :: pressure\textcolor{comment}{   !< pressure [Pa].}}
\DoxyCodeLine{280 \textcolor{keywordtype}{  real}, \textcolor{keywordtype}{dimension(:)}, \textcolor{keywordtype}{intent(out)}    :: drho\_dS\_dS\textcolor{comment}{ !< Partial derivative of beta with respect to S}}
\DoxyCodeLine{281 \textcolor{keywordtype}{  real}, \textcolor{keywordtype}{dimension(:)}, \textcolor{keywordtype}{intent(out)}    :: drho\_dS\_dT\textcolor{comment}{ !< Partial derivative of beta with resepct to T}}
\DoxyCodeLine{282 \textcolor{keywordtype}{  real}, \textcolor{keywordtype}{dimension(:)}, \textcolor{keywordtype}{intent(out)}    :: drho\_dT\_dT\textcolor{comment}{ !< Partial derivative of alpha with respect to T}}
\DoxyCodeLine{283 \textcolor{keywordtype}{  real}, \textcolor{keywordtype}{dimension(:)}, \textcolor{keywordtype}{intent(out)}    :: drho\_dS\_dP\textcolor{comment}{ !< Partial derivative of beta with respect to pressure}}
\DoxyCodeLine{284 \textcolor{keywordtype}{  real}, \textcolor{keywordtype}{dimension(:)}, \textcolor{keywordtype}{intent(out)}    :: drho\_dT\_dP\textcolor{comment}{ !< Partial derivative of alpha with respect to pressure}}
\DoxyCodeLine{285   \textcolor{keywordtype}{integer}, \textcolor{keywordtype}{intent(in)}  :: start\textcolor{comment}{    !< The starting point in the arrays.}}
\DoxyCodeLine{286   \textcolor{keywordtype}{integer}, \textcolor{keywordtype}{intent(in)}  :: npts\textcolor{comment}{     !< The number of values to calculate.}}
\DoxyCodeLine{287 }
\DoxyCodeLine{288   \textcolor{comment}{! Local variables}}
\DoxyCodeLine{289 \textcolor{keywordtype}{  real} :: zs, zt, zp}
\DoxyCodeLine{290   \textcolor{keywordtype}{integer} :: j}
\DoxyCodeLine{291 }
\DoxyCodeLine{292   \textcolor{keywordflow}{do} j=start,start+npts-1}
\DoxyCodeLine{293     \textcolor{comment}{!Conversions}}
\DoxyCodeLine{294     zs = s(j) \textcolor{comment}{!gsw\_sr\_from\_sp(S)       !Convert practical salinity to absolute salinity}}
\DoxyCodeLine{295     zt = t(j) \textcolor{comment}{!gsw\_ct\_from\_pt(S,T)  !Convert potantial temp to conservative temp}}
\DoxyCodeLine{296     zp = pressure(j)* pa2db         \textcolor{comment}{!Convert pressure from Pascal to decibar}}
\DoxyCodeLine{297     \textcolor{keywordflow}{if} (s(j) < -1.0e-10) \textcolor{keywordflow}{then} ; \textcolor{comment}{!Can we assume safely that this is a missing value?}}
\DoxyCodeLine{298       drho\_ds\_ds(j) = 0.0 ; drho\_ds\_dt(j) = 0.0 ; drho\_dt\_dt(j) = 0.0}
\DoxyCodeLine{299       drho\_ds\_dp(j) = 0.0 ; drho\_dt\_dp(j) = 0.0}
\DoxyCodeLine{300     \textcolor{keywordflow}{else}}
\DoxyCodeLine{301       \textcolor{keyword}{call }gsw\_rho\_second\_derivatives(zs, zt, zp, rho\_sa\_sa=drho\_ds\_ds(j), rho\_sa\_ct=drho\_ds\_dt(j), \&}
\DoxyCodeLine{302                                       rho\_ct\_ct=drho\_dt\_dt(j), rho\_sa\_p=drho\_ds\_dp(j), rho\_ct\_p=drho\_dt\_dp(j))}
\DoxyCodeLine{303 \textcolor{keywordflow}{    endif}}
\DoxyCodeLine{304 \textcolor{keywordflow}{  enddo}}
\DoxyCodeLine{305 }

\end{DoxyCode}
\mbox{\Hypertarget{interfacemom__eos__teos10_1_1calculate__density__second__derivs__teos10_aa000cb77e5fa422e3d9cb7033c6fe4f4}\label{interfacemom__eos__teos10_1_1calculate__density__second__derivs__teos10_aa000cb77e5fa422e3d9cb7033c6fe4f4}} 
\index{mom\_eos\_teos10::calculate\_density\_second\_derivs\_teos10@{mom\_eos\_teos10::calculate\_density\_second\_derivs\_teos10}!calculate\_density\_second\_derivs\_scalar\_teos10@{calculate\_density\_second\_derivs\_scalar\_teos10}}
\index{calculate\_density\_second\_derivs\_scalar\_teos10@{calculate\_density\_second\_derivs\_scalar\_teos10}!mom\_eos\_teos10::calculate\_density\_second\_derivs\_teos10@{mom\_eos\_teos10::calculate\_density\_second\_derivs\_teos10}}
\subsubsection{\texorpdfstring{calculate\_density\_second\_derivs\_scalar\_teos10()}{calculate\_density\_second\_derivs\_scalar\_teos10()}}
{\footnotesize\ttfamily subroutine mom\+\_\+eos\+\_\+teos10\+::calculate\+\_\+density\+\_\+second\+\_\+derivs\+\_\+teos10\+::calculate\+\_\+density\+\_\+second\+\_\+derivs\+\_\+scalar\+\_\+teos10 (\begin{DoxyParamCaption}\item[{real, intent(in)}]{T,  }\item[{real, intent(in)}]{S,  }\item[{real, intent(in)}]{pressure,  }\item[{real, intent(out)}]{drho\+\_\+d\+S\+\_\+dS,  }\item[{real, intent(out)}]{drho\+\_\+d\+S\+\_\+dT,  }\item[{real, intent(out)}]{drho\+\_\+d\+T\+\_\+dT,  }\item[{real, intent(out)}]{drho\+\_\+d\+S\+\_\+dP,  }\item[{real, intent(out)}]{drho\+\_\+d\+T\+\_\+dP }\end{DoxyParamCaption})\hspace{0.3cm}{\ttfamily [private]}}



Calculate the 5 second derivatives of the equation of state for scalar inputs. 


\begin{DoxyParams}[1]{Parameters}
\mbox{\texttt{ in}}  & {\em t} & Conservative temperature \mbox{[}degC\mbox{]} \\
\hline
\mbox{\texttt{ in}}  & {\em s} & Absolute Salinity \mbox{[}g kg-\/1\mbox{]} \\
\hline
\mbox{\texttt{ in}}  & {\em pressure} & pressure \mbox{[}Pa\mbox{]}. \\
\hline
\mbox{\texttt{ out}}  & {\em drho\+\_\+ds\+\_\+ds} & Partial derivative of beta with respect to S \\
\hline
\mbox{\texttt{ out}}  & {\em drho\+\_\+ds\+\_\+dt} & Partial derivative of beta with resepct to T \\
\hline
\mbox{\texttt{ out}}  & {\em drho\+\_\+dt\+\_\+dt} & Partial derivative of alpha with respect to T \\
\hline
\mbox{\texttt{ out}}  & {\em drho\+\_\+ds\+\_\+dp} & Partial derivative of beta with respect to pressure \\
\hline
\mbox{\texttt{ out}}  & {\em drho\+\_\+dt\+\_\+dp} & Partial derivative of alpha with respect to pressure \\
\hline
\end{DoxyParams}


Definition at line 252 of file M\+O\+M\+\_\+\+E\+O\+S\+\_\+\+T\+E\+O\+S10.\+F90.


\begin{DoxyCode}{0}
\DoxyCodeLine{252 \textcolor{keywordtype}{  real}, \textcolor{keywordtype}{intent(in)}     :: T\textcolor{comment}{          !< Conservative temperature [degC]}}
\DoxyCodeLine{253 \textcolor{keywordtype}{  real}, \textcolor{keywordtype}{intent(in)}     :: S\textcolor{comment}{          !< Absolute Salinity [g kg-1]}}
\DoxyCodeLine{254 \textcolor{keywordtype}{  real}, \textcolor{keywordtype}{intent(in)}     :: pressure\textcolor{comment}{   !< pressure [Pa].}}
\DoxyCodeLine{255 \textcolor{keywordtype}{  real}, \textcolor{keywordtype}{intent(out)}    :: drho\_dS\_dS\textcolor{comment}{ !< Partial derivative of beta with respect to S}}
\DoxyCodeLine{256 \textcolor{keywordtype}{  real}, \textcolor{keywordtype}{intent(out)}    :: drho\_dS\_dT\textcolor{comment}{ !< Partial derivative of beta with resepct to T}}
\DoxyCodeLine{257 \textcolor{keywordtype}{  real}, \textcolor{keywordtype}{intent(out)}    :: drho\_dT\_dT\textcolor{comment}{ !< Partial derivative of alpha with respect to T}}
\DoxyCodeLine{258 \textcolor{keywordtype}{  real}, \textcolor{keywordtype}{intent(out)}    :: drho\_dS\_dP\textcolor{comment}{ !< Partial derivative of beta with respect to pressure}}
\DoxyCodeLine{259 \textcolor{keywordtype}{  real}, \textcolor{keywordtype}{intent(out)}    :: drho\_dT\_dP\textcolor{comment}{ !< Partial derivative of alpha with respect to pressure}}
\DoxyCodeLine{260 }
\DoxyCodeLine{261   \textcolor{comment}{! Local variables}}
\DoxyCodeLine{262 \textcolor{keywordtype}{  real} :: zs, zt, zp}
\DoxyCodeLine{263 }
\DoxyCodeLine{264   \textcolor{comment}{!Conversions}}
\DoxyCodeLine{265   zs = s \textcolor{comment}{!gsw\_sr\_from\_sp(S)       !Convert practical salinity to absolute salinity}}
\DoxyCodeLine{266   zt = t \textcolor{comment}{!gsw\_ct\_from\_pt(S,T)  !Convert potantial temp to conservative temp}}
\DoxyCodeLine{267   zp = pressure* pa2db         \textcolor{comment}{!Convert pressure from Pascal to decibar}}
\DoxyCodeLine{268   \textcolor{keywordflow}{if} (s < -1.0e-10) \textcolor{keywordflow}{return} \textcolor{comment}{!Can we assume safely that this is a missing value?}}
\DoxyCodeLine{269   \textcolor{keyword}{call }gsw\_rho\_second\_derivatives(zs, zt, zp, rho\_sa\_sa=drho\_ds\_ds, rho\_sa\_ct=drho\_ds\_dt, \&}
\DoxyCodeLine{270                                      rho\_ct\_ct=drho\_dt\_dt, rho\_sa\_p=drho\_ds\_dp, rho\_ct\_p=drho\_dt\_dp)}
\DoxyCodeLine{271 }

\end{DoxyCode}


The documentation for this interface was generated from the following file\+:\begin{DoxyCompactItemize}
\item 
/home/cermak/src/\+M\+O\+M6.\+devrob/src/equation\+\_\+of\+\_\+state/M\+O\+M\+\_\+\+E\+O\+S\+\_\+\+T\+E\+O\+S10.\+F90\end{DoxyCompactItemize}
