Go to the documentation of this file.
75 throw runtime_error(
"No need to use this method with *iy_unit* = \"1\".");
79 os <<
"The spectrum matrix *iy* is required to have original radiance\n"
80 <<
"unit, but this seems not to be the case. This as a value above\n"
81 <<
"1e-3 is found in *iy*.";
82 throw runtime_error(os.str());
125 "The atmospheric fields must be flagged to have\n"
126 "passed a consistency check (atmfields_checked=1).");
129 "The atmospheric geometry must be flagged to have\n"
130 "passed a consistency check (atmgeom_checked=1).");
133 "The cloudbox must be flagged to have\n"
134 "passed a consistency check (cloudbox_checked=1).");
138 "The scattering data must be flagged to have\n"
139 "passed a consistency check (scat_data_checked=1).");
165 for (
Index i = 0; i <
iy.nrows(); i++) {
166 if (std::isnan(
iy(i, 0)))
167 throw runtime_error(
"One or several NaNs found in *iy*.");
228 if (rbi < 1 || rbi > 9)
230 "ppath.background is invalid. Check your "
231 "calculation of *ppath*?");
234 "A secondary propagation path starting at the "
235 "surface and is going directly into the surface "
236 "is found. This is not allowed.");
240 Index j_analytical_do = 0;
245 ArrayOfIndex jac_species_i(nq), jac_scat_i(nq), jac_is_t(nq), jac_wind_i(nq);
248 if (j_analytical_do) {
276 Index auxOptDepth = -1;
278 for (
Index i = 0; i < naux; i++) {
288 os <<
"The only allowed strings in *iy_aux_vars* are:\n"
289 <<
" \"Radiative background\"\n"
290 <<
" \"Optical depth\"\n"
291 <<
"but you have selected: \"" <<
iy_aux_vars[i] <<
"\"";
292 throw runtime_error(os.str());
315 if (np == 1 && rbi == 1) {
359 Index temperature_derivative_position = -1;
362 if (j_analytical_do) {
370 temperature_derivative_position = iq;
375 const bool temperature_jacobian =
379 for (
Index ip = 0; ip < np; ip++) {
423 do_hse ?
ppath.lstep[ip - 1] / (2.0 *
ppvar_t[ip - 1]) : 0;
436 temperature_derivative_position);
452 swap(K_past, K_this);
453 swap(dK_past_dx, dK_this_dx);
463 iy_trans_new = tot_tra[np - 1];
468 if (auxOptDepth >= 0)
469 for (
Index iv = 0; iv < nf; iv++)
470 iy_aux[auxOptDepth](iv, 0) = -std::log(tot_tra[np - 1](iv, 0, 0));
496 lvl_rad[np - 1] =
iy;
499 for (
Index ip = np - 2; ip >= 0; ip--) {
500 lvl_rad[ip] = lvl_rad[ip + 1];
510 dlyr_tra_above[ip + 1],
511 dlyr_tra_below[ip + 1],
512 RadiativeTransferSolver::Emission);
517 for (
Index ip = 0; ip < lvl_rad.
nelem(); ip++) {
527 if (j_analytical_do) {
620 if (rbi < 1 || rbi > 9)
622 "ppath.background is invalid. Check your "
623 "calculation of *ppath*?");
626 "A secondary propagation path starting at the "
627 "surface and is going directly into the surface "
628 "is found. This is not allowed.");
632 Index j_analytical_do = 0;
637 ArrayOfIndex jac_species_i(nq), jac_scat_i(nq), jac_is_t(nq), jac_wind_i(nq);
640 if (j_analytical_do) {
668 Index auxOptDepth = -1;
670 for (
Index i = 0; i < naux; i++) {
680 os <<
"The only allowed strings in *iy_aux_vars* are:\n"
681 <<
" \"Radiative background\"\n"
682 <<
" \"Optical depth\"\n"
683 <<
"but you have selected: \"" <<
iy_aux_vars[i] <<
"\"";
684 throw runtime_error(os.str());
707 if (np == 1 && rbi == 1) {
745 for (
Index ip = 0; ip < np; ip++) {
755 Index temperature_derivative_position = -1;
758 if (j_analytical_do) {
760 for (
Index ip = 0; ip < np; ip++) {
761 dK_dx[ip].resize(nq);
767 temperature_derivative_position = iq;
771 const bool temperature_jacobian =
777 bool do_abort =
false;
780 #pragma omp parallel for if (!arts_omp_in_parallel()) \
781 firstprivate(l_ws, l_propmat_clearsky_agenda, a, B, dB_dT, S, da_dx, dS_dx)
782 for (
Index ip = 0; ip < np; ip++) {
783 if (do_abort)
continue;
794 l_propmat_clearsky_agenda,
838 }
catch (
const std::runtime_error& e) {
840 os <<
"Runtime-error in source calculation at index " << ip
843 #pragma omp critical(iyEmissionStandard_source)
846 fail_msg.push_back(os.str());
851 #pragma omp parallel for if (!arts_omp_in_parallel())
852 for (
Index ip = 1; ip < np; ip++) {
853 if (do_abort)
continue;
856 do_hse ?
ppath.lstep[ip - 1] / (2.0 *
ppvar_t[ip - 1]) : 0;
869 temperature_derivative_position);
870 }
catch (
const std::runtime_error& e) {
872 os <<
"Runtime-error in transmission calculation at index " << ip
875 #pragma omp critical(iyEmissionStandard_transmission)
878 fail_msg.push_back(os.str());
884 std::ostringstream os;
885 os <<
"Error messages from failed cases:\n";
886 for (
const auto& msg : fail_msg) {
889 throw std::runtime_error(os.str());
899 iy_trans_new = tot_tra[np - 1];
904 if (auxOptDepth >= 0)
905 for (
Index iv = 0; iv < nf; iv++)
906 iy_aux[auxOptDepth](iv, 0) = -std::log(tot_tra[np - 1](iv, 0, 0));
932 lvl_rad[np - 1] =
iy;
935 for (
Index ip = np - 2; ip >= 0; ip--) {
936 lvl_rad[ip] = lvl_rad[ip + 1];
946 dlyr_tra_above[ip + 1],
947 dlyr_tra_below[ip + 1],
948 RadiativeTransferSolver::Emission);
953 for (
Index ip = 0; ip < lvl_rad.
nelem(); ip++) {
963 if (j_analytical_do) {
1039 const Index& return_atm1d,
1040 const Index& skip_vmr,
1041 const Index& skip_pnd,
1042 const Index& return_masses,
1046 throw runtime_error(
1047 "Jacobians not provided by the method, *jacobian_do* "
1050 throw runtime_error(
1051 "This method does not yet support non-empty *nlte_field*.");
1053 throw runtime_error(
1054 "This method does not yet support non-empty *wind_u_field*.");
1056 throw runtime_error(
1057 "This method does not yet support non-empty *wind_v_field*.");
1059 throw runtime_error(
1060 "This method does not yet support non-empty *wind_w_field*.");
1062 throw runtime_error(
1063 "This method does not yet support non-empty *mag_u_field*.");
1065 throw runtime_error(
1066 "This method does not yet support non-empty *mag_v_field*.");
1068 throw runtime_error(
1069 "This method does not yet support non-empty *mag_w_field*.");
1071 if (return_masses) {
1073 throw runtime_error(
1074 "Sizes of *pnd_field* and *particle_masses* "
1075 "are inconsistent.");
1140 gp_p[i] =
ppath.gp_p[ip];
1142 gp_lat[i] =
ppath.gp_lat[ip];
1144 gp_lon[i] =
ppath.gp_lon[ip];
1151 gp_p[i] = ppath2.
gp_p[ip];
1153 gp_lat[i] = ppath2.
gp_lat[ip];
1155 gp_lon[i] = ppath2.
gp_lon[ip];
1161 for (
Index i = 0; i < ppath2.
np - 1; i++) {
1162 const Index ip = ppath2.
np - i - 1;
1163 gp_p[i] = ppath2.
gp_p[ip];
1165 gp_lat[i] = ppath2.
gp_lat[ip];
1167 gp_lon[i] = ppath2.
gp_lon[ip];
1172 for (
Index i = ppath2.
np - 1; i < np; i++) {
1173 const Index ip = i - ppath2.
np + 1;
1174 gp_p[i] =
ppath.gp_p[ip];
1176 gp_lat[i] =
ppath.gp_lat[ip];
1178 gp_lon[i] =
ppath.gp_lon[ip];
1193 Vector lat_true1(1), lon_true1(1);
1238 zsurf1(0, 0) = z1(0, 0, 0);
1260 for (
Index i = 0; i < np; i++) {
1284 const Index extra_bot = ifirst == 0 ? 0 : 1;
1285 const Index extra_top = ilast == np - 1 ? 0 : 1;
1287 cbox_lims1.resize(2);
1288 cbox_lims1[0] = ifirst - extra_bot;
1289 cbox_lims1[1] = ilast + extra_top;
1293 pnd1.
resize(
pnd_field.nbooks(), cbox_lims1[1] - cbox_lims1[0] + 1, 1, 1);
1297 for (
Index i = extra_bot; i < pnd1.
npages() - extra_top; i++) {
1298 const Index i0 = cbox_lims1[0] + i;
1325 const Index adim1 = 1;
1368 const Index ntot = 2 + nvmr + npnd + nmass;
1373 field_names[0] =
"Geometric altitudes";
1377 field_names[1] =
"Temperature";
1382 for (
Index i = 0; i < nvmr; i++) {
1383 const Index iout = 2 + i;
1385 sstr <<
"VMR species " << i;
1386 field_names[iout] = sstr.str();
1393 for (
Index i = 0; i < npnd; i++) {
1394 const Index iout = 2 + nvmr + i;
1396 sstr <<
"Scattering element " << i;
1397 field_names[iout] = sstr.str();
1400 iout,
Range(cbox_lims1[0], pnd1.
npages()), 0, 0) =
1401 pnd1(i,
joker, 0, 0);
1407 for (
Index i = 0; i < nmass; i++) {
1408 const Index iout = 2 + nvmr + npnd + i;
1410 sstr <<
"Mass category " << i;
1411 field_names[iout] = sstr.str();
1413 for (
Index ip = cbox_lims1[0]; ip < pnd1.
npages(); ip++) {
1425 "Data created by *iyIndependentBeamApproximation*");
1428 "Atmospheric quantity");
1457 throw runtime_error(
1458 "Recursive usage not possible (iy_agenda_call1 must be 1).");
1460 throw runtime_error(
"*iy_transmission* must be empty.");
1464 for (
Index i = 0; i < nf; i++) {
1549 const Index& t_interp_order,
1553 throw runtime_error(
1554 "Only 3D atmospheres are allowed (atmosphere_dim must be 3)");
1556 throw runtime_error(
1557 "The cloudbox must be activated (cloudbox_on must be 1)");
1559 throw runtime_error(
1560 "This method does not provide any jacobians (jacobian_do must be 0)");
1562 throw runtime_error(
1563 "Recursive usage not possible (iy_agenda_call1 must be 1)");
1565 throw runtime_error(
"*iy_transmission* must be empty");
1575 Index auxError = -1;
1580 for (
Index i = 0; i < naux; i++) {
1586 os <<
"In *iy_aux_vars* you have included: \"" <<
iy_aux_vars[i]
1587 <<
"\"\nThis choice is not recognised.";
1588 throw runtime_error(os.str());
1600 Matrix pos(1, 3), los(1, 2);
1612 bool failed =
false;
1615 #pragma omp parallel for if (!arts_omp_in_parallel() && nf > 1) \
1616 firstprivate(l_ws, \
1617 l_ppath_step_agenda, \
1618 l_iy_space_agenda, \
1619 l_propmat_clearsky_agenda, \
1620 l_surface_rtprop_agenda)
1622 if (failed)
continue;
1649 l_ppath_step_agenda,
1653 l_surface_rtprop_agenda,
1654 l_propmat_clearsky_agenda,
1686 if (auxError >= 0) {
1689 }
catch (
const std::exception& e) {
1694 #pragma omp critical(iyMC_fail)
1697 fail_msg = os.str();
1703 if (failed)
throw runtime_error(fail_msg);
1714 throw runtime_error(
1715 "*iy_aux* and *iy_aux_vars* must have the same "
1716 "number of elements.");
1719 throw runtime_error(
1720 "This method can not provide any jacobians and "
1721 "*jacobian_do* must be 0.");
1725 for (
Index i = 0; i <
iy_aux.nelem() && !ready; i++) {
1733 throw runtime_error(
1734 "The selected auxiliary variable to insert in *iy* "
1735 "is either not defined at all or is not set.");
1791 throw runtime_error(
"The frequency grid is empty.");
1795 throw runtime_error(
"All frequencies in *f_grid* must be > 0.");
1799 throw runtime_error(
1800 "The atmospheric fields must be flagged to have\n"
1801 "passed a consistency check (atmfields_checked=1).");
1803 throw runtime_error(
1804 "The atmospheric geometry must be flagged to have\n"
1805 "passed a consistency check (atmgeom_checked=1).");
1807 throw runtime_error(
1808 "The cloudbox must be flagged to have\n"
1809 "passed a consistency check (cloudbox_checked=1).");
1812 throw runtime_error(
1813 "The scattering data must be flagged to have\n"
1814 "passed a consistency check (scat_data_checked=1).");
1816 throw runtime_error(
1817 "The sensor variables must be flagged to have\n"
1818 "passed a consistency check (sensor_checked=1).");
1833 y.resize(nmblock * n1y);
1834 y_f.resize(nmblock * n1y);
1835 y_pol.resize(nmblock * n1y);
1838 y_geo.resize(nmblock * n1y, 5);
1847 Index j_analytical_do = 0;
1854 jacobian_indices[jacobian_indices.
nelem() - 1][1] + 1);
1867 bool failed =
false;
1870 (nf <= nmblock && nmblock >= nlos)) {
1871 out3 <<
" Parallelizing mblock loop (" << nmblock <<
" iterations)\n";
1880 #pragma omp parallel for firstprivate( \
1881 l_ws, l_jacobian_agenda, l_iy_main_agenda, l_geo_pos_agenda)
1884 if (failed)
continue;
1924 out3 <<
" Not parallelizing mblock loop (" << nmblock <<
" iterations)\n";
1928 if (failed)
continue;
1970 if (failed)
throw runtime_error(fail_msg);
1978 y_aux[
q].resize(nmblock * n1y);
1981 const Range rowind =
1988 for (
Index i = 0; i < n1y; i++) {
1989 const Index row = row0 + i;
1991 for (
Index j = 0; j < niyb; j++) {
2041 const Index& append_instrument_wfs,
2048 jacobian_indices_copy, any_affine, jacobian_quantities_copy,
true);
2053 const Index n1 =
y.nelem();
2055 if (
y.empty())
throw runtime_error(
"Input *y* is empty. Use *yCalc*");
2056 if (
y_f.nelem() != n1)
2057 throw runtime_error(
"Lengths of input *y* and *y_f* are inconsistent.");
2058 if (
y_pol.nelem() != n1)
2059 throw runtime_error(
"Lengths of input *y* and *y_pol* are inconsistent.");
2060 if (
y_pos.nrows() != n1)
2061 throw runtime_error(
"Sizes of input *y* and *y_pos* are inconsistent.");
2062 if (
y_los.nrows() != n1)
2063 throw runtime_error(
"Sizes of input *y* and *y_los* are inconsistent.");
2064 if (
y_geo.nrows() != n1)
2065 throw runtime_error(
"Sizes of input *y* and *y_geo* are inconsistent.");
2067 nrq1 = jacobian_quantities_copy.
nelem();
2069 throw runtime_error(
"Sizes of *y* and *jacobian* are inconsistent.");
2070 if (
jacobian.ncols() != jacobian_indices_copy[nrq1 - 1][1] + 1)
2071 throw runtime_error(
2072 "Size of input *jacobian* and size implied "
2073 "*jacobian_quantities_copy* are inconsistent.");
2079 Matrix y_pos2, y_los2, y_geo2, jacobian2;
2121 throw runtime_error(
2122 "Different number of columns in *y_pos* between the measurements.");
2124 throw runtime_error(
2125 "Different number of columns in *y_los* between the measurements.");
2142 y_f.resize(n1 + n2);
2150 y_los.resize(n1 + n2, y_los1.ncols());
2154 y_geo.resize(n1 + n2, y_geo1.ncols());
2158 y_pol.resize(n1 + n2);
2159 for (
Index i = 0; i < n1; i++) {
2160 y_pol[i] = y_pol1[i];
2162 for (
Index i = 0; i < n2; i++) {
2163 y_pol[n1 + i] = y_pol2[i];
2173 for (
Index a = 0; a < na; a++) {
2174 y_aux[a].resize(n1 + n2);
2196 jacobian_indices = jacobian_indices_copy;
2201 const Index nrq2 = jacobian_quantities2.
nelem();
2204 for (
Index q2 = 0; q2 < nrq2; q2++) {
2214 append_instrument_wfs) {
2216 if (jacobian_quantities2[q2].MainTag() ==
2217 jacobian_quantities_copy[
q1].MainTag()) {
2220 if (jacobian_quantities2[q2].Subtag() ==
2221 jacobian_quantities_copy[
q1].Subtag()) {
2222 if (jacobian_quantities2[q2].Mode() ==
2223 jacobian_quantities_copy[
q1].Mode()) {
2227 os <<
"Jacobians for " << jacobian_quantities2[q2].MainTag()
2228 <<
"/" << jacobian_quantities2[q2].Subtag()
2229 <<
" shall be appended.\nThis requires "
2230 <<
"that the same retrieval unit is used "
2231 <<
"but it seems that this requirement is "
2233 throw runtime_error(os.str());
2238 else if (jacobian_quantities2[q2].MainTag() ==
2240 if (jacobian_quantities2[q2].Subtag() ==
2241 jacobian_quantities_copy[
q1].Subtag()) {
2245 os <<
"Jacobians for " << jacobian_quantities2[q2].MainTag()
2246 <<
"/" << jacobian_quantities2[q2].Subtag()
2247 <<
" shall be appended.\nThis requires "
2248 <<
"that HSE is either ON or OFF for both "
2249 <<
"parts but it seems that this requirement "
2251 throw runtime_error(os.str());
2255 if ((jacobian_quantities2[q2].MainTag() ==
2256 jacobian_quantities_copy[
q1].MainTag()) &&
2257 (jacobian_quantities2[q2].Subtag() ==
2258 jacobian_quantities_copy[
q1].Subtag()) &&
2259 (jacobian_quantities2[q2].SubSubtag() ==
2260 jacobian_quantities_copy[
q1].SubSubtag())) {
2265 else if (jacobian_quantities2[q2].Subtag() ==
2266 jacobian_quantities_copy[
q1].Subtag()) {
2278 indices[0] = jacobian_indices[jacobian_indices.
nelem() - 1][1] + 1;
2280 indices[0] + jacobian_indices2[q2][1] - jacobian_indices2[q2][0];
2281 jacobian_indices.push_back(indices);
2285 map_table[q2] = pos;
2287 ArrayOfVector grids1 = jacobian_quantities_copy[pos].Grids();
2289 bool any_wrong =
false;
2294 if (grids1[g].
nelem() != grids2[g].
nelem()) {
2297 for (
Index e = 0; e < grids1[g].
nelem(); e++) {
2298 const Numeric v1 = grids1[g][e];
2299 const Numeric v2 = grids2[g][e];
2300 if ((v1 == 0 &&
abs(v2) > 1e-9) ||
abs(v1 - v2) / v1 > 1e-6) {
2309 os <<
"Jacobians for " << jacobian_quantities2[q2].MainTag() <<
"/"
2310 << jacobian_quantities2[q2].Subtag()
2311 <<
" shall be appended.\nThis requires that the "
2312 <<
"same grids are used for both measurements,\nbut "
2313 <<
"it seems that this requirement is not met.";
2314 throw runtime_error(os.str());
2324 jacobian.resize(n1 + n2, jacobian_indices[nrq - 1][1] + 1);
2331 for (
Index q2 = 0; q2 < nrq2; q2++) {
2333 Range(jacobian_indices[map_table[q2]][0],
2334 jacobian_indices[map_table[q2]][1] -
2335 jacobian_indices[map_table[q2]][0] + 1)) =
2338 Range(jacobian_indices2[q2][0],
2339 jacobian_indices2[q2][1] - jacobian_indices2[q2][0] + 1));
2352 throw runtime_error(
"No need to use this method with *iy_unit* = \"1\".");
2355 if (
max(
y) > 1e-3) {
2357 os <<
"The spectrum vector *y* is required to have original radiance\n"
2358 <<
"unit, but this seems not to be the case. This as a value above\n"
2359 <<
"1e-3 is found in *y*.";
2360 throw runtime_error(os.str());
2365 const Index ny =
y.nelem();
2367 const bool do_j =
jacobian.nrows() == ny;
2372 os <<
"The method can not be used with jacobian quantities that are not\n"
2373 <<
"obtained through radiative transfer calculations. One example on\n"
2374 <<
"quantity that can not be handled is *jacobianAddPolyfit*.\n"
2375 <<
"The maximum value of *jacobian* indicates that one or several\n"
2376 <<
"such jacobian quantities are included.";
2377 throw runtime_error(os.str());
2395 while (i0 + n < ny &&
y_f[i0] ==
y_f[i0 + n]) {
2401 bool any_quv =
false;
2403 for (
Index i = 0; i < n; i++) {
2404 const Index ix = i0 + i;
2406 i_pol[i] =
y_pol[ix];
2407 if (i_pol[i] > 1 && i_pol[i] < 5) {
2416 if (any_quv && i_pol[0] != 1) {
2418 os <<
"The conversion to PlanckBT, of the Jacobian and "
2419 <<
"errors for Q, U and V, requires that I (first Stokes "
2420 <<
"element) is at hand and that the data are sorted in "
2421 <<
"such way that I comes first for each frequency.";
2422 throw runtime_error(os.str());
2448 for (
Index i = 0; i < ny; i++) {
2450 i_pol[0] =
y_pol[i];
Index mc_iteration_count(Workspace &ws) noexcept
Matrix ppvar_mag(Workspace &ws) noexcept
Matrix y_pos(Workspace &ws) noexcept
Tensor4 ppvar_trans_partial(Workspace &ws) noexcept
Index atmosphere_dim(Workspace &ws) noexcept
std::size_t pos() const noexcept
Tensor3 wind_v_field(Workspace &ws) noexcept
void adapt_stepwise_partial_derivatives(ArrayOfPropagationMatrix &dK_dx, ArrayOfStokesVector &dS_dx, const ArrayOfRetrievalQuantity &jacobian_quantities, ConstVectorView ppath_f_grid, ConstVectorView ppath_line_of_sight, ConstVectorView ppath_vmrs, const Numeric &ppath_temperature, const Numeric &ppath_pressure, const ArrayOfIndex &jacobian_species, const ArrayOfIndex &jacobian_wind, const Index <e, const Index &atmosphere_dim, const bool &jacobian_do)
Adapts clearsky partial derivatives.
void transform(VectorView y, double(&my_func)(double), ConstVectorView x)
A generic transform function for vectors, which can be used to implement mathematical functions opera...
const String ABSSPECIES_MAINTAG
ArrayOfVector y_aux(Workspace &ws) noexcept
Range get_rowindex_for_mblock(const Sparse &sensor_response, const Index &mblock_index)
Returns the "range" of y corresponding to a measurement block.
Tensor3 z_field(Workspace &ws) noexcept
void resize(Index b, Index p, Index r, Index c)
Resize function.
const String SURFACE_MAINTAG
void iy_independent_beam_approx_agendaExecute(Workspace &ws, Matrix &iy, ArrayOfMatrix &iy_aux, Ppath &ppath, ArrayOfTensor3 &diy_dx, const Index iy_agenda_call1, const String &iy_unit, const Tensor3 &iy_transmission, const ArrayOfString &iy_aux_vars, const Index iy_id, const Index atmosphere_dim, const Vector &p_grid, const Vector &lat_grid, const Vector &lon_grid, const Vector &lat_true, const Vector &lon_true, const Tensor3 &t_field, const Tensor3 &z_field, const Tensor4 &vmr_field, const Matrix &z_surface, const Numeric ppath_lmax, const Numeric ppath_lraytrace, const Index cloudbox_on, const ArrayOfIndex &cloudbox_limits, const Tensor4 &pnd_field, const Index jacobian_do, const Vector &f_grid, const Vector &rte_pos, const Vector &rte_los, const Vector &rte_pos2, const Agenda &input_agenda)
PropagationMatrix PropagationMatrix
Stokes vector is as Propagation matrix but only has 4 possible values.
Agenda ppath_step_agenda(Workspace &ws) noexcept
const String SCATSPECIES_MAINTAG
Agenda iy_cloudbox_agenda(Workspace &ws) noexcept
Index atmgeom_checked(Workspace &ws) noexcept
ArrayOfRetrievalQuantity jacobian_quantities(Workspace &ws) noexcept
Matrix transmitter_pos(Workspace &ws) noexcept
void ppath_agendaExecute(Workspace &ws, Ppath &ppath, const Numeric ppath_lmax, const Numeric ppath_lraytrace, const Vector &rte_pos, const Vector &rte_los, const Vector &rte_pos2, const Index cloudbox_on, const Index ppath_inside_cloudbox_do, const Vector &f_grid, const Agenda &input_agenda)
void yCalc_mblock_loop_body(bool &failed, String &fail_msg, ArrayOfArrayOfVector &iyb_aux_array, Workspace &ws, Vector &y, Vector &y_f, ArrayOfIndex &y_pol, Matrix &y_pos, Matrix &y_los, Matrix &y_geo, Matrix &jacobian, const Index &atmosphere_dim, const EnergyLevelMap &nlte_field, const Index &cloudbox_on, const Index &stokes_dim, const Vector &f_grid, const Matrix &sensor_pos, const Matrix &sensor_los, const Matrix &transmitter_pos, const Matrix &mblock_dlos_grid, const Sparse &sensor_response, const Vector &sensor_response_f, const ArrayOfIndex &sensor_response_pol, const Matrix &sensor_response_dlos, const String &iy_unit, const Agenda &iy_main_agenda, const Agenda &geo_pos_agenda, const Agenda &jacobian_agenda, const Index &jacobian_do, const ArrayOfRetrievalQuantity &jacobian_quantities, const ArrayOfArrayOfIndex &jacobian_indices, const ArrayOfString &iy_aux_vars, const Verbosity &verbosity, const Index &mblock_index, const Index &n1y, const Index &j_analytical_do)
Performs calculations for one measurement block, on y-level.
void iy_loop_freqs_agendaExecute(Workspace &ws, Matrix &iy, ArrayOfMatrix &iy_aux, Ppath &ppath, ArrayOfTensor3 &diy_dx, const Index iy_agenda_call1, const Tensor3 &iy_transmission, const ArrayOfString &iy_aux_vars, const Index iy_id, const Vector &f_grid, const Vector &rte_pos, const Vector &rte_los, const Vector &rte_pos2, const Agenda &input_agenda)
void yCalc(Workspace &ws, Vector &y, Vector &y_f, ArrayOfIndex &y_pol, Matrix &y_pos, Matrix &y_los, ArrayOfVector &y_aux, Matrix &y_geo, Matrix &jacobian, const Index &atmgeom_checked, const Index &atmfields_checked, const Index &atmosphere_dim, const EnergyLevelMap &nlte_field, const Index &cloudbox_on, const Index &cloudbox_checked, const Index &scat_data_checked, const Index &sensor_checked, const Index &stokes_dim, const Vector &f_grid, const Matrix &sensor_pos, const Matrix &sensor_los, const Matrix &transmitter_pos, const Matrix &mblock_dlos_grid, const Sparse &sensor_response, const Vector &sensor_response_f, const ArrayOfIndex &sensor_response_pol, const Matrix &sensor_response_dlos, const String &iy_unit, const Agenda &iy_main_agenda, const Agenda &geo_pos_agenda, const Agenda &jacobian_agenda, const Index &jacobian_do, const ArrayOfRetrievalQuantity &jacobian_quantities, const ArrayOfString &iy_aux_vars, const Verbosity &verbosity)
WORKSPACE METHOD: yCalc.
Matrix ppvar_vmr(Workspace &ws) noexcept
void itw2p(VectorView p_values, ConstVectorView p_grid, const ArrayOfGridPos &gp, ConstMatrixView itw)
Converts interpolation weights to pressures.
Tensor3 iy_transmission(Workspace &ws) noexcept
Sparse sensor_response(Workspace &ws) noexcept
void apply_iy_unit2(Tensor3View J, ConstMatrixView iy, const String &iy_unit, ConstVectorView f_grid, const Numeric &n, const ArrayOfIndex &i_pol)
Largely as apply_iy_unit but operates on jacobian data.
Vector lat_grid(Workspace &ws) noexcept
void iyApplyUnit(Matrix &iy, ArrayOfMatrix &iy_aux, const Index &stokes_dim, const Vector &f_grid, const ArrayOfString &iy_aux_vars, const String &iy_unit, const Verbosity &)
WORKSPACE METHOD: iyApplyUnit.
Tensor4 pnd_field(Workspace &ws) noexcept
Index iy_id(Workspace &ws) noexcept
Numeric interp(ConstVectorView itw, ConstVectorView a, const GridPos &tc)
Red 1D Interpolate.
Verbosity verbosity(Workspace &ws) noexcept
void error_if_limb_ppath(const Ppath &ppath)
Throws an error if ppath altitudes not are strictly increasing or decreasing.
void mult(ComplexVectorView y, const ConstComplexMatrixView &M, const ConstComplexVectorView &x)
Matrix-Vector Multiplication.
void interp_atmfield_by_itw(VectorView x, const Index &atmosphere_dim, ConstTensor3View x_field, const ArrayOfGridPos &gp_p, const ArrayOfGridPos &gp_lat, const ArrayOfGridPos &gp_lon, ConstMatrixView itw)
Interpolates an atmospheric field with pre-calculated weights by interp_atmfield_gp2itw.
Tensor3 ppvar_iy(Workspace &ws) noexcept
void swap(ComplexVector &v1, ComplexVector &v2)
Swaps two objects.
Index mc_max_time(Workspace &ws) noexcept
Index f_index(Workspace &ws) noexcept
ArrayOfIndex cloudbox_limits(Workspace &ws) noexcept
Index jacobian_do(Workspace &ws) noexcept
Tensor3 wind_u_field(Workspace &ws) noexcept
Vector y(Workspace &ws) noexcept
void resize(Index n)
Resize function.
ArrayOfTensor3 diy_dx(Workspace &ws) noexcept
Matrix y_los(Workspace &ws) noexcept
bool is_gp_inside_cloudbox(const GridPos &gp_p, const GridPos &gp_lat, const GridPos &gp_lon, const ArrayOfIndex &cloudbox_limits, const bool &include_boundaries, const Index &atmosphere_dim)
int arts_omp_get_max_threads()
Wrapper for omp_get_max_threads.
void ppvar_optical_depthFromPpvar_trans_cumulat(Matrix &ppvar_optical_depth, const Tensor4 &ppvar_trans_cumulat, const Verbosity &)
WORKSPACE METHOD: ppvar_optical_depthFromPpvar_trans_cumulat.
Matrix ppvar_f(Workspace &ws) noexcept
Tensor3 mag_w_field(Workspace &ws) noexcept
Index stokes_dim(Workspace &ws) noexcept
ArrayOfIndex mc_scat_order(Workspace &ws) noexcept
An Antenna object used by MCGeneral.
#define FOR_ANALYTICAL_JACOBIANS_DO(what_to_do)
bool do_temperature_jacobian(const ArrayOfRetrievalQuantity &js) noexcept
Returns if the array wants the temperature derivative.
String iy_unit(Workspace &ws) noexcept
Matrix iy(Workspace &ws) noexcept
Tensor3 mc_points(Workspace &ws) noexcept
Numeric mc_std_err(Workspace &ws) noexcept
Agenda iy_space_agenda(Workspace &ws) noexcept
const String WIND_MAINTAG
void iyCalc(Workspace &ws, Matrix &iy, ArrayOfMatrix &iy_aux, Ppath &ppath, const Index &atmfields_checked, const Index &atmgeom_checked, const ArrayOfString &iy_aux_vars, const Index &iy_id, const Index &cloudbox_on, const Index &cloudbox_checked, const Index &scat_data_checked, const Vector &f_grid, const EnergyLevelMap &nlte_field, const Vector &rte_pos, const Vector &rte_los, const Vector &rte_pos2, const String &iy_unit, const Agenda &iy_main_agenda, const Verbosity &)
WORKSPACE METHOD: iyCalc.
The structure to describe a propagation path and releated quantities.
ArrayOfGridPos gp_p
Index position with respect to the pressure grid.
void MCGeneral(Workspace &ws, Vector &y, Index &mc_iteration_count, Vector &mc_error, Tensor3 &mc_points, ArrayOfIndex &mc_source_domain, ArrayOfIndex &mc_scat_order, const MCAntenna &mc_antenna, const Vector &f_grid, const Index &f_index, const Matrix &sensor_pos, const Matrix &sensor_los, const Index &stokes_dim, const Index &atmosphere_dim, const Agenda &ppath_step_agenda, const Numeric &ppath_lmax, const Numeric &ppath_lraytrace, const Agenda &iy_space_agenda, const Agenda &surface_rtprop_agenda, const Agenda &propmat_clearsky_agenda, const Vector &p_grid, const Vector &lat_grid, const Vector &lon_grid, const Tensor3 &z_field, const Vector &refellipsoid, const Matrix &z_surface, const Tensor3 &t_field, const Tensor4 &vmr_field, const Index &cloudbox_on, const ArrayOfIndex &cloudbox_limits, const Tensor4 &pnd_field, const ArrayOfArrayOfSingleScatteringData &scat_data, const Index &atmfields_checked, const Index &atmgeom_checked, const Index &scat_data_checked, const Index &cloudbox_checked, const String &iy_unit, const Index &mc_seed, const Numeric &std_err, const Index &max_time, const Index &max_iter, const Index &min_iter, const Numeric &taustep_limit, const Index &l_mc_scat_order, const Index &t_interp_order, const Verbosity &verbosity)
WORKSPACE METHOD: MCGeneral.
Agenda surface_rtprop_agenda(Workspace &ws) noexcept
void rtmethods_unit_conversion(Matrix &iy, ArrayOfTensor3 &diy_dx, Tensor3 &ppvar_iy, const Index &ns, const Index &np, const Vector &f_grid, const Ppath &ppath, const ArrayOfRetrievalQuantity &jacobian_quantities, const Index &j_analytical_do, const String &iy_unit)
This function handles the unit conversion to be done at the end of some radiative transfer WSMs.
Agenda iy_independent_beam_approx_agenda(Workspace &ws) noexcept
Numeric sqrt(const Rational r)
Square root.
GriddedField4 atm_fields_compact(Workspace &ws) noexcept
void rtmethods_jacobian_init(ArrayOfIndex &jac_species_i, ArrayOfIndex &jac_scat_i, ArrayOfIndex &jac_is_t, ArrayOfIndex &jac_wind_i, ArrayOfIndex &jac_mag_i, ArrayOfIndex &jac_other, ArrayOfTensor3 &diy_dx, ArrayOfTensor3 &diy_dpath, const Index &ns, const Index &nf, const Index &np, const Index &nq, const ArrayOfArrayOfSpeciesTag &abs_species, const Index &cloudbox_on, const ArrayOfString &scat_species, const ArrayOfTensor4 &dpnd_field_dx, const ArrayOfRetrievalQuantity &jacobian_quantities, const Index &iy_agenda_call1, const bool is_active)
This function fixes the initial steps around Jacobian calculations, to be done inside radiative trans...
constexpr Index get_start() const
Returns the start index of the range.
Tensor4 ppvar_trans_cumulat(Workspace &ws) noexcept
Vector lon_true(Workspace &ws) noexcept
Numeric rte_alonglos_v(Workspace &ws) noexcept
EnergyLevelMap nlte_field(Workspace &ws) noexcept
This can be used to make arrays out of anything.
Numeric pow(const Rational base, Numeric exp)
Power of.
ArrayOfIndex mc_source_domain(Workspace &ws) noexcept
Index nelem(const Lines &l)
Number of lines.
const String TEMPERATURE_MAINTAG
Vector sensor_response_f(Workspace &ws) noexcept
Index mc_min_iter(Workspace &ws) noexcept
void get_stepwise_clearsky_propmat(Workspace &ws, PropagationMatrix &K, StokesVector &S, Index <e, ArrayOfPropagationMatrix &dK_dx, ArrayOfStokesVector &dS_dx, const Agenda &propmat_clearsky_agenda, const ArrayOfRetrievalQuantity &jacobian_quantities, ConstVectorView ppath_f_grid, ConstVectorView ppath_magnetic_field, ConstVectorView ppath_line_of_sight, const EnergyLevelMap &ppath_nlte, ConstVectorView ppath_vmrs, const Numeric &ppath_temperature, const Numeric &ppath_pressure, const ArrayOfIndex &jacobian_species, const bool &jacobian_do)
Gets the clearsky propgation matrix and NLTE contributions.
void iyReplaceFromAux(Matrix &iy, const ArrayOfMatrix &iy_aux, const ArrayOfString &iy_aux_vars, const Index &jacobian_do, const String &aux_var, const Verbosity &)
WORKSPACE METHOD: iyReplaceFromAux.
void stepwise_transmission(TransmissionMatrix &T, ArrayOfTransmissionMatrix &dT1, ArrayOfTransmissionMatrix &dT2, const PropagationMatrix &K1, const PropagationMatrix &K2, const ArrayOfPropagationMatrix &dK1, const ArrayOfPropagationMatrix &dK2, const Numeric &r, const Numeric &dr_dtemp1, const Numeric &dr_dtemp2, const Index temp_deriv_pos)
Set the stepwise transmission matrix.
Matrix ppvar_optical_depth(Workspace &ws) noexcept
ArrayOfGridPos gp_lat
Index position with respect to the latitude grid.
Declarations having to do with the four output streams.
Vector rte_pos(Workspace &ws) noexcept
Matrix particle_masses(Workspace &ws) noexcept
Vector y_f(Workspace &ws) noexcept
void MCSetSeedFromTime(Index &mc_seed, const Verbosity &)
WORKSPACE METHOD: MCSetSeedFromTime.
Index ncols() const
Returns the number of columns.
ArrayOfIndex y_pol(Workspace &ws) noexcept
Agenda iy_loop_freqs_agenda(Workspace &ws) noexcept
void stepwise_source(RadiationVector &J, ArrayOfRadiationVector &dJ, const PropagationMatrix &K, const StokesVector &a, const StokesVector &S, const ArrayOfPropagationMatrix &dK, const ArrayOfStokesVector &da, const ArrayOfStokesVector &dS, const ConstVectorView B, const ConstVectorView dB_dT, const ArrayOfRetrievalQuantity &jacobian_quantities, const bool &jacobian_do)
Set the stepwise source.
ArrayOfGridPos gp_lon
Index position with respect to the longitude grid.
Index np
Number of points describing the ppath.
Index nelem() const
Returns the number of elements.
Array< RadiationVector > ArrayOfRadiationVector
Tensor4 vmr_field(Workspace &ws) noexcept
Vector rte_los(Workspace &ws) noexcept
This file contains declerations of functions of physical character.
EnergyLevelMap ppvar_nlte(Workspace &ws) noexcept
const Index GFIELD4_LON_GRID
ArrayOfArrayOfSpeciesTag abs_species(Workspace &ws) noexcept
Vector ppvar_t(Workspace &ws) noexcept
void iyEmissionStandard(Workspace &ws, Matrix &iy, ArrayOfMatrix &iy_aux, ArrayOfTensor3 &diy_dx, Vector &ppvar_p, Vector &ppvar_t, EnergyLevelMap &ppvar_nlte, Matrix &ppvar_vmr, Matrix &ppvar_wind, Matrix &ppvar_mag, Matrix &ppvar_f, Tensor3 &ppvar_iy, Tensor4 &ppvar_trans_cumulat, Tensor4 &ppvar_trans_partial, const Index &iy_id, const Index &stokes_dim, const Vector &f_grid, const Index &atmosphere_dim, const Vector &p_grid, const Tensor3 &t_field, const EnergyLevelMap &nlte_field, const Tensor4 &vmr_field, const ArrayOfArrayOfSpeciesTag &abs_species, const Tensor3 &wind_u_field, const Tensor3 &wind_v_field, const Tensor3 &wind_w_field, const Tensor3 &mag_u_field, const Tensor3 &mag_v_field, const Tensor3 &mag_w_field, const Index &cloudbox_on, const String &iy_unit, const ArrayOfString &iy_aux_vars, const Index &jacobian_do, const ArrayOfRetrievalQuantity &jacobian_quantities, const Ppath &ppath, const Vector &rte_pos2, const Agenda &propmat_clearsky_agenda, const Agenda &water_p_eq_agenda, const Agenda &iy_main_agenda, const Agenda &iy_space_agenda, const Agenda &iy_surface_agenda, const Agenda &iy_cloudbox_agenda, const Index &iy_agenda_call1, const Tensor3 &iy_transmission, const Numeric &rte_alonglos_v, const Tensor3 &surface_props_data, const Verbosity &verbosity)
WORKSPACE METHOD: iyEmissionStandard.
Index atmfields_checked(Workspace &ws) noexcept
void get_ppath_atmvars(Vector &ppath_p, Vector &ppath_t, EnergyLevelMap &ppath_nlte, Matrix &ppath_vmr, Matrix &ppath_wind, Matrix &ppath_mag, const Ppath &ppath, const Index &atmosphere_dim, ConstVectorView p_grid, ConstTensor3View t_field, const EnergyLevelMap &nlte_field, ConstTensor4View vmr_field, ConstTensor3View wind_u_field, ConstTensor3View wind_v_field, ConstTensor3View wind_w_field, ConstTensor3View mag_u_field, ConstTensor3View mag_v_field, ConstTensor3View mag_w_field)
Determines pressure, temperature, VMR, winds and magnetic field for each propgataion path point.
Vector p_grid(Workspace &ws) noexcept
Ppath ppath(Workspace &ws) noexcept
Tensor3 surface_props_data(Workspace &ws) noexcept
Routines for setting up the jacobian.
NUMERIC Numeric
The type to use for all floating point numbers.
MCAntenna mc_antenna(Workspace &ws) noexcept
void iyEmissionStandardSequential(Workspace &ws, Matrix &iy, ArrayOfMatrix &iy_aux, ArrayOfTensor3 &diy_dx, Vector &ppvar_p, Vector &ppvar_t, EnergyLevelMap &ppvar_nlte, Matrix &ppvar_vmr, Matrix &ppvar_wind, Matrix &ppvar_mag, Matrix &ppvar_f, Tensor3 &ppvar_iy, Tensor4 &ppvar_trans_cumulat, Tensor4 &ppvar_trans_partial, const Index &iy_id, const Index &stokes_dim, const Vector &f_grid, const Index &atmosphere_dim, const Vector &p_grid, const Tensor3 &t_field, const EnergyLevelMap &nlte_field, const Tensor4 &vmr_field, const ArrayOfArrayOfSpeciesTag &abs_species, const Tensor3 &wind_u_field, const Tensor3 &wind_v_field, const Tensor3 &wind_w_field, const Tensor3 &mag_u_field, const Tensor3 &mag_v_field, const Tensor3 &mag_w_field, const Index &cloudbox_on, const String &iy_unit, const ArrayOfString &iy_aux_vars, const Index &jacobian_do, const ArrayOfRetrievalQuantity &jacobian_quantities, const Ppath &ppath, const Vector &rte_pos2, const Agenda &propmat_clearsky_agenda, const Agenda &water_p_eq_agenda, const Agenda &iy_main_agenda, const Agenda &iy_space_agenda, const Agenda &iy_surface_agenda, const Agenda &iy_cloudbox_agenda, const Index &iy_agenda_call1, const Tensor3 &iy_transmission, const Numeric &rte_alonglos_v, const Tensor3 &surface_props_data, const Verbosity &verbosity)
WORKSPACE METHOD: iyEmissionStandardSequential.
Index npages() const
Returns the number of pages.
Index iy_agenda_call1(Workspace &ws) noexcept
Index nbooks() const
Returns the number of books.
Index npages(Workspace &ws) noexcept
void iyMC(Workspace &ws, Matrix &iy, ArrayOfMatrix &iy_aux, ArrayOfTensor3 &diy_dx, const Index &iy_agenda_call1, const Tensor3 &iy_transmission, const Vector &rte_pos, const Vector &rte_los, const ArrayOfString &iy_aux_vars, const Index &jacobian_do, const Index &atmosphere_dim, const Vector &p_grid, const Vector &lat_grid, const Vector &lon_grid, const Tensor3 &z_field, const Tensor3 &t_field, const Tensor4 &vmr_field, const Vector &refellipsoid, const Matrix &z_surface, const Index &cloudbox_on, const ArrayOfIndex &cloudbox_limits, const Index &stokes_dim, const Vector &f_grid, const ArrayOfArrayOfSingleScatteringData &scat_data, const Agenda &iy_space_agenda, const Agenda &surface_rtprop_agenda, const Agenda &propmat_clearsky_agenda, const Agenda &ppath_step_agenda, const Numeric &ppath_lmax, const Numeric &ppath_lraytrace, const Tensor4 &pnd_field, const String &iy_unit, const Numeric &mc_std_err, const Index &mc_max_time, const Index &mc_max_iter, const Index &mc_min_iter, const Numeric &mc_taustep_limit, const Index &t_interp_order, const Verbosity &verbosity)
WORKSPACE METHOD: iyMC.
Vector refellipsoid(Workspace &ws) noexcept
ArrayOfString iy_aux_vars(Workspace &ws) noexcept
Vector f_grid(Workspace &ws) noexcept
Vector lat_true(Workspace &ws) noexcept
Matrix sensor_pos(Workspace &ws) noexcept
void iyIndependentBeamApproximation(Workspace &ws, Matrix &iy, ArrayOfMatrix &iy_aux, Ppath &ppath, ArrayOfTensor3 &diy_dx, GriddedField4 &atm_fields_compact, const Index &iy_id, const Vector &f_grid, const Index &atmosphere_dim, const Vector &p_grid, const Vector &lat_grid, const Vector &lon_grid, const Vector &lat_true, const Vector &lon_true, const Tensor3 &t_field, const Tensor3 &z_field, const Tensor4 &vmr_field, const EnergyLevelMap &nlte_field, const Tensor3 &wind_u_field, const Tensor3 &wind_v_field, const Tensor3 &wind_w_field, const Tensor3 &mag_u_field, const Tensor3 &mag_v_field, const Tensor3 &mag_w_field, const Index &cloudbox_on, const ArrayOfIndex &cloudbox_limits, const Tensor4 &pnd_field, const Matrix &particle_masses, const Agenda &ppath_agenda, const Numeric &ppath_lmax, const Numeric &ppath_lraytrace, const Index &iy_agenda_call1, const String &iy_unit, const Tensor3 &iy_transmission, const Vector &rte_pos, const Vector &rte_los, const Vector &rte_pos2, const Index &jacobian_do, const ArrayOfString &iy_aux_vars, const Agenda &iy_independent_beam_approx_agenda, const Index &return_atm1d, const Index &skip_vmr, const Index &skip_pnd, const Index &return_masses, const Verbosity &)
WORKSPACE METHOD: iyIndependentBeamApproximation.
Matrix ppvar_wind(Workspace &ws) noexcept
ArrayOfArrayOfSingleScatteringData scat_data(Workspace &ws) noexcept
void resize(Index r, Index c)
Resize function.
void update_radiation_vector(RadiationVector &I, ArrayOfRadiationVector &dI1, ArrayOfRadiationVector &dI2, const RadiationVector &J1, const RadiationVector &J2, const ArrayOfRadiationVector &dJ1, const ArrayOfRadiationVector &dJ2, const TransmissionMatrix &T, const TransmissionMatrix &PiT, const ArrayOfTransmissionMatrix &dT1, const ArrayOfTransmissionMatrix &dT2, const RadiativeTransferSolver solver)
Update the Radiation Vector.
Vector lon_grid(Workspace &ws) noexcept
const Index GFIELD4_LAT_GRID
ArrayOfTensor4 dpnd_field_dx(Workspace &ws) noexcept
Numeric ppath_lmax(Workspace &ws) noexcept
Numeric ppath_lraytrace(Workspace &ws) noexcept
Agenda iy_surface_agenda(Workspace &ws) noexcept
Array< TransmissionMatrix > ArrayOfTransmissionMatrix
ArrayOfTransmissionMatrix cumulative_transmission(const ArrayOfTransmissionMatrix &T, const CumulativeTransmission type)
Accumulate the transmission matrix over all layers.
Index scat_data_checked(Workspace &ws) noexcept
invlib::Vector< ArtsVector > Vector
invlib wrapper type for ARTS vectors.
Matrix mblock_dlos_grid(Workspace &ws) noexcept
ArrayOfIndex sensor_response_pol(Workspace &ws) noexcept
Agenda ppath_agenda(Workspace &ws) noexcept
void interp_atmfield_gp2itw(Matrix &itw, const Index &atmosphere_dim, const ArrayOfGridPos &gp_p, const ArrayOfGridPos &gp_lat, const ArrayOfGridPos &gp_lon)
Converts atmospheric grid positions to weights for interpolation of an atmospheric field.
#define FOR_ANALYTICAL_JACOBIANS_DO2(what_to_do)
Propagation path structure and functions.
void apply_iy_unit(MatrixView iy, const String &iy_unit, ConstVectorView f_grid, const Numeric &n, const ArrayOfIndex &i_pol)
Performs conversion from radiance to other units, as well as applies refractive index to fulfill the ...
ArrayOfMatrix iy_aux(Workspace &ws) noexcept
Agenda geo_pos_agenda(Workspace &ws) noexcept
void iyLoopFrequencies(Workspace &ws, Matrix &iy, ArrayOfMatrix &iy_aux, Ppath &ppath, ArrayOfTensor3 &diy_dx, const ArrayOfString &iy_aux_vars, const Index &iy_agenda_call1, const Tensor3 &iy_transmission, const Vector &rte_pos, const Vector &rte_los, const Vector &rte_pos2, const Index &stokes_dim, const Vector &f_grid, const Agenda &iy_loop_freqs_agenda, const Verbosity &)
WORKSPACE METHOD: iyLoopFrequencies.
Header file for logic.cc.
Agenda iy_main_agenda(Workspace &ws) noexcept
Vector rte_pos2(Workspace &ws) noexcept
RadiationVector RadiationVector
void iy_transmission_mult(Tensor3 &iy_trans_total, ConstTensor3View iy_trans_old, ConstTensor3View iy_trans_new)
Multiplicates iy_transmission with transmissions.
Declaration of functions in rte.cc.
const Index GFIELD4_P_GRID
Tensor3 mag_v_field(Workspace &ws) noexcept
Tensor3 t_field(Workspace &ws) noexcept
const Numeric SPEED_OF_LIGHT
Header file for special_interp.cc.
void yCalcAppend(Workspace &ws, Vector &y, Vector &y_f, ArrayOfIndex &y_pol, Matrix &y_pos, Matrix &y_los, ArrayOfVector &y_aux, Matrix &y_geo, Matrix &jacobian, ArrayOfRetrievalQuantity &jacobian_quantities, const Index &atmfields_checked, const Index &atmgeom_checked, const Index &atmosphere_dim, const EnergyLevelMap &nlte_field, const Index &cloudbox_on, const Index &cloudbox_checked, const Index &scat_data_checked, const Index &sensor_checked, const Index &stokes_dim, const Vector &f_grid, const Matrix &sensor_pos, const Matrix &sensor_los, const Matrix &transmitter_pos, const Matrix &mblock_dlos_grid, const Sparse &sensor_response, const Vector &sensor_response_f, const ArrayOfIndex &sensor_response_pol, const Matrix &sensor_response_dlos, const String &iy_unit, const Agenda &iy_main_agenda, const Agenda &geo_pos_agenda, const Agenda &jacobian_agenda, const Index &jacobian_do, const ArrayOfString &iy_aux_vars, const ArrayOfRetrievalQuantity &jacobian_quantities_copy, const Index &append_instrument_wfs, const Verbosity &verbosity)
WORKSPACE METHOD: yCalcAppend.
Tensor3 wind_w_field(Workspace &ws) noexcept
Numeric mc_taustep_limit(Workspace &ws) noexcept
TransmissionMatrix TransmissionMatrix
const Index GFIELD4_FIELD_NAMES
Index sensor_checked(Workspace &ws) noexcept
Agenda propmat_clearsky_agenda(Workspace &ws) noexcept
void rtmethods_jacobian_finalisation(Workspace &ws, ArrayOfTensor3 &diy_dx, ArrayOfTensor3 &diy_dpath, const Index &ns, const Index &nf, const Index &np, const Index &atmosphere_dim, const Ppath &ppath, const Vector &ppvar_p, const Vector &ppvar_t, const Matrix &ppvar_vmr, const Index &iy_agenda_call1, const Tensor3 &iy_transmission, const Agenda &water_p_eq_agenda, const ArrayOfRetrievalQuantity &jacobian_quantities, const ArrayOfIndex jac_species_i, const ArrayOfIndex jac_is_t)
This function fixes the last steps to made on the Jacobian in some radiative transfer WSMs.
void iy_main_agendaExecute(Workspace &ws, Matrix &iy, ArrayOfMatrix &iy_aux, Ppath &ppath, ArrayOfTensor3 &diy_dx, const Index iy_agenda_call1, const Tensor3 &iy_transmission, const ArrayOfString &iy_aux_vars, const Index iy_id, const String &iy_unit, const Index cloudbox_on, const Index jacobian_do, const Vector &f_grid, const EnergyLevelMap &nlte_field, const Vector &rte_pos, const Vector &rte_los, const Vector &rte_pos2, const Agenda &input_agenda)
Matrix jacobian(Workspace &ws) noexcept
Stuff related to the transmission matrix.
Index mc_seed(Workspace &ws) noexcept
void yApplyUnit(Vector &y, Matrix &jacobian, const Vector &y_f, const ArrayOfIndex &y_pol, const String &iy_unit, const Verbosity &)
WORKSPACE METHOD: yApplyUnit.
INDEX Index
The type to use for all integer numbers and indices.
Matrix sensor_response_dlos(Workspace &ws) noexcept
ConstComplexMatrixView transpose(ConstComplexMatrixView m)
Const version of transpose.
ArrayOfString scat_species(Workspace &ws) noexcept
Tensor3 mag_u_field(Workspace &ws) noexcept
Index mblock_index(Workspace &ws) noexcept
Index ppath_what_background(const Ppath &ppath)
Returns the case number for the radiative background.
Header file for helper functions for OpenMP.
Agenda jacobian_agenda(Workspace &ws) noexcept
void get_iy_of_background(Workspace &ws, Matrix &iy, ArrayOfTensor3 &diy_dx, ConstTensor3View iy_transmission, const Index &iy_id, const Index &jacobian_do, const ArrayOfRetrievalQuantity &jacobian_quantities, const Ppath &ppath, ConstVectorView rte_pos2, const Index &atmosphere_dim, const EnergyLevelMap &nlte_field, const Index &cloudbox_on, const Index &stokes_dim, ConstVectorView f_grid, const String &iy_unit, ConstTensor3View surface_props_data, const Agenda &iy_main_agenda, const Agenda &iy_space_agenda, const Agenda &iy_surface_agenda, const Agenda &iy_cloudbox_agenda, const Index &iy_agenda_call1, const Verbosity &verbosity)
Determines iy of the "background" of a propgation path.
void interp_cloudfield_gp2itw(VectorView itw, GridPos &gp_p_out, GridPos &gp_lat_out, GridPos &gp_lon_out, const GridPos &gp_p_in, const GridPos &gp_lat_in, const GridPos &gp_lon_in, const Index &atmosphere_dim, const ArrayOfIndex &cloudbox_limits)
Converts atmospheric a grid position to weights for interpolation of a field defined ONLY inside the ...
Vector ppvar_p(Workspace &ws) noexcept
void jac_ranges_indices(ArrayOfArrayOfIndex &jis, bool &any_affine, const ArrayOfRetrievalQuantity &jqs, const bool &before_affine)
Determines the index range inside x and the Jacobian for each retrieval quantity.
Agenda water_p_eq_agenda(Workspace &ws) noexcept
Index nelem() const
Number of elements.
Vector mc_error(Workspace &ws) noexcept
Matrix sensor_los(Workspace &ws) noexcept
Index mc_max_iter(Workspace &ws) noexcept
Matrix y_geo(Workspace &ws) noexcept
Index cloudbox_checked(Workspace &ws) noexcept
StokesVector StokesVector
Matrix z_surface(Workspace &ws) noexcept
void get_stepwise_blackbody_radiation(VectorView B, VectorView dB_dT, ConstVectorView ppath_f_grid, const Numeric &ppath_temperature, const bool &do_temperature_derivative)
Get the blackbody radiation at propagation path point.
void get_ppath_f(Matrix &ppath_f, const Ppath &ppath, ConstVectorView f_grid, const Index &atmosphere_dim, const Numeric &rte_alonglos_v, ConstMatrixView ppath_wind)
Determines the Doppler shifted frequencies along the propagation path.
The global header file for ARTS.
Index cloudbox_on(Workspace &ws) noexcept