pyremo.physics.pressure

pressure(ps, ak, bk, ptop=0.0, z_coord=None)[source]

computes pressure at model levels.

Uses surface pressure and vertical hybrid coordinates.

Parameters:
  • ps (xarray.DataArray) – Surface pressure field.

  • ak (xarray.DataArray) – Hybrid sigma A coefficient at full levels or level interfaces.

  • bk (xarray.DataArrays) – Hybrid sigma B coefficient at full levels or level interfaces.

  • ptop (float) – Pressure at the top of the atmosphere. Defaults to zero.

  • z_coord (xr.DataArray) – If provided, the Z coordinate will be replace by z_coord. Useful, if ak and bk have no coordinates but only dims.

Returns:

p (xarray.DataArray) – Returns atmopspheric pressure.