varwg.meteo.meteox2y.norm_pressure¶
- varwg.meteo.meteox2y.norm_pressure(p, at, h=454.0)[source]¶
normalize pressure to sealevel
formula from wikipedia.de for linear temperature gradient 0.0065K/m
- Parameters:
- pfloat or numpy.array of floats
pressure [hPa]
- atfloat or numpy.array of floats
air temperature [deg C]
- hfloat, optional
height above sea level of measuring station [m] default value = 454.0 (height of station Stuttgart-Lauchaecker)
- Returns:
- p_nnfloat or numpy.array of floats
sea level pressure [hPa]
Examples
>>> "%.9f" % norm_pressure(930,10.0) '982.074383073'
>>> "%.9f" % norm_pressure(930,10.0,h=765) '1019.090035371'
>>> at = np.array((0.0, 2.5, 5.0, 7.5, 10.0)) >>> p = np.array((925, 930, 935, 932, 931)) >>> norm_pressure(p,at,h=765) array([1016.98077228, 1021.60706988, 1026.24032953, 1022.10690872, 1020.18583111])