# gsw_pt_from_t

    potential temperature

## Contents

- USAGE:
- DESCRIPTION:
- INPUT:
- OUTPUT:
- EXAMPLE:
- AUTHOR:
- VERSION NUMBER:
- REFERENCES:

## USAGE:

    pt = gsw_pt_from_t(SA,t,p,p_ref)

## DESCRIPTION:

    Calculates potential temperature with the general reference pressure,
    p_ref, from in-situ temperature, t.
    This function calls "gsw_entropy_part" which evaluates entropy, except
    for the parts which are a function of Absolute Salinity alone.

    Click for a more detailed description of potential
    temperature.

## INPUT:

    SA  =   Absolute Salinity                                       [ g/kg ]
    t   =   in-situ temperature (ITS-90)                           [ deg C ]
    p   =   sea pressure                                            [ dbar ]
            ( i.e. absolute pressure - 10.1325 dbar )

    OPTIONAL:
    p_ref = reference pressure                                      [ dbar ]
            ( i.e. absolute reference pressure - 10.1325 dbar )
    (If reference pressure is not given then it is assumed that reference
     pressure is zero).

    SA & t need to have the same dimensions. p & pr (if provided) may
    have dimensions 1x1 or Mx1 or 1xN or MxN, where SA & t are MxN.

    A faster gsw routine exists if pr is indeed zero dbar, this routine
    is "gsw_pt0_from_t(SA,t,p)".

## OUTPUT:

    pt   =  potential temperature with                             [ deg C ]
            reference pressure, p_ref. (ITS-90)

## EXAMPLE:

    SA = [34.7118; 34.8915; 35.0256; 34.8472; 34.7366; 34.7324;]
    t =  [28.7856; 28.4329; 22.8103; 10.2600;  6.8863;  4.4036;]
    p =  [     10;      50;     125;     250;     600;    1000;]
    p_ref = 0

    pt = gsw_pt_from_t(SA,t,p,p_ref)

    pt =

      28.783196819670632
      28.420983342398962
      22.784930399117108
      10.230523661095731
       6.829230224409661
       4.324510571845719

## AUTHOR:

    Trevor McDougall, David Jackett, Claire Roberts-Thomson and Paul Barker.
                                                         [ help@teos-10.org ]

## VERSION NUMBER:

    3.01 (26th August, 2010)

## REFERENCES:

    IOC, SCOR and IAPSO, 2010: The international thermodynamic equation of
     seawater - 2010: Calculation and use of thermodynamic properties.
     Intergovernmental Oceanographic Commission, Manuals and Guides No. 56,
     UNESCO (English), 196 pp.  Available from the TEOS-10 web site.
      See section 3.1 of this TEOS-10 Manual.

    McDougall T.J., P.M. Barker, R. Feistel and D.R. Jackett, 2011:  A
     computationally efficient 48-term expression for the density of
     seawater in terms of Conservative Temperature, and related properties
     of seawater.  To be submitted to Ocean Science Discussions.

    The software is available from http://www.TEOS-10.org