radarx.retrieve.ducts.modified_refractivity#
- radarx.retrieve.ducts.modified_refractivity(profile, *, earth_radius=6371000.0, form='bean_dutton')[source]#
Modified refractivity of a profile.
- Parameters:
profile (
xarray.Datasetorxarray.DataArray) – Refractivity on aheightcoordinate (m above sea level): a DataArray in N-units, or a Dataset withrefractivityor withpressure(Pa),temperature(K) and one ofvapor_pressure,specific_humidity,dewpointorrelative_humidity, as forradarx.retrieve.beam_path(). Any other dimensions are kept.earth_radius (
float, optional) – Radius of the Earth (m). Default: the radarx value.form (
str, optional) – Formula of the refractivity from the thermodynamic variables (radarx.io.sounding.refractivity()). Default"bean_dutton".
- Returns:
xarray.DataArray– \(M = N + 10^6 h / a\) (M-units), on the dimensions of the profile. It decreases with height in trapping layers.- Raises:
ValueError – For a missing variable or coordinate, or an
earth_radiusthat is not positive.TypeError – If
profileis not an xarray object.
Notes
Bean and Dutton (1966, Table 1.9). The input is not changed.
References
Examples
>>> import numpy as np, xarray as xr >>> h = np.array([0.0, 1000.0]) >>> n = xr.DataArray([320.0, 281.0], dims="height", coords={"height": h}) >>> modified_refractivity(n).round(1).values.tolist() [320.0, 437.96]