ARTS
2.4.0(git:4fb77825)
|
This file contains functions to calculate the radiative transfer inside the cloudbox using the DOIT method. More...
#include <cmath>
#include <cstdlib>
#include <iostream>
#include <stdexcept>
#include "agenda_class.h"
#include "array.h"
#include "arts.h"
#include "auto_md.h"
#include "check_input.h"
#include "doit.h"
#include "geodetic.h"
#include "lin_alg.h"
#include "logic.h"
#include "m_general.h"
#include "math_funcs.h"
#include "matpackVII.h"
#include "messages.h"
#include "physics_funcs.h"
#include "ppath.h"
#include "rte.h"
#include "special_interp.h"
#include "wsv_aux.h"
#include "xml_io.h"
Go to the source code of this file.
Functions | |
void | DOAngularGridsSet (Index &doit_za_grid_size, Vector &aa_grid, Vector &za_grid, const Index &N_za_grid, const Index &N_aa_grid, const String &za_grid_opt_file, const Verbosity &verbosity) |
WORKSPACE METHOD: DOAngularGridsSet. More... | |
void | doit_conv_flagAbs (Index &doit_conv_flag, Index &doit_iteration_counter, Tensor6 &cloudbox_field_mono, const Tensor6 &cloudbox_field_mono_old, const Vector &epsilon, const Index &max_iterations, const Index &throw_nonconv_error, const Verbosity &verbosity) |
WORKSPACE METHOD: doit_conv_flagAbs. More... | |
void | doit_conv_flagAbsBT (Index &doit_conv_flag, Index &doit_iteration_counter, Tensor6 &cloudbox_field_mono, const Tensor6 &cloudbox_field_mono_old, const Vector &f_grid, const Index &f_index, const Vector &epsilon, const Index &max_iterations, const Index &throw_nonconv_error, const Verbosity &verbosity) |
WORKSPACE METHOD: doit_conv_flagAbsBT. More... | |
void | doit_conv_flagLsq (Index &doit_conv_flag, Index &doit_iteration_counter, Tensor6 &cloudbox_field_mono, const Tensor6 &cloudbox_field_mono_old, const Vector &f_grid, const Index &f_index, const Vector &epsilon, const Index &max_iterations, const Index &throw_nonconv_error, const Verbosity &verbosity) |
WORKSPACE METHOD: doit_conv_flagLsq. More... | |
void | cloudbox_field_monoIterate (Workspace &ws, Tensor6 &cloudbox_field_mono, const Agenda &doit_scat_field_agenda, const Agenda &doit_rte_agenda, const Agenda &doit_conv_test_agenda, const Index &accelerated, const Verbosity &verbosity) |
WORKSPACE METHOD: cloudbox_field_monoIterate. More... | |
void | cloudbox_fieldUpdate1D (Workspace &ws, Tensor6 &cloudbox_field_mono, const Tensor6 &doit_scat_field, const ArrayOfIndex &cloudbox_limits, const Agenda &propmat_clearsky_agenda, const Tensor4 &vmr_field, const Agenda &spt_calc_agenda, const Vector &za_grid, const Tensor4 &pnd_field, const Agenda &ppath_step_agenda, const Numeric &ppath_lmax, const Numeric &ppath_lraytrace, const Vector &p_grid, const Tensor3 &z_field, const Vector &refellipsoid, const Tensor3 &t_field, const Vector &f_grid, const Index &f_index, const Agenda &surface_rtprop_agenda, const Index &doit_za_interp, const Verbosity &verbosity) |
WORKSPACE METHOD: cloudbox_fieldUpdate1D. More... | |
void | cloudbox_fieldUpdateSeq1D (Workspace &ws, Tensor6 &cloudbox_field_mono, Tensor6 &doit_scat_field, const ArrayOfIndex &cloudbox_limits, const Agenda &propmat_clearsky_agenda, const Tensor4 &vmr_field, const Agenda &spt_calc_agenda, const Vector &za_grid, const Vector &aa_grid, const Tensor4 &pnd_field, const Agenda &ppath_step_agenda, const Numeric &ppath_lmax, const Numeric &ppath_lraytrace, const Vector &p_grid, const Tensor3 &z_field, const Vector &refellipsoid, const Tensor3 &t_field, const Vector &f_grid, const Index &f_index, const Agenda &surface_rtprop_agenda, const Index &doit_za_interp, const Index &normalize, const Numeric &norm_error_threshold, const Index &norm_debug, const Verbosity &verbosity) |
WORKSPACE METHOD: cloudbox_fieldUpdateSeq1D. More... | |
void | cloudbox_fieldUpdateSeq3D (Workspace &ws, Tensor6 &cloudbox_field_mono, const Tensor6 &doit_scat_field, const ArrayOfIndex &cloudbox_limits, const Agenda &propmat_clearsky_agenda, const Tensor4 &vmr_field, const Agenda &spt_calc_agenda, const Vector &za_grid, const Vector &aa_grid, const Tensor4 &pnd_field, const Agenda &ppath_step_agenda, const Numeric &ppath_lmax, const Numeric &ppath_lraytrace, const Vector &p_grid, const Vector &lat_grid, const Vector &lon_grid, const Tensor3 &z_field, const Vector &refellipsoid, const Tensor3 &t_field, const Vector &f_grid, const Index &f_index, const Index &doit_za_interp, const Verbosity &verbosity) |
WORKSPACE METHOD: cloudbox_fieldUpdateSeq3D. More... | |
void | cloudbox_fieldUpdateSeq1DPP (Workspace &ws, Tensor6 &cloudbox_field_mono, Index &za_index, const Tensor6 &doit_scat_field, const ArrayOfIndex &cloudbox_limits, const Agenda &propmat_clearsky_agenda, const Tensor4 &vmr_field, const Agenda &spt_calc_agenda, const Vector &za_grid, const Tensor4 &pnd_field, const Vector &p_grid, const Tensor3 &z_field, const Tensor3 &t_field, const Vector &f_grid, const Index &f_index, const Verbosity &verbosity) |
WORKSPACE METHOD: cloudbox_fieldUpdateSeq1DPP. More... | |
void | DoitInit (Tensor6 &doit_scat_field, Tensor7 &cloudbox_field, Index &doit_is_initialized, const Index &stokes_dim, const Index &atmosphere_dim, const Vector &f_grid, const Vector &za_grid, const Vector &aa_grid, const Index &doit_za_grid_size, const Index &cloudbox_on, const ArrayOfIndex &cloudbox_limits, const Verbosity &verbosity) |
WORKSPACE METHOD: DoitInit. More... | |
void | cloudbox_field_monoOptimizeReverse (Tensor6 &cloudbox_field_mono, const Vector &p_grid_orig, const Vector &p_grid, const ArrayOfIndex &cloudbox_limits, const Verbosity &) |
WORKSPACE METHOD: cloudbox_field_monoOptimizeReverse. More... | |
void | OptimizeDoitPressureGrid (Workspace &ws, Vector &p_grid, Tensor4 &pnd_field, Tensor3 &t_field, ArrayOfArrayOfSingleScatteringData &scat_data_mono, Tensor3 &z_field, ArrayOfIndex &cloudbox_limits, Tensor6 &cloudbox_field_mono, Tensor7 &pha_mat_doit, Tensor4 &vmr_field, Vector &p_grid_orig, const Vector &f_grid, const Index &f_index, const Agenda &propmat_clearsky_agenda, const Numeric &tau_scat_max, const Numeric &sgl_alb_max, const Index &cloudbox_size_max, const Verbosity &verbosity) |
WORKSPACE METHOD: OptimizeDoitPressureGrid. More... | |
void | DoitWriteIterationFields (const Index &doit_iteration_counter, const Tensor6 &cloudbox_field_mono, const Index &f_index, const ArrayOfIndex &iterations, const ArrayOfIndex &frequencies, const Verbosity &verbosity) |
WORKSPACE METHOD: DoitWriteIterationFields. More... | |
void | doit_scat_fieldCalc (Workspace &ws, Tensor6 &doit_scat_field, const Agenda &pha_mat_spt_agenda, const Tensor6 &cloudbox_field_mono, const Tensor4 &pnd_field, const Tensor3 &t_field, const Index &atmosphere_dim, const ArrayOfIndex &cloudbox_limits, const Vector &za_grid, const Vector &aa_grid, const Index &doit_za_grid_size, const Tensor7 &pha_mat_doit, const Verbosity &verbosity) |
WORKSPACE METHOD: doit_scat_fieldCalc. More... | |
void | doit_scat_fieldCalcLimb (Workspace &ws, Tensor6 &doit_scat_field, const Agenda &pha_mat_spt_agenda, const Tensor6 &cloudbox_field_mono, const Tensor4 &pnd_field, const Tensor3 &t_field, const Index &atmosphere_dim, const ArrayOfIndex &cloudbox_limits, const Vector &za_grid, const Vector &aa_grid, const Index &doit_za_grid_size, const Index &doit_za_interp, const Tensor7 &pha_mat_doit, const Verbosity &verbosity) |
WORKSPACE METHOD: doit_scat_fieldCalcLimb. More... | |
void | doit_za_grid_optCalc (Vector &doit_za_grid_opt, const Tensor6 &cloudbox_field_mono, const Vector &za_grid, const Index &doit_za_interp, const Numeric &acc, const Verbosity &verbosity) |
WORKSPACE METHOD: doit_za_grid_optCalc. More... | |
void | doit_za_interpSet (Index &doit_za_interp, const Index &atmosphere_dim, const String &method, const Verbosity &) |
WORKSPACE METHOD: doit_za_interpSet. More... | |
void | DoitCalc (Workspace &ws, Tensor7 &cloudbox_field, const Index &atmfields_checked, const Index &atmgeom_checked, const Index &cloudbox_checked, const Index &scat_data_checked, const Index &cloudbox_on, const Vector &f_grid, const Agenda &doit_mono_agenda, const Index &doit_is_initialized, const Verbosity &verbosity) |
WORKSPACE METHOD: DoitCalc. More... | |
void | DoitGetIncoming (Workspace &ws, Tensor7 &cloudbox_field, const Index &atmfields_checked, const Index &atmgeom_checked, const Index &cloudbox_checked, const Index &doit_is_initialized, const Agenda &iy_main_agenda, const Index &atmosphere_dim, const Vector &lat_grid, const Vector &lon_grid, const Tensor3 &z_field, const EnergyLevelMap &nlte_field, const Index &cloudbox_on, const ArrayOfIndex &cloudbox_limits, const Vector &f_grid, const Index &stokes_dim, const Vector &za_grid, const Vector &aa_grid, const Index &rigorous, const Numeric &maxratio, const Verbosity &) |
WORKSPACE METHOD: DoitGetIncoming. More... | |
void | DoitGetIncoming1DAtm (Workspace &ws, Tensor7 &cloudbox_field, Index &cloudbox_on, const Index &atmfields_checked, const Index &atmgeom_checked, const Index &cloudbox_checked, const Index &doit_is_initialized, const Agenda &iy_main_agenda, const Index &atmosphere_dim, const Vector &lat_grid, const Vector &lon_grid, const Tensor3 &z_field, const EnergyLevelMap &nlte_field, const ArrayOfIndex &cloudbox_limits, const Vector &f_grid, const Index &stokes_dim, const Vector &za_grid, const Vector &aa_grid, const Verbosity &) |
WORKSPACE METHOD: DoitGetIncoming1DAtm. More... | |
void | cloudbox_fieldSetFromPrecalc (Tensor7 &cloudbox_field, const Vector &za_grid, const Vector &f_grid, const Index &atmosphere_dim, const Index &stokes_dim, const ArrayOfIndex &cloudbox_limits, const Index &doit_is_initialized, const Tensor7 &cloudbox_field_precalc, const Verbosity &) |
WORKSPACE METHOD: cloudbox_fieldSetFromPrecalc. More... | |
void | cloudbox_fieldSetClearsky (Tensor7 &cloudbox_field, const Vector &p_grid, const Vector &lat_grid, const Vector &lon_grid, const ArrayOfIndex &cloudbox_limits, const Index &atmosphere_dim, const Index &cloudbox_on, const Index &doit_is_initialized, const Index &all_frequencies, const Verbosity &verbosity) |
WORKSPACE METHOD: cloudbox_fieldSetClearsky. More... | |
void | cloudbox_fieldSetConst (Tensor7 &cloudbox_field, const Vector &p_grid, const Vector &lat_grid, const Vector &lon_grid, const ArrayOfIndex &cloudbox_limits, const Index &atmosphere_dim, const Index &stokes_dim, const Vector &cloudbox_field_values, const Verbosity &verbosity) |
WORKSPACE METHOD: cloudbox_fieldSetConst. More... | |
void | cloudbox_fieldSetConstPerFreq (Tensor7 &cloudbox_field, const Vector &p_grid, const Vector &lat_grid, const Vector &lon_grid, const ArrayOfIndex &cloudbox_limits, const Index &atmosphere_dim, const Index &stokes_dim, const Matrix &cloudbox_field_values, const Verbosity &verbosity) |
WORKSPACE METHOD: cloudbox_fieldSetConstPerFreq. More... | |
void | cloudbox_field_monoSetConst (Tensor6 &cloudbox_field_mono, const Vector &p_grid, const Vector &lat_grid, const Vector &lon_grid, const ArrayOfIndex &cloudbox_limits, const Index &atmosphere_dim, const Index &stokes_dim, const Vector &cloudbox_field_values, const Verbosity &verbosity) |
WORKSPACE METHOD: cloudbox_field_monoSetConst. More... | |
Variables | |
const Numeric | PI |
const Numeric | RAD2DEG |
This file contains functions to calculate the radiative transfer inside the cloudbox using the DOIT method.
These functions are listed in the doxygen documentation as entries of the file auto_md.h
Definition in file m_doit.cc.
void cloudbox_field_monoIterate | ( | Workspace & | ws, |
Tensor6 & | cloudbox_field_mono, | ||
const Agenda & | doit_scat_field_agenda, | ||
const Agenda & | doit_rte_agenda, | ||
const Agenda & | doit_conv_test_agenda, | ||
const Index & | accelerated, | ||
const Verbosity & | verbosity | ||
) |
WORKSPACE METHOD: cloudbox_field_monoIterate.
Iterative solution of the VRTE (DOIT method).
A solution for the RTE with scattering is found using the DOIT method: <br> 1. Calculate scattering integral using doit_scat_field_agenda. <br> 2. Calculate RT with fixed scattered field using <br> doit_rte_agenda. <br> 3. Convergence test using doit_conv_test_agenda.
Note: The atmospheric dimensionality atmosphere_dim can be <br> either 1 or 3. To these dimensions the method adapts <br> automatically. 2D scattering calculations are not <br> supported.
[in,out] | ws | Workspace |
[in,out] | cloudbox_field_mono | WS Input/Output |
[in] | doit_scat_field_agenda | WS Input |
[in] | doit_rte_agenda | WS Input |
[in] | doit_conv_test_agenda | WS Input |
[in] | accelerated | Generic Input (Default: "0") |
Definition at line 497 of file m_doit.cc.
References chk_not_empty(), ARTS::Var::cloudbox_field_mono(), CREATE_OUT2, ARTS::Var::doit_conv_test_agenda(), ARTS::Var::doit_rte_agenda(), and ARTS::Var::doit_scat_field_agenda().
Referenced by cloudbox_field_monoIterate_g().
void cloudbox_field_monoOptimizeReverse | ( | Tensor6 & | cloudbox_field_mono, |
const Vector & | p_grid_orig, | ||
const Vector & | p_grid, | ||
const ArrayOfIndex & | cloudbox_limits, | ||
const Verbosity & | verbosity | ||
) |
WORKSPACE METHOD: cloudbox_field_monoOptimizeReverse.
Interpolate cloudbox_field_mono back to the original p_grid. For detailed description, see OptimizeDoitPressureGrid.
[in,out] | cloudbox_field_mono | WS Input/Output |
[in] | p_grid_orig | WS Input |
[in] | p_grid | WS Input |
[in] | cloudbox_limits | WS Input |
Definition at line 1699 of file m_doit.cc.
References chk_interpolation_grids(), ARTS::Var::cloudbox_field_mono(), ARTS::Var::cloudbox_limits(), gridpos(), interp(), interpweights(), joker, Array< base >::nelem(), ARTS::Var::p_grid(), and ARTS::Var::p_grid_orig().
Referenced by cloudbox_field_monoOptimizeReverse_g().
void cloudbox_field_monoSetConst | ( | Tensor6 & | cloudbox_field_mono, |
const Vector & | p_grid, | ||
const Vector & | lat_grid, | ||
const Vector & | lon_grid, | ||
const ArrayOfIndex & | cloudbox_limits, | ||
const Index & | atmosphere_dim, | ||
const Index & | stokes_dim, | ||
const Vector & | value, | ||
const Verbosity & | verbosity | ||
) |
WORKSPACE METHOD: cloudbox_field_monoSetConst.
This method sets the initial field inside the cloudbox to a constant value. The method works only for monochromatic calculations (number of elements in f_grid=1).
The user can specify a value for each Stokes dimension in the control file by value.
[in,out] | cloudbox_field_mono | WS Input/Output |
[in] | p_grid | WS Input |
[in] | lat_grid | WS Input |
[in] | lon_grid | WS Input |
[in] | cloudbox_limits | WS Input |
[in] | atmosphere_dim | WS Input |
[in] | stokes_dim | WS Input |
[in] | value | Generic Input |
Definition at line 3793 of file m_doit.cc.
References ARTS::Var::atmosphere_dim(), chk_atm_grids(), chk_if_in_range(), ARTS::Var::cloudbox_field_mono(), ARTS::Var::cloudbox_limits(), CREATE_OUT2, CREATE_OUT3, joker, ARTS::Var::lat_grid(), ARTS::Var::lon_grid(), ARTS::Var::p_grid(), and ARTS::Var::stokes_dim().
Referenced by cloudbox_field_monoSetConst_g(), cloudbox_fieldSetConst(), and cloudbox_fieldSetConstPerFreq().
void cloudbox_fieldSetClearsky | ( | Tensor7 & | cloudbox_field, |
const Vector & | p_grid, | ||
const Vector & | lat_grid, | ||
const Vector & | lon_grid, | ||
const ArrayOfIndex & | cloudbox_limits, | ||
const Index & | atmosphere_dim, | ||
const Index & | cloudbox_on, | ||
const Index & | doit_is_initialized, | ||
const Index & | all_frequencies, | ||
const Verbosity & | verbosity | ||
) |
WORKSPACE METHOD: cloudbox_fieldSetClearsky.
Interpolate clearsky field on all gridpoints in cloudbox.
This method uses a linear 1D/3D interpolation scheme to obtain the radiation field on all grid points inside the cloud box from the clear sky field on the cloudbox boundary. This radiation field is taken as the first guess radiation field in the DOIT module.
Set the all_frequencies to 1 if the clearsky field shall be used as initial field for all frequencies. Set it to 0 if the clear sky field shall be used only for the first frequency in f_grid. For later frequencies, cloudbox_field of the previous frequency is then used.
[in,out] | cloudbox_field | WS Input/Output |
[in] | p_grid | WS Input |
[in] | lat_grid | WS Input |
[in] | lon_grid | WS Input |
[in] | cloudbox_limits | WS Input |
[in] | atmosphere_dim | WS Input |
[in] | cloudbox_on | WS Input |
[in] | doit_is_initialized | WS Input |
[in] | all_frequencies | Generic Input (Default: "1") |
Definition at line 3467 of file m_doit.cc.
References ARTS::Var::aa_index(), ARTS::Var::atmosphere_dim(), ARTS::Var::cloudbox_field(), ARTS::Var::cloudbox_limits(), ARTS::Var::cloudbox_on(), CREATE_OUT2, ARTS::Var::doit_is_initialized(), ARTS::Var::f_index(), gridpos(), interp(), interpweights(), joker, ARTS::Var::lat_grid(), ARTS::Var::lon_grid(), p2gridpos(), ARTS::Var::p_grid(), and ARTS::Var::za_index().
Referenced by cloudbox_fieldSetClearsky_g().
void cloudbox_fieldSetConst | ( | Tensor7 & | cloudbox_field, |
const Vector & | p_grid, | ||
const Vector & | lat_grid, | ||
const Vector & | lon_grid, | ||
const ArrayOfIndex & | cloudbox_limits, | ||
const Index & | atmosphere_dim, | ||
const Index & | stokes_dim, | ||
const Vector & | value, | ||
const Verbosity & | verbosity | ||
) |
WORKSPACE METHOD: cloudbox_fieldSetConst.
This method sets the initial field inside the cloudbox to a constant value.
The user has to specify a value for each Stokes dimension in the control file by value.
[in,out] | cloudbox_field | WS Input/Output |
[in] | p_grid | WS Input |
[in] | lat_grid | WS Input |
[in] | lon_grid | WS Input |
[in] | cloudbox_limits | WS Input |
[in] | atmosphere_dim | WS Input |
[in] | stokes_dim | WS Input |
[in] | value | Generic Input |
Definition at line 3706 of file m_doit.cc.
References ARTS::Var::atmosphere_dim(), ARTS::Var::cloudbox_field(), ARTS::Var::cloudbox_field_mono(), cloudbox_field_monoSetConst(), ARTS::Var::cloudbox_limits(), CREATE_OUT2, ARTS::Var::f_index(), joker, ARTS::Var::lat_grid(), ARTS::Var::lon_grid(), ARTS::Var::p_grid(), ARTS::Var::stokes_dim(), and ARTS::Var::verbosity().
Referenced by cloudbox_fieldSetConst_g().
void cloudbox_fieldSetConstPerFreq | ( | Tensor7 & | cloudbox_field, |
const Vector & | p_grid, | ||
const Vector & | lat_grid, | ||
const Vector & | lon_grid, | ||
const ArrayOfIndex & | cloudbox_limits, | ||
const Index & | atmosphere_dim, | ||
const Index & | stokes_dim, | ||
const Matrix & | value, | ||
const Verbosity & | verbosity | ||
) |
WORKSPACE METHOD: cloudbox_fieldSetConstPerFreq.
This method sets the initial field inside the cloudbox to a constant value per frequency slice.
The user has specify a value for each frequency and Stokes dimension in the control file by value.
[in,out] | cloudbox_field | WS Input/Output |
[in] | p_grid | WS Input |
[in] | lat_grid | WS Input |
[in] | lon_grid | WS Input |
[in] | cloudbox_limits | WS Input |
[in] | atmosphere_dim | WS Input |
[in] | stokes_dim | WS Input |
[in] | value | Generic Input |
Definition at line 3747 of file m_doit.cc.
References ARTS::Var::atmosphere_dim(), ARTS::Var::cloudbox_field(), ARTS::Var::cloudbox_field_mono(), cloudbox_field_monoSetConst(), ARTS::Var::cloudbox_limits(), CREATE_OUT2, ARTS::Var::f_index(), joker, ARTS::Var::lat_grid(), ARTS::Var::lon_grid(), ConstMatrixView::nrows(), ARTS::Var::p_grid(), ARTS::Var::stokes_dim(), and ARTS::Var::verbosity().
Referenced by cloudbox_fieldSetConstPerFreq_g().
void cloudbox_fieldSetFromPrecalc | ( | Tensor7 & | cloudbox_field, |
const Vector & | za_grid, | ||
const Vector & | f_grid, | ||
const Index & | atmosphere_dim, | ||
const Index & | stokes_dim, | ||
const ArrayOfIndex & | cloudbox_limits, | ||
const Index & | doit_is_initialized, | ||
const Tensor7 & | cloudbox_field_precalc, | ||
const Verbosity & | verbosity | ||
) |
WORKSPACE METHOD: cloudbox_fieldSetFromPrecalc.
Sets the initial cloudbox intensity field cloudbox_field from a precalculated field.
This method sets the (monochromatic) first guess radiation field inside the cloudbox from a precalculated cloudbox_field_precalc, e.g., from the solution of a similar atmospheric scenario. The dimensions of cloudbox_field_precalc have to be consistent with the DOIT setup in terms of frequencies, pressure levels inside the cloudbox, polar angles used as well as the stokes dimension. Incoming field on the cloudbox boundaries is adapted to the actual clearsky incoming field as, e.g., calculated by DoitGetIncoming.
[in,out] | cloudbox_field | WS Input/Output |
[in] | za_grid | WS Input |
[in] | f_grid | WS Input |
[in] | atmosphere_dim | WS Input |
[in] | stokes_dim | WS Input |
[in] | cloudbox_limits | WS Input |
[in] | doit_is_initialized | WS Input |
[in] | cloudbox_field_precalc | Generic Input |
Definition at line 3364 of file m_doit.cc.
References ARTS::Var::atmosphere_dim(), ARTS::Var::cloudbox_field(), ARTS::Var::cloudbox_limits(), ARTS::Var::doit_is_initialized(), ARTS::Var::f_grid(), joker, ConstTensor7View::ncols(), ConstTensor7View::nlibraries(), ConstTensor7View::npages(), ConstTensor7View::nvitrines(), ARTS::Var::stokes_dim(), and ARTS::Var::za_grid().
Referenced by cloudbox_fieldSetFromPrecalc_g().
void cloudbox_fieldUpdate1D | ( | Workspace & | ws, |
Tensor6 & | cloudbox_field_mono, | ||
const Tensor6 & | doit_scat_field, | ||
const ArrayOfIndex & | cloudbox_limits, | ||
const Agenda & | propmat_clearsky_agenda, | ||
const Tensor4 & | vmr_field, | ||
const Agenda & | spt_calc_agenda, | ||
const Vector & | za_grid, | ||
const Tensor4 & | pnd_field, | ||
const Agenda & | ppath_step_agenda, | ||
const Numeric & | ppath_lmax, | ||
const Numeric & | ppath_lraytrace, | ||
const Vector & | p_grid, | ||
const Tensor3 & | z_field, | ||
const Vector & | refellipsoid, | ||
const Tensor3 & | t_field, | ||
const Vector & | f_grid, | ||
const Index & | f_index, | ||
const Agenda & | surface_rtprop_agenda, | ||
const Index & | doit_za_interp, | ||
const Verbosity & | verbosity | ||
) |
WORKSPACE METHOD: cloudbox_fieldUpdate1D.
RT calculation in cloudbox with fixed scattering integral (1D).
Updates the radiation field (DOIT method). The method loops through the cloudbox to update the radiation field for all positions and directions in the 1D cloudbox.
Note: This method is very inefficient, because the number of iterations scales with the number of cloudbox pressure levels. It is recommended to use cloudbox_fieldUpdateSeq1D.
[in,out] | ws | Workspace |
[in,out] | cloudbox_field_mono | WS Input/Output |
[in] | doit_scat_field | WS Input |
[in] | cloudbox_limits | WS Input |
[in] | propmat_clearsky_agenda | WS Input |
[in] | vmr_field | WS Input |
[in] | spt_calc_agenda | WS Input |
[in] | za_grid | WS Input |
[in] | pnd_field | WS Input |
[in] | ppath_step_agenda | WS Input |
[in] | ppath_lmax | WS Input |
[in] | ppath_lraytrace | WS Input |
[in] | p_grid | WS Input |
[in] | z_field | WS Input |
[in] | refellipsoid | WS Input |
[in] | t_field | WS Input |
[in] | f_grid | WS Input |
[in] | f_index | WS Input |
[in] | surface_rtprop_agenda | WS Input |
[in] | doit_za_interp | WS Input |
Definition at line 591 of file m_doit.cc.
References chk_if_decreasing(), chk_if_increasing(), chk_not_empty(), chk_size(), cloud_fieldsCalc(), cloud_ppath_update1D_noseq(), ARTS::Var::cloudbox_field_mono(), ARTS::Var::cloudbox_limits(), CREATE_OUT2, CREATE_OUT3, ARTS::Var::doit_scat_field(), ARTS::Var::doit_za_interp(), ARTS::Var::f_grid(), ARTS::Var::f_index(), is_size(), ARTS::Var::p_grid(), ARTS::Var::pnd_field(), ARTS::Var::ppath_lmax(), ARTS::Var::ppath_lraytrace(), ARTS::Var::ppath_step_agenda(), ARTS::Var::propmat_clearsky_agenda(), ARTS::Var::refellipsoid(), ARTS::Var::spt_calc_agenda(), ARTS::Var::stokes_dim(), ARTS::Var::surface_rtprop_agenda(), ARTS::Var::t_field(), ARTS::Var::verbosity(), ARTS::Var::vmr_field(), ARTS::Var::z_field(), and ARTS::Var::za_grid().
Referenced by cloudbox_fieldUpdate1D_g().
void cloudbox_fieldUpdateSeq1D | ( | Workspace & | ws, |
Tensor6 & | cloudbox_field_mono, | ||
Tensor6 & | doit_scat_field, | ||
const ArrayOfIndex & | cloudbox_limits, | ||
const Agenda & | propmat_clearsky_agenda, | ||
const Tensor4 & | vmr_field, | ||
const Agenda & | spt_calc_agenda, | ||
const Vector & | za_grid, | ||
const Vector & | aa_grid, | ||
const Tensor4 & | pnd_field, | ||
const Agenda & | ppath_step_agenda, | ||
const Numeric & | ppath_lmax, | ||
const Numeric & | ppath_lraytrace, | ||
const Vector & | p_grid, | ||
const Tensor3 & | z_field, | ||
const Vector & | refellipsoid, | ||
const Tensor3 & | t_field, | ||
const Vector & | f_grid, | ||
const Index & | f_index, | ||
const Agenda & | surface_rtprop_agenda, | ||
const Index & | doit_za_interp, | ||
const Index & | normalize, | ||
const Numeric & | norm_error_threshold, | ||
const Index & | norm_debug, | ||
const Verbosity & | verbosity | ||
) |
WORKSPACE METHOD: cloudbox_fieldUpdateSeq1D.
RT calculation in cloudbox with fixed scattering integral.
Updates radiation field (cloudbox_field) in DOIT module. This method loops through the cloudbox to update the radiation field for all positions and directions in the 1D cloudbox. The method applies the sequential update. For more information refer to AUG.
[in,out] | ws | Workspace |
[in,out] | cloudbox_field_mono | WS Input/Output |
[in,out] | doit_scat_field | WS Input/Output |
[in] | cloudbox_limits | WS Input |
[in] | propmat_clearsky_agenda | WS Input |
[in] | vmr_field | WS Input |
[in] | spt_calc_agenda | WS Input |
[in] | za_grid | WS Input |
[in] | aa_grid | WS Input |
[in] | pnd_field | WS Input |
[in] | ppath_step_agenda | WS Input |
[in] | ppath_lmax | WS Input |
[in] | ppath_lraytrace | WS Input |
[in] | p_grid | WS Input |
[in] | z_field | WS Input |
[in] | refellipsoid | WS Input |
[in] | t_field | WS Input |
[in] | f_grid | WS Input |
[in] | f_index | WS Input |
[in] | surface_rtprop_agenda | WS Input |
[in] | doit_za_interp | WS Input |
[in] | normalize | Generic Input (Default: "1") |
[in] | norm_error_threshold | Generic Input (Default: "1.0") |
[in] | norm_debug | Generic Input (Default: "0") |
Definition at line 771 of file m_doit.cc.
References ARTS::Var::aa_grid(), abs, chk_if_decreasing(), chk_if_increasing(), chk_not_empty(), chk_size(), cloud_fieldsCalc(), cloud_ppath_update1D(), ARTS::Var::cloudbox_field_mono(), ARTS::Var::cloudbox_limits(), CREATE_OUT2, CREATE_OUT3, ARTS::Var::doit_scat_field(), doit_scat_fieldNormalize(), ARTS::Var::doit_za_interp(), ARTS::Var::f_grid(), ARTS::Var::f_index(), invrayjean(), is_size(), joker, ARTS::Var::p_grid(), ARTS::Var::pnd_field(), ARTS::Var::ppath_lmax(), ARTS::Var::ppath_lraytrace(), ARTS::Var::ppath_step_agenda(), ARTS::Var::propmat_clearsky_agenda(), RAD2DEG, ARTS::Var::refellipsoid(), ARTS::Var::spt_calc_agenda(), ARTS::Var::stokes_dim(), ARTS::Var::surface_rtprop_agenda(), ARTS::Var::t_field(), ARTS::Var::verbosity(), ARTS::Var::vmr_field(), ARTS::Var::z_field(), and ARTS::Var::za_grid().
Referenced by cloudbox_fieldUpdateSeq1D_g().
void cloudbox_fieldUpdateSeq1DPP | ( | Workspace & | ws, |
Tensor6 & | cloudbox_field_mono, | ||
Index & | za_index, | ||
const Tensor6 & | doit_scat_field, | ||
const ArrayOfIndex & | cloudbox_limits, | ||
const Agenda & | propmat_clearsky_agenda, | ||
const Tensor4 & | vmr_field, | ||
const Agenda & | spt_calc_agenda, | ||
const Vector & | za_grid, | ||
const Tensor4 & | pnd_field, | ||
const Vector & | p_grid, | ||
const Tensor3 & | z_field, | ||
const Tensor3 & | t_field, | ||
const Vector & | f_grid, | ||
const Index & | f_index, | ||
const Verbosity & | verbosity | ||
) |
WORKSPACE METHOD: cloudbox_fieldUpdateSeq1DPP.
RT calculation in cloudbox with fixed scattering integral.
<br> Update radiation field (cloudbox_field) in DOIT module. This method loops through the cloudbox to update the radiation field for all positions and directions in the 1D cloudbox. The method applies the sequential update and the plane parallel approximation. This method is only slightly faster than cloudbox_fieldUpdateSeq1D* and it is less accurate. It can not be used for limb simulations.
[in,out] | ws | Workspace |
[in,out] | cloudbox_field_mono | WS Input/Output |
[out] | za_index | WS Output |
[in] | doit_scat_field | WS Input |
[in] | cloudbox_limits | WS Input |
[in] | propmat_clearsky_agenda | WS Input |
[in] | vmr_field | WS Input |
[in] | spt_calc_agenda | WS Input |
[in] | za_grid | WS Input |
[in] | pnd_field | WS Input |
[in] | p_grid | WS Input |
[in] | z_field | WS Input |
[in] | t_field | WS Input |
[in] | f_grid | WS Input |
[in] | f_index | WS Input |
Definition at line 1410 of file m_doit.cc.
References ARTS::Var::aa_index(), cloud_fieldsCalc(), cloud_ppath_update1D_planeparallel(), ARTS::Var::cloudbox_field_mono(), ARTS::Var::cloudbox_limits(), CREATE_OUT2, CREATE_OUT3, ARTS::Var::doit_scat_field(), ARTS::Var::f_grid(), ARTS::Var::f_index(), is_size(), ARTS::Var::p_grid(), ARTS::Var::pnd_field(), ARTS::Var::propmat_clearsky_agenda(), ARTS::Var::spt_calc_agenda(), ARTS::Var::stokes_dim(), ARTS::Var::t_field(), ARTS::Var::verbosity(), ARTS::Var::vmr_field(), ARTS::Var::z_field(), ARTS::Var::za_grid(), and ARTS::Var::za_index().
Referenced by cloudbox_fieldUpdateSeq1DPP_g().
void cloudbox_fieldUpdateSeq3D | ( | Workspace & | ws, |
Tensor6 & | cloudbox_field_mono, | ||
const Tensor6 & | doit_scat_field, | ||
const ArrayOfIndex & | cloudbox_limits, | ||
const Agenda & | propmat_clearsky_agenda, | ||
const Tensor4 & | vmr_field, | ||
const Agenda & | spt_calc_agenda, | ||
const Vector & | za_grid, | ||
const Vector & | aa_grid, | ||
const Tensor4 & | pnd_field, | ||
const Agenda & | ppath_step_agenda, | ||
const Numeric & | ppath_lmax, | ||
const Numeric & | ppath_lraytrace, | ||
const Vector & | p_grid, | ||
const Vector & | lat_grid, | ||
const Vector & | lon_grid, | ||
const Tensor3 & | z_field, | ||
const Vector & | refellipsoid, | ||
const Tensor3 & | t_field, | ||
const Vector & | f_grid, | ||
const Index & | f_index, | ||
const Index & | doit_za_interp, | ||
const Verbosity & | verbosity | ||
) |
WORKSPACE METHOD: cloudbox_fieldUpdateSeq3D.
RT calculation in cloudbox with fixed scattering integral.
Update radiation field (cloudbox_field) in DOIT module. This method loops through the cloudbox to update the radiation field for all positions and directions in the 3D cloudbox. The method applies the sequential update. For more information please refer to AUG. Surface reflections are not yet implemented in 3D scattering calculations.
[in,out] | ws | Workspace |
[in,out] | cloudbox_field_mono | WS Input/Output |
[in] | doit_scat_field | WS Input |
[in] | cloudbox_limits | WS Input |
[in] | propmat_clearsky_agenda | WS Input |
[in] | vmr_field | WS Input |
[in] | spt_calc_agenda | WS Input |
[in] | za_grid | WS Input |
[in] | aa_grid | WS Input |
[in] | pnd_field | WS Input |
[in] | ppath_step_agenda | WS Input |
[in] | ppath_lmax | WS Input |
[in] | ppath_lraytrace | WS Input |
[in] | p_grid | WS Input |
[in] | lat_grid | WS Input |
[in] | lon_grid | WS Input |
[in] | z_field | WS Input |
[in] | refellipsoid | WS Input |
[in] | t_field | WS Input |
[in] | f_grid | WS Input |
[in] | f_index | WS Input |
[in] | doit_za_interp | WS Input |
Definition at line 1096 of file m_doit.cc.
References ARTS::Var::aa_grid(), ARTS::Var::aa_index(), chk_atm_grids(), chk_if_increasing(), chk_not_empty(), chk_size(), cloud_fieldsCalc(), cloud_ppath_update3D(), ARTS::Var::cloudbox_field_mono(), ARTS::Var::cloudbox_limits(), CREATE_OUT2, CREATE_OUT3, ARTS::Var::doit_scat_field(), ARTS::Var::doit_za_interp(), ARTS::Var::f_grid(), ARTS::Var::f_index(), is_size(), joker, ARTS::Var::lat_grid(), ARTS::Var::lon_grid(), ARTS::Var::p_grid(), ARTS::Var::pnd_field(), ARTS::Var::ppath_lmax(), ARTS::Var::ppath_lraytrace(), ARTS::Var::ppath_step_agenda(), ARTS::Var::propmat_clearsky_agenda(), RAD2DEG, ARTS::Var::refellipsoid(), ARTS::Var::spt_calc_agenda(), ARTS::Var::stokes_dim(), ARTS::Var::t_field(), ARTS::Var::verbosity(), ARTS::Var::vmr_field(), ARTS::Var::z_field(), ARTS::Var::za_grid(), and ARTS::Var::za_index().
Referenced by cloudbox_fieldUpdateSeq3D_g().
void DOAngularGridsSet | ( | Index & | doit_za_grid_size, |
Vector & | aa_grid, | ||
Vector & | za_grid, | ||
const Index & | N_za_grid, | ||
const Index & | N_aa_grid, | ||
const String & | za_grid_opt_file, | ||
const Verbosity & | verbosity | ||
) |
WORKSPACE METHOD: DOAngularGridsSet.
Sets the angular grids for Discrete Ordinate type scattering calculations.
This method sets the angular grids for the Discrete Ordinate type scattering calculations (DOIT, DISORT). For down- und up-looking geometries it suffices to define N_za_grid (both solvers) and N_aa_grid* (DOIT). From these numbers equally spaced grids are created and stored in the WSVs za_grid and aa_grid.
For limb simulations it is important to use an optimized zenith angle grid with a very fine resolution around the horizon (za=90 degrees). Such a grid can be generated using doit_za_grid_optCalc*. To be applied, the name of the file holding the optimized angle grid has to be given (za_grid_opt_file).
When an optimized grid is present, the equidistant grid is used for the calculation of the scattering integrals, while the optimized grid is applied for the integration of the radiative transfer equation. Otherwise the equidistant grid is used throughout. For down-looking cases using the equidistant grid typically suffices and speeds up the calculations.
[out] | doit_za_grid_size | WS Output |
[out] | aa_grid | WS Output |
[out] | za_grid | WS Output |
[in] | N_za_grid | Generic Input |
[in] | N_aa_grid | Generic Input (Default: "1") |
[in] | za_grid_opt_file | Generic Input (Default: "") |
Definition at line 70 of file m_doit.cc.
References ARTS::Var::aa_grid(), ARTS::Var::doit_za_grid_size(), nlinspace(), ARTS::Var::verbosity(), xml_read_from_file(), and ARTS::Var::za_grid().
Referenced by DOAngularGridsSet_g().
void doit_conv_flagAbs | ( | Index & | doit_conv_flag, |
Index & | doit_iteration_counter, | ||
Tensor6 & | cloudbox_field_mono, | ||
const Tensor6 & | cloudbox_field_mono_old, | ||
const Vector & | epsilon, | ||
const Index & | max_iterations, | ||
const Index & | nonconv_return_nan, | ||
const Verbosity & | verbosity | ||
) |
WORKSPACE METHOD: doit_conv_flagAbs.
DOIT convergence test (maximum absolute difference).
The function calculates the absolute differences for two successive iteration fields. It picks out the maximum values for each Stokes component separately. The convergence test is fullfilled under the following conditions: <br> |I(m+1) - I(m)| < epsilon_1 Intensity. <br> |Q(m+1) - Q(m)| < epsilon_2 The other Stokes components. <br> |U(m+1) - U(m)| < epsilon_3
<br> |V(m+1) - V(m)| < epsilon_4
These conditions have to be valid for all positions in the cloudbox and for all directions.
[in,out] | doit_conv_flag | WS Input/Output |
[in,out] | doit_iteration_counter | WS Input/Output |
[in,out] | cloudbox_field_mono | WS Input/Output |
[in] | cloudbox_field_mono_old | WS Input |
[in] | epsilon | Generic Input |
[in] | max_iterations | Generic Input (Default: "100") |
[in] | nonconv_return_nan | Generic Input (Default: "0") |
Definition at line 115 of file m_doit.cc.
References ARTS::Var::aa_index(), abs, ARTS::Var::cloudbox_field_mono(), ARTS::Var::cloudbox_field_mono_old(), CREATE_OUT1, CREATE_OUT2, ARTS::Var::doit_conv_flag(), ARTS::Var::doit_iteration_counter(), is_size(), ConstVectorView::nelem(), ARTS::Var::stokes_dim(), and ARTS::Var::za_index().
Referenced by doit_conv_flagAbs_g().
void doit_conv_flagAbsBT | ( | Index & | doit_conv_flag, |
Index & | doit_iteration_counter, | ||
Tensor6 & | cloudbox_field_mono, | ||
const Tensor6 & | cloudbox_field_mono_old, | ||
const Vector & | f_grid, | ||
const Index & | f_index, | ||
const Vector & | epsilon, | ||
const Index & | max_iterations, | ||
const Index & | nonconv_return_nan, | ||
const Verbosity & | verbosity | ||
) |
WORKSPACE METHOD: doit_conv_flagAbsBT.
DOIT convergence test (maximum absolute difference in Rayleigh Jeans BT)
As doit_conv_flagAbs but convergence limits are specified in Rayleigh-Jeans brighntess temperatures.
[in,out] | doit_conv_flag | WS Input/Output |
[in,out] | doit_iteration_counter | WS Input/Output |
[in,out] | cloudbox_field_mono | WS Input/Output |
[in] | cloudbox_field_mono_old | WS Input |
[in] | f_grid | WS Input |
[in] | f_index | WS Input |
[in] | epsilon | Generic Input |
[in] | max_iterations | Generic Input (Default: "100") |
[in] | nonconv_return_nan | Generic Input (Default: "0") |
Definition at line 231 of file m_doit.cc.
References ARTS::Var::aa_index(), abs, chk_if_increasing(), ARTS::Var::cloudbox_field_mono(), ARTS::Var::cloudbox_field_mono_old(), CREATE_OUT1, CREATE_OUT2, ARTS::Var::doit_conv_flag(), ARTS::Var::doit_iteration_counter(), ARTS::Var::f_grid(), ARTS::Var::f_index(), invrayjean(), is_size(), ConstVectorView::nelem(), ARTS::Var::stokes_dim(), and ARTS::Var::za_index().
Referenced by doit_conv_flagAbsBT_g().
void doit_conv_flagLsq | ( | Index & | doit_conv_flag, |
Index & | doit_iteration_counter, | ||
Tensor6 & | cloudbox_field_mono, | ||
const Tensor6 & | cloudbox_field_mono_old, | ||
const Vector & | f_grid, | ||
const Index & | f_index, | ||
const Vector & | epsilon, | ||
const Index & | max_iterations, | ||
const Index & | nonconv_return_nan, | ||
const Verbosity & | verbosity | ||
) |
WORKSPACE METHOD: doit_conv_flagLsq.
DOIT convergence test (least squares).
As doit_conv_flagAbsBT but applies a least squares convergence test between two successive iteration fields.
Warning: This method is not recommended because this kind of convergence test is not sufficiently strict, so that the DOIT result might be wrong.
[in,out] | doit_conv_flag | WS Input/Output |
[in,out] | doit_iteration_counter | WS Input/Output |
[in,out] | cloudbox_field_mono | WS Input/Output |
[in] | cloudbox_field_mono_old | WS Input |
[in] | f_grid | WS Input |
[in] | f_index | WS Input |
[in] | epsilon | Generic Input |
[in] | max_iterations | Generic Input (Default: "100") |
[in] | nonconv_return_nan | Generic Input (Default: "0") |
Definition at line 370 of file m_doit.cc.
References ARTS::Var::aa_index(), chk_if_increasing(), ARTS::Var::cloudbox_field_mono(), ARTS::Var::cloudbox_field_mono_old(), CREATE_OUT1, CREATE_OUT2, ARTS::Var::doit_conv_flag(), ARTS::Var::doit_iteration_counter(), ARTS::Var::f_grid(), ARTS::Var::f_index(), invrayjean(), is_size(), ConstVectorView::nelem(), pow(), sqrt(), ARTS::Var::stokes_dim(), and ARTS::Var::za_index().
Referenced by doit_conv_flagLsq_g().
void doit_scat_fieldCalc | ( | Workspace & | ws, |
Tensor6 & | doit_scat_field, | ||
const Agenda & | pha_mat_spt_agenda, | ||
const Tensor6 & | cloudbox_field_mono, | ||
const Tensor4 & | pnd_field, | ||
const Tensor3 & | t_field, | ||
const Index & | atmosphere_dim, | ||
const ArrayOfIndex & | cloudbox_limits, | ||
const Vector & | za_grid, | ||
const Vector & | aa_grid, | ||
const Index & | doit_za_grid_size, | ||
const Tensor7 & | pha_mat_doit, | ||
const Verbosity & | verbosity | ||
) |
WORKSPACE METHOD: doit_scat_fieldCalc.
Calculates the scattering integral field in the DOIT module.
The scattering integral field is generated by integrating the product of phase matrix and Stokes vector over all incident angles. For more information please refer to AUG.
[in,out] | ws | Workspace |
[in,out] | doit_scat_field | WS Input/Output |
[in] | pha_mat_spt_agenda | WS Input |
[in] | cloudbox_field_mono | WS Input |
[in] | pnd_field | WS Input |
[in] | t_field | WS Input |
[in] | atmosphere_dim | WS Input |
[in] | cloudbox_limits | WS Input |
[in] | za_grid | WS Input |
[in] | aa_grid | WS Input |
[in] | doit_za_grid_size | WS Input |
[in] | pha_mat_doit | WS Input |
Definition at line 2081 of file m_doit.cc.
References ARTS::Var::aa_grid(), AngIntegrate_trapezoid(), AngIntegrate_trapezoid_opti(), ARTS::Var::atmosphere_dim(), chk_not_empty(), ARTS::Var::cloudbox_field_mono(), ARTS::Var::cloudbox_limits(), CREATE_OUT2, CREATE_OUT3, ARTS::Var::doit_scat_field(), ARTS::Var::doit_za_grid_size(), is_size(), joker, ARTS::Var::pha_mat_doit(), ARTS::Var::pha_mat_spt_agenda(), pha_mat_spt_agendaExecute(), pha_matCalc(), PI, ARTS::Var::pnd_field(), ARTS::Var::stokes_dim(), ARTS::Var::t_field(), ARTS::Var::verbosity(), and ARTS::Var::za_grid().
Referenced by doit_scat_fieldCalc_g().
void doit_scat_fieldCalcLimb | ( | Workspace & | ws, |
Tensor6 & | doit_scat_field, | ||
const Agenda & | pha_mat_spt_agenda, | ||
const Tensor6 & | cloudbox_field_mono, | ||
const Tensor4 & | pnd_field, | ||
const Tensor3 & | t_field, | ||
const Index & | atmosphere_dim, | ||
const ArrayOfIndex & | cloudbox_limits, | ||
const Vector & | za_grid, | ||
const Vector & | aa_grid, | ||
const Index & | doit_za_grid_size, | ||
const Index & | doit_za_interp, | ||
const Tensor7 & | pha_mat_doit, | ||
const Verbosity & | verbosity | ||
) |
WORKSPACE METHOD: doit_scat_fieldCalcLimb.
Calculates the scattering integral field in the DOIT module (limb).
The scattering integral field is the field generated by integrating the product of phase matrix and the Stokes vector over all incident angles.
For limb simulations it makes sense to use different zenith angle grids for the scattering integral part and the RT part, because the latter part requires a much finer resolution near 90 degrees. Taking an optimized grid for the RT part and an equidistant grid for the scattering integral part saves very much CPU time. This method uses the equidistant za_grid defined in DOAngularGridsSet* and it should always be used for limb simulations.
For more information please refer to AUG.
[in,out] | ws | Workspace |
[in,out] | doit_scat_field | WS Input/Output |
[in] | pha_mat_spt_agenda | WS Input |
[in] | cloudbox_field_mono | WS Input |
[in] | pnd_field | WS Input |
[in] | t_field | WS Input |
[in] | atmosphere_dim | WS Input |
[in] | cloudbox_limits | WS Input |
[in] | za_grid | WS Input |
[in] | aa_grid | WS Input |
[in] | doit_za_grid_size | WS Input |
[in] | doit_za_interp | WS Input |
[in] | pha_mat_doit | WS Input |
Definition at line 2355 of file m_doit.cc.
References ARTS::Var::aa_grid(), AngIntegrate_trapezoid(), AngIntegrate_trapezoid_opti(), ARTS::Var::atmosphere_dim(), chk_not_empty(), ARTS::Var::cloudbox_field_mono(), ARTS::Var::cloudbox_limits(), CREATE_OUT1, CREATE_OUT2, CREATE_OUT3, ARTS::Var::doit_scat_field(), ARTS::Var::doit_za_grid_size(), ARTS::Var::doit_za_interp(), gridpos(), interp(), interp_poly(), interpweights(), is_size(), joker, ConstVectorView::nelem(), nlinspace(), ARTS::Var::pha_mat_doit(), ARTS::Var::pha_mat_spt_agenda(), pha_mat_spt_agendaExecute(), pha_matCalc(), PI, ARTS::Var::pnd_field(), ARTS::Var::stokes_dim(), ARTS::Var::t_field(), ARTS::Var::verbosity(), and ARTS::Var::za_grid().
Referenced by doit_scat_fieldCalcLimb_g().
void doit_za_grid_optCalc | ( | Vector & | doit_za_grid_opt, |
const Tensor6 & | cloudbox_field_mono, | ||
const Vector & | za_grid, | ||
const Index & | doit_za_interp, | ||
const Numeric & | acc, | ||
const Verbosity & | verbosity | ||
) |
WORKSPACE METHOD: doit_za_grid_optCalc.
Zenith angle grid optimization for scattering calculation.
This method optimizes the zenith angle grid. As input it requires a radiation field (cloudbox_field) which is calculated on a very fine zenith angle grid (za_grid). Based on this field zenith angle grid points are selected, such that the maximum difference between the radiation field represented on the very fine zenith angle grid and the radiation field represented on the optimized grid (doit_za_grid_opt) is less than the accuracy (acc). Between the grid points the radiation field is interpolated linearly or polynomially depending on doit_za_interp.
Note: The method works only for a 1D atmosphere and for one frequency.
[out] | doit_za_grid_opt | WS Output |
[in] | cloudbox_field_mono | WS Input |
[in] | za_grid | WS Input |
[in] | doit_za_interp | WS Input |
[in] | acc | Generic Input |
Definition at line 2709 of file m_doit.cc.
References chk_size(), ARTS::Var::cloudbox_field_mono(), CREATE_OUT1, ARTS::Var::doit_za_grid_opt(), ARTS::Var::doit_za_interp(), ARTS::Var::za_grid(), and za_gridOpt().
Referenced by doit_za_grid_optCalc_g().
void doit_za_interpSet | ( | Index & | doit_za_interp, |
const Index & | atmosphere_dim, | ||
const String & | interp_method, | ||
const Verbosity & | verbosity | ||
) |
WORKSPACE METHOD: doit_za_interpSet.
Define interpolation method for zenith angle dimension.
You can use this method to choose the interpolation method for interpolations in the zenith angle dimension.
[out] | doit_za_interp | WS Output |
[in] | atmosphere_dim | WS Input |
[in] | interp_method | Generic Input (Default: "linear") |
Definition at line 2770 of file m_doit.cc.
References ARTS::Var::atmosphere_dim(), chk_if_in_range(), and ARTS::Var::doit_za_interp().
Referenced by doit_za_interpSet_g().
void DoitCalc | ( | Workspace & | ws, |
Tensor7 & | cloudbox_field, | ||
const Index & | atmfields_checked, | ||
const Index & | atmgeom_checked, | ||
const Index & | cloudbox_checked, | ||
const Index & | scat_data_checked, | ||
const Index & | cloudbox_on, | ||
const Vector & | f_grid, | ||
const Agenda & | doit_mono_agenda, | ||
const Index & | doit_is_initialized, | ||
const Verbosity & | verbosity | ||
) |
WORKSPACE METHOD: DoitCalc.
Main DOIT method.
This method executes doit_mono_agenda for each frequency in f_grid. The output is the radiation field inside the cloudbox (cloudbox_field).
[in,out] | ws | Workspace |
[in,out] | cloudbox_field | WS Input/Output |
[in] | atmfields_checked | WS Input |
[in] | atmgeom_checked | WS Input |
[in] | cloudbox_checked | WS Input |
[in] | scat_data_checked | WS Input |
[in] | cloudbox_on | WS Input |
[in] | f_grid | WS Input |
[in] | doit_mono_agenda | WS Input |
[in] | doit_is_initialized | WS Input |
Definition at line 2795 of file m_doit.cc.
References ARTS::Var::atmfields_checked(), ARTS::Var::atmgeom_checked(), chk_if_increasing(), chk_not_empty(), ARTS::Var::cloudbox_checked(), ARTS::Var::cloudbox_field(), ARTS::Var::cloudbox_on(), CREATE_OUT0, CREATE_OUT2, ARTS::Var::doit_is_initialized(), ARTS::Var::doit_mono_agenda(), doit_mono_agendaExecute(), ARTS::Var::f_grid(), ARTS::Var::f_index(), joker, and ARTS::Var::scat_data_checked().
Referenced by DoitCalc_g().
void DoitGetIncoming | ( | Workspace & | ws, |
Tensor7 & | cloudbox_field, | ||
const Index & | atmfields_checked, | ||
const Index & | atmgeom_checked, | ||
const Index & | cloudbox_checked, | ||
const Index & | doit_is_initialized, | ||
const Agenda & | iy_main_agenda, | ||
const Index & | atmosphere_dim, | ||
const Vector & | lat_grid, | ||
const Vector & | lon_grid, | ||
const Tensor3 & | z_field, | ||
const EnergyLevelMap & | nlte_field, | ||
const Index & | cloudbox_on, | ||
const ArrayOfIndex & | cloudbox_limits, | ||
const Vector & | f_grid, | ||
const Index & | stokes_dim, | ||
const Vector & | za_grid, | ||
const Vector & | aa_grid, | ||
const Index & | rigorous, | ||
const Numeric & | maxratio, | ||
const Verbosity & | verbosity | ||
) |
WORKSPACE METHOD: DoitGetIncoming.
Calculates incoming radiation field of the cloudbox by repeated radiative transfer calculations.
The method performs monochromatic pencil beam calculations for all grid positions on the cloudbox boundary, and all directions given by scattering angle grids (scat_za/aa_grid). Found radiances are stored in cloudbox_field which can be used as boundary conditions when scattering inside the cloud box is solved by the DoitCalc* method.
Note that cloudbox_field will always hold intensity in terms of radiances, regardless of the setting of iy_unit (unit conversion is done within yCalc or iyCalc, which will provide their output in terms of the specified iy_unit; no explicit unit conversion by the user necessary.).
[in,out] | ws | Workspace |
[in,out] | cloudbox_field | WS Input/Output |
[in] | atmfields_checked | WS Input |
[in] | atmgeom_checked | WS Input |
[in] | cloudbox_checked | WS Input |
[in] | doit_is_initialized | WS Input |
[in] | iy_main_agenda | WS Input |
[in] | atmosphere_dim | WS Input |
[in] | lat_grid | WS Input |
[in] | lon_grid | WS Input |
[in] | z_field | WS Input |
[in] | nlte_field | WS Input |
[in] | cloudbox_on | WS Input |
[in] | cloudbox_limits | WS Input |
[in] | f_grid | WS Input |
[in] | stokes_dim | WS Input |
[in] | za_grid | WS Input |
[in] | aa_grid | WS Input |
[in] | rigorous | Generic Input (Default: "1") |
[in] | maxratio | Generic Input (Default: "100") |
Definition at line 2912 of file m_doit.cc.
References ARTS::Var::aa_grid(), ARTS::Var::aa_index(), ARTS::Var::atmfields_checked(), ARTS::Var::atmgeom_checked(), ARTS::Var::atmosphere_dim(), chk_if_in_range(), ARTS::Var::cloudbox_checked(), ARTS::Var::cloudbox_field(), ARTS::Var::cloudbox_limits(), ARTS::Var::cloudbox_on(), ARTS::Var::doit_is_initialized(), ARTS::Var::f_grid(), get_iy(), ARTS::Var::iy(), ARTS::Var::iy_main_agenda(), ARTS::Var::iy_unit(), joker, ARTS::Var::lat_grid(), ARTS::Var::lon_grid(), ARTS::Var::nlte_field(), ARTS::Var::ppath(), ARTS::Var::stokes_dim(), ARTS::Var::z_field(), ARTS::Var::za_grid(), and ARTS::Var::za_index().
Referenced by DoitGetIncoming_g().
void DoitGetIncoming1DAtm | ( | Workspace & | ws, |
Tensor7 & | cloudbox_field, | ||
Index & | cloudbox_on, | ||
const Index & | atmfields_checked, | ||
const Index & | atmgeom_checked, | ||
const Index & | cloudbox_checked, | ||
const Index & | doit_is_initialized, | ||
const Agenda & | iy_main_agenda, | ||
const Index & | atmosphere_dim, | ||
const Vector & | lat_grid, | ||
const Vector & | lon_grid, | ||
const Tensor3 & | z_field, | ||
const EnergyLevelMap & | nlte_field, | ||
const ArrayOfIndex & | cloudbox_limits, | ||
const Vector & | f_grid, | ||
const Index & | stokes_dim, | ||
const Vector & | za_grid, | ||
const Vector & | aa_grid, | ||
const Verbosity & | verbosity | ||
) |
WORKSPACE METHOD: DoitGetIncoming1DAtm.
As DoitGetIncoming but assumes clear sky part to be 1D. The incoming field is calculated only for one position and azimuth angle for each cloud box boundary, and obtained values are used for all other postions and azimuth angles. This works if a 3D cloud box is put into an 1D background atmosphere.
This method can only be used for 3D cases.
[in,out] | ws | Workspace |
[in,out] | cloudbox_field | WS Input/Output |
[in,out] | cloudbox_on | WS Input/Output |
[in] | atmfields_checked | WS Input |
[in] | atmgeom_checked | WS Input |
[in] | cloudbox_checked | WS Input |
[in] | doit_is_initialized | WS Input |
[in] | iy_main_agenda | WS Input |
[in] | atmosphere_dim | WS Input |
[in] | lat_grid | WS Input |
[in] | lon_grid | WS Input |
[in] | z_field | WS Input |
[in] | nlte_field | WS Input |
[in] | cloudbox_limits | WS Input |
[in] | f_grid | WS Input |
[in] | stokes_dim | WS Input |
[in] | za_grid | WS Input |
[in] | aa_grid | WS Input |
Definition at line 3208 of file m_doit.cc.
References ARTS::Var::aa_grid(), ARTS::Var::aa_index(), ARTS::Var::atmfields_checked(), ARTS::Var::atmgeom_checked(), ARTS::Var::atmosphere_dim(), chk_if_in_range(), ARTS::Var::cloudbox_checked(), ARTS::Var::cloudbox_field(), ARTS::Var::cloudbox_limits(), ARTS::Var::cloudbox_on(), ARTS::Var::doit_is_initialized(), ARTS::Var::f_grid(), get_iy(), ARTS::Var::iy(), ARTS::Var::iy_main_agenda(), ARTS::Var::iy_unit(), joker, ARTS::Var::lat(), ARTS::Var::lat_grid(), ARTS::Var::lon(), ARTS::Var::lon_grid(), ARTS::Var::nlte_field(), ARTS::Var::ppath(), ARTS::Var::stokes_dim(), ARTS::Var::z_field(), ARTS::Var::za_grid(), and ARTS::Var::za_index().
Referenced by DoitGetIncoming1DAtm_g().
void DoitInit | ( | Tensor6 & | doit_scat_field, |
Tensor7 & | cloudbox_field, | ||
Index & | doit_is_initialized, | ||
const Index & | stokes_dim, | ||
const Index & | atmosphere_dim, | ||
const Vector & | f_grid, | ||
const Vector & | za_grid, | ||
const Vector & | aa_grid, | ||
const Index & | doit_za_grid_size, | ||
const Index & | cloudbox_on, | ||
const ArrayOfIndex & | cloudbox_limits, | ||
const Verbosity & | verbosity | ||
) |
WORKSPACE METHOD: DoitInit.
Initialises variables for DOIT scattering calculations.
Note that multi-dimensional output variables (Tensors, specifically) are NaN-initialized. That is, this methods needs to be called BEFORE other WSMs that provide input to DoitCalc, e.g. before DoitGetIncoming*.
[out] | doit_scat_field | WS Output |
[out] | cloudbox_field | WS Output |
[out] | doit_is_initialized | WS Output |
[in] | stokes_dim | WS Input |
[in] | atmosphere_dim | WS Input |
[in] | f_grid | WS Input |
[in] | za_grid | WS Input |
[in] | aa_grid | WS Input |
[in] | doit_za_grid_size | WS Input |
[in] | cloudbox_on | WS Input |
[in] | cloudbox_limits | WS Input |
Definition at line 1582 of file m_doit.cc.
References ARTS::Var::aa_grid(), ARTS::Var::atmosphere_dim(), chk_if_in_range(), ARTS::Var::cloudbox_field(), ARTS::Var::cloudbox_limits(), ARTS::Var::cloudbox_on(), CREATE_OUT0, CREATE_OUT1, ARTS::Var::doit_is_initialized(), ARTS::Var::doit_scat_field(), ARTS::Var::doit_za_grid_size(), ARTS::Var::f_grid(), is_increasing(), ARTS::Var::stokes_dim(), and ARTS::Var::za_grid().
Referenced by DoitInit_g().
void DoitWriteIterationFields | ( | const Index & | doit_iteration_counter, |
const Tensor6 & | cloudbox_field_mono, | ||
const Index & | f_index, | ||
const ArrayOfIndex & | iterations, | ||
const ArrayOfIndex & | frequencies, | ||
const Verbosity & | verbosity | ||
) |
WORKSPACE METHOD: DoitWriteIterationFields.
Writes DOIT iteration fields.
This method writes intermediate iteration fields to xml-files. The method can be used as a part of doit_conv_test_agenda.
The iterations to be stored are specified by iterations, e.g.: <br> iterations = [3, 6, 9] In this case the 3rd, 6th and 9th iterations are stored. If a number is larger than the total number of iterations, this number is ignored. If all iterations should be stored set <br> iterations = [-1]
The frequencies to be stored are specified by frequencies in the same way as the iterations. The frequency index corresponds to the order of frequencies in f_grid.
The output files are named doit_iteration_fX_iY.xml with X being the frequency index and iY the iteration counter.
[in] | doit_iteration_counter | WS Input |
[in] | cloudbox_field_mono | WS Input |
[in] | f_index | WS Input |
[in] | iterations | Generic Input (Default: "[-1]") |
[in] | frequencies | Generic Input (Default: "[-1]") |
Definition at line 2032 of file m_doit.cc.
References ARTS::Var::cloudbox_field_mono(), ARTS::Var::doit_iteration_counter(), ARTS::Var::f_index(), FILE_TYPE_ASCII, Array< base >::nelem(), ARTS::Var::verbosity(), and xml_write_to_file().
Referenced by DoitWriteIterationFields_g().
void OptimizeDoitPressureGrid | ( | Workspace & | ws, |
Vector & | p_grid, | ||
Tensor4 & | pnd_field, | ||
Tensor3 & | t_field, | ||
ArrayOfArrayOfSingleScatteringData & | scat_data_mono, | ||
Tensor3 & | z_field, | ||
ArrayOfIndex & | cloudbox_limits, | ||
Tensor6 & | cloudbox_field_mono, | ||
Tensor7 & | pha_mat_doit, | ||
Tensor4 & | vmr_field, | ||
Vector & | p_grid_orig, | ||
const Vector & | f_grid, | ||
const Index & | f_index, | ||
const Agenda & | propmat_clearsky_agenda, | ||
const Numeric & | tau_scat_max, | ||
const Numeric & | sgl_alb_max, | ||
const Index & | cloudbox_size_max, | ||
const Verbosity & | verbosity | ||
) |
WORKSPACE METHOD: OptimizeDoitPressureGrid.
Optimization of the pressure grid for RT calculation. The methods consists of three parts: 1) Calculate the single scattering albedo and the scattering opticalthickness from the scattering and absorption species. 2) Enhance z_field according to the two thresholds sgl_alb_max and tau_scat_max.If the resulting cloudbox size is bigger than cloudbox_size_max, this step is repeated with a higher threshold of tau_scat_max. 3) Interpolate all variables used in doit_mono_agenda to the new z_field This method should be called inside doit_mono_agenda*, right before cloudbox_field_monoIterate. It can only be used if ScatSpeciesMerge has been called and if it is called, cloudbox_field_monoOptimizeReverse has to be called right after cloudbox_field_monoIterate to interpolate cloudbox_field_mono* back to the original size. Optimization currently only works with stokes_dim = 1 .
[in,out] | ws | Workspace |
[in,out] | p_grid | WS Input/Output |
[in,out] | pnd_field | WS Input/Output |
[in,out] | t_field | WS Input/Output |
[in,out] | scat_data_mono | WS Input/Output |
[in,out] | z_field | WS Input/Output |
[in,out] | cloudbox_limits | WS Input/Output |
[in,out] | cloudbox_field_mono | WS Input/Output |
[in,out] | pha_mat_doit | WS Input/Output |
[in,out] | vmr_field | WS Input/Output |
[out] | p_grid_orig | WS Output |
[in] | f_grid | WS Input |
[in] | f_index | WS Input |
[in] | propmat_clearsky_agenda | WS Input |
[in] | tau_scat_max | Generic Input (Default: "0.1") |
[in] | sgl_alb_max | Generic Input (Default: "0.9") |
[in] | cloudbox_size_max | Generic Input (Default: "200") |
Definition at line 1732 of file m_doit.cc.
References ARTS::Var::abs_vec(), ARTS::Var::cloudbox_field_mono(), ARTS::Var::cloudbox_limits(), CREATE_OUT2, CREATE_OUT3, ARTS::Var::ext_mat(), ARTS::Var::p_grid(), ARTS::Var::p_grid_orig(), ARTS::Var::pnd_field(), ARTS::Var::scat_data_mono(), and ARTS::Var::z_field().
Referenced by OptimizeDoitPressureGrid_g().
|
extern |
Referenced by doit_scat_fieldCalc(), and doit_scat_fieldCalcLimb().
|
extern |
Referenced by cloudbox_fieldUpdateSeq1D(), and cloudbox_fieldUpdateSeq3D().