ctapipe is not stable yet, so expect large and rapid changes to structure and functionality as we explore various design choices before the 1.0 release.

AtmosphereDensityProfile#

class ctapipe.atmosphere.AtmosphereDensityProfile[source]#

Bases: ABC

Base class for models of atmosphere density.

Methods Summary

__call__(height)

Returns:

from_table(table)

return a subclass of AtmosphereDensityProfile from a serialized table

height_from_overburden(overburden)

Get the height a.s.l. from the mass overburden in the atmosphere.

height_from_slant_depth(slant_depth[, ...])

Calculates height a.s.l. in the atmosphere from traversed slant depth

integral(height)

Integral of the profile along the height axis, i.e. the atmospheric depth \(X\).

peek()

Draw quick plot of profile

slant_depth_from_height(height[, ...])

Line-of-sight integral from height to infinity, along the direction specified by the zenith angle.

Methods Documentation

abstract __call__(height: Quantity) Quantity[source]#
Returns:
u.Quantity[“g cm-3”]

the density at height h

classmethod from_table(table: Table)[source]#

return a subclass of AtmosphereDensityProfile from a serialized table

abstract height_from_overburden(overburden: Quantity) Quantity[source]#
Get the height a.s.l. from the mass overburden in the atmosphere.

Inverse of the integral function

Returns:
u.Quantity[“m”]:

Height a.s.l. for given overburden

height_from_slant_depth(slant_depth: ~astropy.units.quantity.Quantity, zenith_angle=<Quantity 0. deg>, output_units=Unit("m"))[source]#
Calculates height a.s.l. in the atmosphere from traversed slant depth

taking into account the shower zenith angle.

Parameters:
slant_depth: u.Quantity[“grammage”]

line-of-site distance from observer to point

zenith_angle: u.Quantity[“angle”]

zenith angle of observation

output_units: u.Unit

unit to output (must be convertible to m)

abstract integral(height: Quantity) Quantity[source]#

Integral of the profile along the height axis, i.e. the atmospheric depth \(X\).

\[X(h) = \int_{h}^{\infty} \rho(h') dh'\]
Returns:
u.Quantity[“g/cm2”]:

Integral of the density from height h to infinity

peek()[source]#

Draw quick plot of profile

slant_depth_from_height(height: ~astropy.units.quantity.Quantity, zenith_angle=<Quantity 0. deg>, output_units=Unit("g / cm2"))[source]#

Line-of-sight integral from height to infinity, along the direction specified by the zenith angle. This is sometimes called the slant depth. The atmosphere here is assumed to be Cartesian, the curvature of the Earth is not taken into account. This approximation breaks down for large zenith angles (>70 deg), in which case this function does not give correct results. Inverse of height_from_slant_depth function.

\[X(h, \Psi) = \int_{h}^{\infty} \rho(h') dh' / \cos{\Psi}\]
Parameters:
height: u.Quantity[“length”]

height a.s.l. at which to start integral

zenith_angle: u.Quantity[“angle”]

zenith angle of observation

output_units: u.Unit

unit to output (must be convertible to g/cm2)