Metview's documentation is now on readthedocs!

You are viewing an old version of this page. View the current version.

Compare with Current View Page History

« Previous Version 12 Next »


definition lifted_condensation_level(number t, number td, number p)

Computes the Lifted Condensation Level of a parcel ascending from a given temperature, dewpoint and pressure, where

    • t: the start temperature (°C)
    • td: the start dewpoint (°C)
    • p: the start pressure (hPa)

The LCL is the level where the parcel becomes saturated and it is computed with an iterative method along the dry adiabat of the ascending parcel.

The result is a definition with two members: t and p, containing the temperature and pressure of the LCL, in K and Pa units, respectively. On error or if the LCL does not exist nil is returned.


number potential_temperature(number t, number p)

Computes the potential temperature for a given temperature and pressure, where

    • t: the temperature (°C)
    • p: the pressure (hPa)

The result is the potential temperature in °C units. On error  nil is returned.


number saturation_mixing_ratio(number t, number p)

Computes the saturation mixing ratio for a given temperature and pressure, where

    • t: the temperature (°C)
    • p: the pressure (hPa)

The result is the saturation mixing ratio  in kg/kg units. On error  nil is returned.


number temperature_from_potential_temperature(number th, number p)

Computes the temperature for a given potential temperature and pressure, where

    • th:the potential temperature (°C)
    • p: the pressure (hPa)

The result is the temperature in °C units. On error  nil is returned.


netcdf thermo_bufr(...)

Extract vertical profiles from BUFR data in a suitable format suitable for thermodynamic diagrams (defined by Thermo View). This is a Metview icon function, for detailed documentation please see Thermo Data.


netcdf thermo_grib(...)

Extract vertical profiles from GRIB data in a suitable format for thermodynamic diagrams (defined by Thermo View). This is a Metview icon function, for detailed documentation please see Thermo Data.


definition thermo_parcel_path(vector t, vector td, vector p, definition start_condition)

definition thermo_parcel_path(netcdf profile, definition start_condition)

Computes the path of an ascending thermodynamic parcel with the given start condition for the given vertical profile. It returns a definition containing all the data to plot parcel path, buoyancy areas and related data into a thermodynamic diagram. The vertical profile is either specified as a set of vectors where:

    • t: the temperature profile (°C)
    • td: the dew point profile (°C)
    • p: the pressure profile (hPa)

or as a vertical profile where:

    • profile: the result of a vertical profile extraction from GRIB or BUFR with the thermo_grib() or thermo_bufr() functions (see Thermo Data ), respectively.

There are four different modes to specify the a parcel's start_condition  (as a definition):

Surface

The parcel ascends from the surface, i.e. the lowest point of the profile. The format is as follows:

(mode: 'surface')

Custom

The parcel ascends from a given temperature, dewpoint and pressure. The format is as follows:

(mode: 'custom', t: start_temperature, td: start_dewpoint, p: start_pressure)

Mean layer

The parcel ascends from the mean temperature, dew point and pressure of a given pressure layer. The format is as follows:

(mode: 'mean_layer', p_top: layer_top, p_bottom: layer_bottom )

Please note that when p_bottom is omitted the layer starts at the surface.

Most unstable

The parcel ascends from the most unstable condition. To determine this, a parcel is started from all the points along the profile in the specified pressure layer. The start level of the parcel that results in the highest CAPE value will define the most unstable start condition. The format is as follows:

(mode: 'most_unstable', p_top: layer_top, p_bottom: layer_bottom )

Please note that when p_bottom is omitted the pressure layer starts at the surface.


The function returns a definition to describe all the parameters related to the parcel's ascend. The members of this definition are as follows:

    • path: the path of the parcel. It is itself a definition with two members: t and p, each containing a list of values.
    • area: the positive and negative buoyancy areas between the parcel path and the profile. It is a list of definitions describing the areas.
    • cape: the value of the CAPE (Convective Available Potential Energy)  (J/kg)
    • cin: value the CIN (Convective Inhibition) (J/kg)
    • lcl: the Lifted Condensation Level. It is a definition with two members: t and p. If no LCL exists it is set to nil.
    • lfc: the Level of Free Convention. It is a definition with two members: t and p. If no LFC exists it is set to nil.
    • el: the Equilibrium Level. It is a definition with two members: t and p. If no EL exists it is set to nil.
    • top: the Cloud Top Level. It is a definition with two members: t and p. If no TOP exists it is set to nil.
    • start: the start conditions of the parcel with four members: mode, t, td and p.




  • No labels