ARTS built-in documentation server

Workspace Method cloudboxSetAutomatically

Description

Sets the cloud box to encompass the cloud given by the entries
in massdensity_field. 

The function must be called before any cloudbox_limits using
WSMs.
NOTE: only 1-dim case is handeled in the moment!

The function iterates over all part_species and performs a 
check, to see if the corresponding scattering particle profiles do not
contain a cloud (all values equal zero). If, after all iterations,
all the considrered profiles proove to contain no cloud,
the cloudbox is switched off! (see WSM cloudboxOff)

Each scattering particle profile is searched for the first and last
pressure index, where the value is unequal to zero. This index
is then copied to cloudbox_limits.

Additionaly the lower cloudbox_limit is altered by
*cloudbox_margin*.
The margin is given as a height difference in meters and
trasformed into a pressure.(via isothermal barometric heightformula)
This alteration is needed to ensure, that scattered photons
do not leave and re-enter the cloudbox, due to its convex
shape.
If *cloudbox_margin* is set to -1 (default), the cloudbox will extend to
the surface. Hence the lower cloudbox_limit is set to 0 (index
of first pressure level).

Authors: Daniel Kreyling

Synopsis

cloudboxSetAutomatically( cloudbox_on, cloudbox_limits, atmosphere_dim, p_grid, lat_grid, lon_grid, massdensity_field, cloudbox_margin )

Variables

OUTcloudbox_on(Index)Flag to activate the cloud box.
OUTcloudbox_limits(ArrayOfIndex)The limits of the cloud box.
INatmosphere_dim(Index)The atmospheric dimensionality (1-3).
INp_grid(Vector)The pressure grid.
INlat_grid(Vector)The latitude grid.
INlon_grid(Vector)The longitude grid.
INmassdensity_field(Tensor4)The field of atmospheric scattering particle types in unit of massdensity (like IWC/LWC/Rain/Aerosol etc.).
GINcloudbox_margin(Numeric, Default: -1)The margin alters the lower vertical cloudbox limit. Value must be given in [m]. If cloudbox_margin is set to *-1* (default), the lower cloudbox limit equals 0, what corresponds to the surface !