ARTS 2.5.10 (git: 2f1c442c)
zeemandata.cc
Go to the documentation of this file.
1/* Copyright (C) 2018 Richard Larsson
2
3 This program is free software; you can redistribute it and/or modify it
4 under the terms of the GNU General Public License as published by the
5 Free Software Foundation; either version 2, or (at your option) any
6 later version.
7
8 This program is distributed in the hope that it will be useful,
9 but WITHOUT ANY WARRANTY; without even the implied warranty of
10 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
11 GNU General Public License for more details.
12
13 You should have received a copy of the GNU General Public License
14 along with this program; if not, write to the Free Software
15 Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307,
16 USA. */
17
29#include "zeemandata.h"
30
31#include "debug.h"
32#include "matpack_eigen.h"
33#include "species_info.h"
34#include "wigner_functions.h"
35
37 const Numeric& GS,
38 const Numeric& GL) noexcept {
39 if (Quantum::Number::vamdcCheck(qns, Quantum::Number::VAMDC::hunda) and
40 qns.has(QuantumNumberType::Omega,
41 QuantumNumberType::J,
42 QuantumNumberType::Lambda,
43 QuantumNumberType::S)) {
44 auto& Omega = qns[QuantumNumberType::Omega];
45 auto& J = qns[QuantumNumberType::J];
46 auto& Lambda = qns[QuantumNumberType::Lambda];
47 auto& S = qns[QuantumNumberType::S];
49 Omega.upp(), J.upp(), Lambda.upp(), S.upp(), GS, GL),
51 Omega.low(), J.low(), Lambda.low(), S.low(), GS, GL)};
52 }
53
54 if (Quantum::Number::vamdcCheck(qns, Quantum::Number::VAMDC::hundb) and
55 qns.has(QuantumNumberType::N,
56 QuantumNumberType::J,
57 QuantumNumberType::Lambda,
58 QuantumNumberType::S)) {
59 auto& N = qns[QuantumNumberType::N];
60 auto& J = qns[QuantumNumberType::J];
61 auto& Lambda = qns[QuantumNumberType::Lambda];
62 auto& S = qns[QuantumNumberType::S];
63 return {
64 Zeeman::SimpleGCaseB(N.upp(), J.upp(), Lambda.upp(), S.upp(), GS, GL),
65 Zeeman::SimpleGCaseB(N.low(), J.low(), Lambda.low(), S.low(), GS, GL)};
66 }
67
68 return {NAN, NAN};
69}
70
73 const Numeric GS = get_lande_spin_constant(qid.Species());
75 return SimpleG(qid.val, GS, GL);
76}
77
79 Rational N,
80 Numeric GS,
81 Numeric GR,
82 Numeric GLE,
83 Numeric B,
84 Numeric D,
85 Numeric H,
86 Numeric gB,
87 Numeric gD,
88 Numeric gH,
89 Numeric lB,
90 Numeric lD,
91 Numeric lH) {
93 using std::atan2, std::cos, std::sin;
94
95 if (J.isUndefined() or N.isUndefined()) return NAN;
96 if (J == 0) return 0;
97
98 auto nom = (lB + lD * (J * J + J + 1) + lH * pow2(J * J + J + 1)) *
99 (2 * sqrt(J * J + J) / (2 * J + 1));
100
101 auto denom =
102 B * J * (J - 1) - D * pow2(J * (J - 1)) + H * pow3(J * (J - 1)) +
103 (gB + gD * J * (J - 1) + gH * pow2(J * (J - 1))) * (J - 1) +
104 (lB + lD * J * (J - 1) + lH * pow2(J * (J - 1))) *
105 (2. / 3. - 2 * J / (2 * J + 1)) -
106 (B * (J + 2) * (J + 1) - D * pow2((J + 2) * (J + 1)) +
107 H * pow3((J + 2) * (J + 1)) -
108 (gB + gD * (J + 2) * (J + 1) + gH * pow2((J + 2) * (J + 1))) * (J + 2) +
109 (lB + lD * (J + 2) * (J + 1) + lH * pow2((J + 2) * (J + 1))) *
110 (2. / 3. - 2 * (J + 1) / (2 * J + 1)));
111
112 auto phi = atan2(2 * nom, denom) / 2;
113
114 if (J == N) return (GS + GR) / (J * (J + 1)) - GR;
115 if (J < N)
116 return (GS + GR) * (pow2(cos(phi)) / J - pow2(sin(phi)) / (J + 1)) +
117 2 * GLE * cos(2 * phi) / (2 * J + 1) - GR;
118 return (GS + GR) * (pow2(sin(phi)) / J - pow2(cos(phi)) / (J + 1)) -
119 2 * GLE * cos(2 * phi) / (2 * J + 1) - GR;
120}
121
123 Rational j,
124 Numeric gperp,
125 Numeric gpara) {
126 using Math::pow2;
127 if (k.isUndefined() or j.isUndefined() or j == 0) return 0;
128 return gperp + (gperp + gpara) * (pow2(k) / (j * (j + 1)));
129}
130
133 if (qid.Isotopologue() == "O2-66") {
134 if (qid.val.has(QuantumNumberType::J,
135 QuantumNumberType::N,
136 QuantumNumberType::v1)) {
137 if (qid.val[QuantumNumberType::v1].low() == 0 and
138 qid.val[QuantumNumberType::v1].upp() == 0) {
139 constexpr Numeric GS = 2.002084;
140 constexpr Numeric GLE = 2.77e-3;
141 constexpr Numeric GR = -1.16e-4;
142 constexpr Numeric B = 43100.44276e6;
143 constexpr Numeric D = 145.1271e3;
144 constexpr Numeric H = 49e-3;
145 constexpr Numeric lB = 59501.3438e6;
146 constexpr Numeric lD = 58.3680e3;
147 constexpr Numeric lH = 290.8e-3;
148 constexpr Numeric gB = -252.58634e6;
149 constexpr Numeric gD = -243.42;
150 constexpr Numeric gH = -1.46e-3;
151
152 auto JU = qid.val[QuantumNumberType::J].upp();
153 auto NU = qid.val[QuantumNumberType::N].upp();
155 JU, NU, GS, GR, GLE, B, D, H, gB, gD, gH, lB, lD, lH);
156 auto JL = qid.val[QuantumNumberType::J].low();
157 auto NL = qid.val[QuantumNumberType::N].low();
159 JL, NL, GS, GR, GLE, B, D, H, gB, gD, gH, lB, lD, lH);
160 return {gu, gl};
161 }
162 }
163 } else if (qid.Isotopologue() == "O2-68") {
164 if (qid.val.has(QuantumNumberType::J,
165 QuantumNumberType::N,
166 QuantumNumberType::v1)) {
167 if (qid.val[QuantumNumberType::v1].low() == 0 and
168 qid.val[QuantumNumberType::v1].upp() == 0) {
169 constexpr Numeric GS = 2.002025;
170 constexpr Numeric GLE = 2.813e-3;
171 constexpr Numeric GR = -1.26e-4;
172 constexpr Numeric B = 40707.38657e6;
173 constexpr Numeric D = 129.4142e3;
174 constexpr Numeric H = 0;
175 constexpr Numeric lB = 59499.0375e6;
176 constexpr Numeric lD = 54.9777e3;
177 constexpr Numeric lH = 272.1e-3;
178 constexpr Numeric gB = -238.51530e6;
179 constexpr Numeric gD = -217.77;
180 constexpr Numeric gH = -1.305e-3;
181
182 auto JU = qid.val[QuantumNumberType::J].upp();
183 auto NU = qid.val[QuantumNumberType::N].upp();
185 JU, NU, GS, GR, GLE, B, D, H, gB, gD, gH, lB, lD, lH);
186 auto JL = qid.val[QuantumNumberType::J].low();
187 auto NL = qid.val[QuantumNumberType::N].low();
189 JL, NL, GS, GR, GLE, B, D, H, gB, gD, gH, lB, lD, lH);
190 return {gu, gl};
191 }
192 }
193 } else if (qid.Isotopologue() == "CO-26") {
194 constexpr Numeric gperp =
195 -0.2689 /
196 Constant::mass_ratio_electrons_per_proton; // Flygare and Benson 1971
197
198 return {gperp, gperp};
199 } else if (qid.Isotopologue() == "OCS-622") {
200 constexpr Numeric gperp =
201 -.02889 /
202 Constant::mass_ratio_electrons_per_proton; // Flygare and Benson 1971
203 constexpr Numeric gpara =
204 0 /
205 Constant::mass_ratio_electrons_per_proton; // Flygare and Benson 1971
206 if (qid.val.has(QuantumNumberType::J, QuantumNumberType::Ka)) {
207 auto JU = qid.val[QuantumNumberType::J].upp();
208 auto KU = qid.val[QuantumNumberType::Ka].upp();
209 auto JL = qid.val[QuantumNumberType::J].low();
210 auto KL = qid.val[QuantumNumberType::Ka].low();
211
212 return {closed_shell_trilinear(KU, JU, gperp, gpara),
213 closed_shell_trilinear(KL, JL, gperp, gpara)};
214 }
215 } else if (qid.Isotopologue() == "OCS-624") {
216 constexpr Numeric gperp =
217 -.0285 /
218 Constant::mass_ratio_electrons_per_proton; // Flygare and Benson 1971
219 constexpr Numeric gpara =
220 -.061 /
221 Constant::mass_ratio_electrons_per_proton; // Flygare and Benson 1971
222
223 if (qid.val.has(QuantumNumberType::J, QuantumNumberType::Ka)) {
224 auto JU = qid.val[QuantumNumberType::J].upp();
225 auto KU = qid.val[QuantumNumberType::Ka].upp();
226 auto JL = qid.val[QuantumNumberType::J].low();
227 auto KL = qid.val[QuantumNumberType::Ka].low();
228
229 return {closed_shell_trilinear(KU, JU, gperp, gpara),
230 closed_shell_trilinear(KL, JL, gperp, gpara)};
231 }
232 } else if (qid.Isotopologue() == "CO2-626") {
233 constexpr Numeric gperp =
234 -.05508 /
235 Constant::mass_ratio_electrons_per_proton; // Flygare and Benson 1971
236 constexpr Numeric gpara =
237 0 /
238 Constant::mass_ratio_electrons_per_proton; // Flygare and Benson 1971
239
240 if (qid.val.has(QuantumNumberType::J, QuantumNumberType::Ka)) {
241 auto JU = qid.val[QuantumNumberType::J].upp();
242 auto KU = qid.val[QuantumNumberType::Ka].upp();
243 auto JL = qid.val[QuantumNumberType::J].low();
244 auto KL = qid.val[QuantumNumberType::Ka].low();
245
246 return {closed_shell_trilinear(KU, JU, gperp, gpara),
247 closed_shell_trilinear(KL, JL, gperp, gpara)};
248 }
249 }
250
251 // Set to zero otherwise as we practically say "there's no Zeeman effect" then
252 return {0, 0};
253}
254
256 Model m = GetAdvancedModel(qid);
257 if (m.empty()) m = GetSimpleModel(qid);
258 *this = m;
259}
260
262 return Eigen::Vector3d(v, u, w).normalized();
263}
264
266 using std::cos;
267 using std::sin;
268 return Eigen::Vector3d(cos(a) * sin(z), sin(a) * sin(z), cos(z)).normalized();
269}
270
271Eigen::Vector3d ev_xyz_by_za_local(Numeric z, Numeric a) {
272 using std::cos;
273 using std::sin;
274 return Eigen::Vector3d(cos(a) * cos(z), sin(a) * cos(z), -sin(z)).normalized();
275}
276
278 Numeric u, Numeric v, Numeric w, Numeric z, Numeric a) noexcept {
279 Derived output;
280
281 // If there is no magnetic field, bailout quickly
282 output.H = std::hypot(u, v, w);
283 if (output.H == 0) {
284 output = FromPreDerived(0, 0, 0);
285 } else {
286 // XYZ vectors normalized
287 const Eigen::Vector3d n = los_xyz_by_za_local(z, a);
288 const Eigen::Vector3d ev = ev_xyz_by_za_local(z, a);
289 const Eigen::Vector3d nH = los_xyz_by_uvw_local(u, v, w);
290
291 // Normalized vector (which are also the magnetic field derivatives)
292 output.dH_dv = nH[0];
293 output.dH_du = nH[1];
294 output.dH_dw = nH[2];
295
296 // Compute theta (and its derivatives if possible)
297 const Numeric cos_theta = n.dot(nH);
298 const Numeric sin_theta = std::sqrt(1 - Math::pow2(cos_theta));
299 output.theta = std::acos(cos_theta);
300 if (sin_theta not_eq 0) {
301 const Eigen::Vector3d dtheta =
302 (nH * cos_theta - n) / (output.H * sin_theta);
303 output.dtheta_dv = dtheta[0];
304 output.dtheta_du = dtheta[1];
305 output.dtheta_dw = dtheta[2];
306 } else {
307 output.dtheta_dv = 0;
308 output.dtheta_du = 0;
309 output.dtheta_dw = 0;
310 }
311
312 // Compute eta (and its derivatives if possible)
313 const Eigen::Vector3d inplane = nH - nH.dot(n) * n;
314 const Numeric y = ev.cross(inplane).dot(n);
315 const Numeric x = ev.dot(inplane);
316 output.eta = std::atan2(y, x);
317 if (x not_eq 0 or y not_eq 0) {
318 const Eigen::Vector3d deta =
319 n.cross(nH) / (output.H * (Math::pow2(x) + Math::pow2(y)));
320 output.deta_dv = deta[0];
321 output.deta_du = deta[1];
322 output.deta_dw = deta[2];
323 } else {
324 output.deta_dv = 0;
325 output.deta_du = 0;
326 output.deta_dw = 0;
327 }
328 }
329
330 return output;
331}
332
333namespace Zeeman {
335 Rational Jl,
337 Index n) const ARTS_NOEXCEPT {
339 using Math::pow2;
340
341 auto ml = Ml(Ju, Jl, type, n);
342 auto mu = Mu(Ju, Jl, type, n);
343 auto dm = Rational(dM(type));
344 return PolarizationFactor(type) *
345 pow2(wigner3j(Jl, Rational(1), Ju, ml, -dm, -mu));
346}
347
348std::ostream& operator<<(std::ostream& os, const Model& m) {
349 os << m.mdata.gu << ' ' << m.mdata.gl;
350 return os;
351}
352
353std::istream& operator>>(std::istream& is, Model& m) {
354 is >> double_imanip() >> m.mdata.gu >> m.mdata.gl;
355 return is;
356}
357
358std::ostream& operator<<(bofstream& bof, const Model& m) {
359 bof << m.mdata.gu << m.mdata.gl;
360 return bof;
361}
362
363std::istream& operator>>(bifstream& bif, Model& m) {
364 bif >> m.mdata.gu >> m.mdata.gl;
365 return bif;
366}
367
369 const Numeric ST = std::sin(theta), CT = std::cos(theta), ST2 = ST * ST,
370 CT2 = CT * CT, ST2C2E = ST2 * std::cos(2 * eta),
371 ST2S2E = ST2 * std::sin(2 * eta);
372
375 1 + CT2, ST2C2E, ST2S2E, 2 * CT, 4 * CT, 2 * ST2S2E, -2 * ST2C2E);
376 pv.pi =
377 PolarizationVector(ST2, -ST2C2E, -ST2S2E, 0, 0, -2 * ST2S2E, 2 * ST2C2E);
379 1 + CT2, ST2C2E, ST2S2E, -2 * CT, -4 * CT, 2 * ST2S2E, -2 * ST2C2E);
380 return pv;
381}
382
384 const Numeric eta) noexcept {
385 const Numeric ST = std::sin(theta), CT = std::cos(theta),
386 C2E = std::cos(2 * eta), S2E = std::sin(2 * eta), dST = CT,
387 dST2 = 2 * ST * dST, dCT = -ST, dST2C2E = dST2 * C2E,
388 dST2S2E = dST2 * S2E, dCT2 = 2 * CT * dCT;
389
392 dCT2, dST2C2E, dST2S2E, 2 * dCT, 4 * dCT, 2 * dST2S2E, -2 * dST2C2E);
394 dST2, -dST2C2E, -dST2S2E, 0, 0, -2 * dST2S2E, 2 * dST2C2E);
396 dCT2, dST2C2E, dST2S2E, -2 * dCT, -4 * dCT, 2 * dST2S2E, -2 * dST2C2E);
397 return pv;
398}
399
401 Numeric eta) noexcept {
402 const Numeric ST = std::sin(theta), ST2 = ST * ST, C2E = std::cos(2 * eta),
403 S2E = std::sin(2 * eta), dST2C2E = -2 * ST2 * S2E,
404 dST2S2E = 2 * ST2 * C2E;
405
407 pv.sm =
408 PolarizationVector(0, dST2C2E, dST2S2E, 0, 0, 2 * dST2S2E, -2 * dST2C2E);
410 0, -dST2C2E, -dST2S2E, 0, 0, -2 * dST2S2E, 2 * dST2C2E);
411 pv.sp =
412 PolarizationVector(0, dST2C2E, dST2S2E, 0, 0, 2 * dST2S2E, -2 * dST2C2E);
413 return pv;
414}
415
416#pragma GCC diagnostic push
417#pragma GCC diagnostic ignored "-Wreturn-type"
419 Polarization type) noexcept {
420 switch (type) {
422 return data.sm;
423 case Polarization::Pi:
424 return data.pi;
426 return data.sp;
428 return data.sm;
429 }
430}
431#pragma GCC diagnostic pop
432
434 const ComplexVectorView& abs,
435 const PolarizationVector& polvec,
436 const bool do_phase) ARTS_NOEXCEPT {
437 ARTS_ASSERT(pm.NumberOfZenithAngles() == 1)
438 ARTS_ASSERT(pm.NumberOfAzimuthAngles() == 1)
439 ARTS_ASSERT(pm.NumberOfFrequencies() == abs.nelem())
440 ARTS_ASSERT(do_phase ? pm.NumberOfNeededVectors() == 7
441 : pm.NumberOfNeededVectors() == 4)
442
443 const auto pol_real = matpack::eigen::col_vec(polvec.att);
444 const auto pol_imag = matpack::eigen::col_vec(polvec.dis);
445
446 MatrixView out = pm.Data()(0, 0, joker, joker);
447 matpack::eigen::mat(out).leftCols<4>().noalias() += matpack::eigen::row_vec(abs.real()) * pol_real;
448 if (do_phase)
449 matpack::eigen::mat(out).rightCols<3>().noalias() +=
450 matpack::eigen::row_vec(abs.imag()) * pol_imag;
451}
452
454 const ComplexVectorView& abs,
455 const ComplexVectorView& dabs,
456 const PolarizationVector& polvec,
457 const PolarizationVector& dpolvec_dtheta,
458 const PolarizationVector& dpolvec_deta,
459 const Numeric dH,
460 const Numeric dt,
461 const Numeric de,
462 const bool do_phase) ARTS_NOEXCEPT {
463 ARTS_ASSERT(pm.NumberOfZenithAngles() == 1)
464 ARTS_ASSERT(pm.NumberOfAzimuthAngles() == 1)
465 ARTS_ASSERT(pm.NumberOfFrequencies() == abs.nelem())
466 ARTS_ASSERT(do_phase ? pm.NumberOfNeededVectors() == 7
467 : pm.NumberOfNeededVectors() == 4)
468
469 const auto pol_real = matpack::eigen::col_vec(polvec.att);
470 const auto pol_imag = matpack::eigen::col_vec(polvec.dis);
471 const auto dpolvec_dtheta_real = matpack::eigen::col_vec(dpolvec_dtheta.att);
472 const auto dpolvec_dtheta_imag = matpack::eigen::col_vec(dpolvec_dtheta.dis);
473 const auto dpolvec_deta_real = matpack::eigen::col_vec(dpolvec_deta.att);
474 const auto dpolvec_deta_imag = matpack::eigen::col_vec(dpolvec_deta.dis);
475
476 auto da_r =
477 (dt * dpolvec_dtheta_real + de * dpolvec_deta_real);
478 auto da_i =
479 (dt * dpolvec_dtheta_imag + de * dpolvec_deta_imag);
480
481 MatrixView out = pm.Data()(0, 0, joker, joker);
482 matpack::eigen::mat(out).leftCols<4>().noalias() +=
483 dH * matpack::eigen::row_vec(dabs.real()) * pol_real + matpack::eigen::row_vec(abs.real()) * da_r;
484 if (do_phase)
485 matpack::eigen::mat(out).rightCols<3>().noalias() +=
486 dH * matpack::eigen::row_vec(dabs.imag()) * pol_imag + matpack::eigen::row_vec(abs.imag()) * da_i;
487}
488} // namespace Zeeman
The ComplexVectorView class.
The MatrixView class.
Definition: matpackI.h:1188
A list of many quantum numbers. Should always remain sorted.
Main Zeeman Model.
Definition: zeemandata.h:296
SplittingData mdata
Definition: zeemandata.h:298
Numeric Strength(Rational Ju, Rational Jl, Polarization type, Index n) const ARTS_NOEXCEPT
Gives the strength of one subline of a given polarization.
Definition: zeemandata.cc:334
bool empty() const noexcept
Returns true if the Model represents no Zeeman effect.
Definition: zeemandata.h:320
constexpr Model(SplittingData gs={NAN, NAN}) noexcept
Default copy/init of Model from its only private variable.
Definition: zeemandata.h:302
Binary output file stream class.
Definition: bifstream.h:43
Binary output file stream class.
Definition: bofstream.h:42
Input manipulator class for doubles to enable nan and inf parsing.
Definition: double_imanip.h:42
Helper macros for debugging.
#define ARTS_NOEXCEPT
Definition: debug.h:99
#define ARTS_ASSERT(condition,...)
Definition: debug.h:102
void abs(Sparse &A, const Sparse &B)
Absolute value of sparse matrix elements.
Definition: matpackII.cc:394
NUMERIC Numeric
The type to use for all floating point numbers.
Definition: matpack.h:33
INDEX Index
The type to use for all integer numbers and indices.
Definition: matpack.h:39
const Joker joker
constexpr Numeric mass_ratio_electrons_per_proton
Mass ratio of electrons to protons [-] From: https://physics.nist.gov/cgi-bin/cuu/Value?...
constexpr auto pow3(auto x) noexcept
power of three
constexpr auto pow2(auto x) noexcept
power of two
bool vamdcCheck(const ValueList &l, VAMDC type) ARTS_NOEXCEPT
Implements Zeeman modeling.
Definition: zeemandata.cc:333
std::ostream & operator<<(std::ostream &os, const Model &m)
Definition: zeemandata.cc:348
constexpr Index dM(Polarization type) noexcept
Gives the change of M given a polarization type.
Definition: zeemandata.h:52
constexpr Numeric SimpleGCaseB(Rational N, Rational J, Rational Lambda, Rational S, Numeric GS, Numeric GL) noexcept
Computes the Zeeman splitting coefficient.
Definition: zeemandata.h:226
const PolarizationVector & SelectPolarization(const AllPolarizationVectors &data, Polarization type) noexcept
Selects the polarization vector depending on polarization type.
Definition: zeemandata.cc:418
constexpr Derived FromPreDerived(Numeric H, Numeric theta, Numeric eta) noexcept
Sets Derived from predefined Derived parameters.
Definition: zeemandata.h:568
constexpr Numeric SimpleGCaseA(Rational Omega, Rational J, Rational Lambda, Rational Sigma, Numeric GS, Numeric GL) noexcept
Computes the Zeeman splitting coefficient.
Definition: zeemandata.h:262
constexpr Numeric PolarizationFactor(Polarization type) noexcept
The renormalization factor of a polarization type.
Definition: zeemandata.h:198
Derived FromGrids(Numeric u, Numeric v, Numeric w, Numeric z, Numeric a) noexcept
Computes the derived plane from ARTS grids.
Definition: zeemandata.cc:277
AllPolarizationVectors AllPolarization_deta(Numeric theta, Numeric eta) noexcept
The derivative of AllPolarization wrt eta.
Definition: zeemandata.cc:400
AllPolarizationVectors AllPolarization_dtheta(Numeric theta, const Numeric eta) noexcept
The derivative of AllPolarization wrt theta.
Definition: zeemandata.cc:383
Polarization
Zeeman polarization selection.
Definition: zeemandata.h:44
Model GetAdvancedModel(const QuantumIdentifier &qid) ARTS_NOEXCEPT
Returns an advanced Zeeman model.
Definition: zeemandata.cc:131
void dsum(PropagationMatrix &pm, const ComplexVectorView &abs, const ComplexVectorView &dabs, const PolarizationVector &polvec, const PolarizationVector &dpolvec_dtheta, const PolarizationVector &dpolvec_deta, const Numeric dH, const Numeric dt, const Numeric de, const bool do_phase) ARTS_NOEXCEPT
Sums the Zeeman components derivatives into a propagation matrix.
Definition: zeemandata.cc:453
void sum(PropagationMatrix &pm, const ComplexVectorView &abs, const PolarizationVector &polvec, const bool do_phase) ARTS_NOEXCEPT
Sums the Zeeman components into a propagation matrix.
Definition: zeemandata.cc:433
std::istream & operator>>(std::istream &is, Model &m)
Definition: zeemandata.cc:353
Model GetSimpleModel(const QuantumIdentifier &qid) ARTS_NOEXCEPT
Returns a simple Zeeman model.
Definition: zeemandata.cc:71
constexpr Rational Ml(Rational Ju, Rational Jl, Polarization type, Index n) noexcept
Gives the lower state M value at an index.
Definition: zeemandata.h:180
AllPolarizationVectors AllPolarization(Numeric theta, Numeric eta) noexcept
Computes the polarization of each polarization type.
Definition: zeemandata.cc:368
constexpr Rational Mu(Rational Ju, Rational Jl, Polarization type, Index n) noexcept
Gives the upper state M value at an index.
Definition: zeemandata.h:159
auto row_vec(matpack::vector auto &&x)
Map the input to a non-owning const-correct Eigen Map representing a column vector.
Definition: matpack_eigen.h:71
auto col_vec(matpack::vector auto &&x)
Map the input to a non-owning const-correct Eigen Map representing a column vector.
Definition: matpack_eigen.h:51
auto mat(matpack::matrix auto &&x)
Map the input to a non-owning const-correct Eigen Map representing a row matrix.
Definition: matpack_eigen.h:91
Numeric sqrt(const Rational r)
Square root.
Definition: rational.h:705
#define N
Definition: rng.cc:164
Numeric get_lande_spin_constant(const Species::Species species) noexcept
Get the Lande spin constant.
Definition: species_info.cc:30
Numeric get_lande_lambda_constant() noexcept
Get the Lande Lambda constant.
Definition: species_info.cc:44
Some molecular constants.
A logical struct for global quantum numbers with species identifiers.
Implements rational numbers to work with other ARTS types.
Definition: rational.h:43
constexpr bool isUndefined() const noexcept
Is the object not defined.
Definition: rational.h:77
PolarizationVector for each Polarization.
Definition: zeemandata.h:442
Contains derived values useful for Zeeman calculations.
Definition: zeemandata.h:522
Numeric deta_dv
Definition: zeemandata.h:524
Numeric dtheta_du
Definition: zeemandata.h:523
Numeric dtheta_dw
Definition: zeemandata.h:523
Numeric dtheta_dv
Definition: zeemandata.h:523
Numeric deta_du
Definition: zeemandata.h:524
Numeric deta_dw
Definition: zeemandata.h:524
Polarization vector for Zeeman Propagation Matrix.
Definition: zeemandata.h:422
Main storage for Zeeman splitting coefficients.
Definition: zeemandata.h:285
#define u
#define v
#define w
#define a
Numeric wigner3j(const Rational j1, const Rational j2, const Rational j3, const Rational m1, const Rational m2, const Rational m3)
Wigner 3J symbol.
Wigner symbol interactions.
Eigen::Vector3d los_xyz_by_za_local(Numeric z, Numeric a)
Definition: zeemandata.cc:265
Numeric case_b_g_coefficient_o2(Rational J, Rational N, Numeric GS, Numeric GR, Numeric GLE, Numeric B, Numeric D, Numeric H, Numeric gB, Numeric gD, Numeric gH, Numeric lB, Numeric lD, Numeric lH)
Definition: zeemandata.cc:78
Zeeman::SplittingData SimpleG(const Quantum::Number::ValueList &qns, const Numeric &GS, const Numeric &GL) noexcept
Definition: zeemandata.cc:36
constexpr Numeric closed_shell_trilinear(Rational k, Rational j, Numeric gperp, Numeric gpara)
Definition: zeemandata.cc:122
Eigen::Vector3d ev_xyz_by_za_local(Numeric z, Numeric a)
Definition: zeemandata.cc:271
Eigen::Vector3d los_xyz_by_uvw_local(Numeric u, Numeric v, Numeric w)
Definition: zeemandata.cc:261
Headers and class definition of Zeeman modeling.