stilt.transforms.particle_pwf#

stilt.transforms.particle_pwf(particles, surface_pressure=None, altitude_ref='agl')[source]#

Return each particle’s release pressure and pressure weight.

As in X-STILT’s get.wgt.*.func, a hypsometric curve ln p = b + a·z is fit to the particles’ first-step heights and pressures. The fit smooths out the one time step of turbulence between release and the first output, and gives a surface pressure when none is supplied. It is evaluated at each release height, and the spacing between neighboring release pressures gives the air mass each release height represents.

HYSPLIT spreads column particles evenly over height, each placed at random within its own 1/numpar slab. Each release height therefore stands for the slab centered on it. Slab edges sit midway between neighboring release pressures, the ground closes the bottom slab, and the top slab extends above its release height as far as it does below. X-STILT instead gives each particle the layer below it, which shifts every weight down by half a slab and leaves the lowest particle with almost none.

A multipoint receptor releases several particles from each point. Those particles share one release height, so the point’s slab is split evenly among them.

Parameters:
  • particles (DataFrame) – Particle table with indx, pres (hPa), and zagl (m), and optionally xhgt, the release height (m). Without xhgt the first-step height is used. An MSL receptor also needs zsfc, the terrain height (m above sea level).

  • surface_pressure (float | None) – Surface pressure in hPa. Defaults to the fitted curve at the ground.

  • altitude_ref (Literal['agl', 'msl']) – Vertical reference of the release heights, receptor.altitude_ref. With "msl" the fit is made against zagl + zsfc so that it can be evaluated at the release heights, and the ground closing the bottom slab is the terrain under the lowest release height.

Return type:

tuple[Series, Series]

Returns:

  • xpres (pandas.Series) – Release pressure of each particle in hPa, indexed by indx.

  • pwf (pandas.Series) – Pressure weight of each particle, indexed by indx. The weights sum to the fraction of the atmosphere’s mass inside the column, (p_sfc - p_top) / p_sfc. The rest lies above the column top, where surface fluxes do not reach the receptor.