#include <stdio.h>
Go to the source code of this file.
Namespaces | |
namespace | atm |
The module ATMOS specifies the top-level calculations which are aimed to compute the atmospheric parameters and the turbulence profile. The weight functions, described themselves in the module WEIF, are selected and initialized here. With the help of these functions, the various integrals over the altitude which approximate the certain moments of the turbulence (calibrated into seeing, isoplanatic or isokinetic angles etc) are calculated and the low-resolution turbulence profile is computed.
Usage:
Prior to the scientific operations using the observation data, the module should be initialized with atm::init(). Since the module acts as an interface to the module WEIF, some parameters for weight initialization (which are not changed frequently) are transmitted via atm::init(), some others (such as number of measurements or spectral energy distribution - via atm::update(). Note, that the initialization of the module SCIND has to be done separately. Each time some basic information is changed (apertures geometry, transmission function, altitude grid), the module has to be shut down with atm::done() and reinitialized with atm::init() again.
Each time the new object is selected, the weight functions must be updated using the object's own spectral energy distribution (SED) file via the call to atm::loadsed(), atm::checkwf() and atm::update() functions.
Before starting the new measurement the function atm::alloc() must be called before the first calculation of atmospheric integrals. atm::alloc() requires the guessed number of index measurements per accumulation time. It must not be less than actual to avoid the error on the storages overfull.
Then, after some (instantaneous) scintillation indices are obtained, the computation of integrals of Cn2*h^a over atmosphere (power a=0,1,5/3,2) has to be done with atm::calcint(). The results are stored internally.
After the completion of the accumulation time, the integrals of Cn2 by powers of altitude are averaged and converted into seeing, isoplanatic angle and effective altitude of turbulence by atm::avgint(). Also, the procedure atm::calcn2() may be called which uses the average indices and their errors to restore the low-resolution Cn2-profile with one of two methods.
Once the profile and atmospheric characteristics are computed, they may be saved on disk by atm::write(). The converted average integral values and their errors may be accessed by atm::getval() and atm::geterr() after atm::avgint() call.
Finally, to end with the measurements, call a memory destructor atm::done().