pcon¶
-
cfplot.
pcon
(mb=None, km=None, h=7.0, p0=1000)[source]¶ - pcon is a function for converting pressure to height in kilometers andvice-versa. This function uses the equation P=P0exp(-z/H) to translatebetween pressure and height. In pcon the surface pressure P0 is set to1000.0mb and the scale height H is set to 7.0. The value of H can varyfrom 6.0 in the polar regions to 8.5 in the tropics as well asseasonally. The value of P0 could also be said to be 1013.25mb ratherthan 1000.0mb.As this relationship is approximate:(i) Only use this for making the axis labels on y axis pressure plots(ii) Put the converted axis on the right hand side to indicate thatthis isn’t the primary unit of measureprint cfp.pcon(mb=[1000, 300, 100, 30, 10, 3, 1, 0.3])[0. 8.42780963 16.11809565 24.54590528 32.236191340.66400093 48.35428695, 56.78209658]mb=None - input pressurekm=None - input heighth=7.0 - default value for hp0=1000 - default value for p0
Returns: pressure(mb) if height(km) input,height(km) if pressure(mb) input