13 Isotropic1::Isotropic1(Pvl &pvl, PhotoModel &pmodel) : AtmosModel(pvl, pmodel) {
53 void Isotropic1::AtmosModelAlgorithm(
double phase,
double incidence,
double emission) {
65 if(p_atmosTau == 0.0) {
74 if(TauOrWhaChanged()) {
76 p_wha2 = 0.5 * p_atmosWha;
77 p_e2 = AtmosModel::En(2, p_atmosTau);
78 p_e3 = AtmosModel::En(3, p_atmosTau);
79 p_e4 = AtmosModel::En(4, p_atmosTau);
86 p_delta = (1.0 - (p_x0 + p_y0) - (1.0 - p_atmosWha) / (1.0 - (p_x0 - p_y0))) / (p_atmosWha * (0.5 - p_e3));
89 p_alpha0 = 1.0 + p_delta * (0.5 - p_e3);
90 p_alpha1 = 0.5 + p_delta * ((1.0 / 3.0) - p_e4);
91 p_beta0 = p_e2 + p_delta * (0.5 - p_e3);
92 p_beta1 = p_e3 + p_delta * ((1.0 / 3.0) - p_e4);
95 if(p_atmosWha == 1.0) {
96 p_e5 = AtmosModel::En(5, p_atmosTau);
97 p_alpha2 = (1.0 / 3.0) + p_delta * (0.25 - p_e5);
98 p_beta2 = p_e4 + p_delta * (0.25 - p_e5);
99 p_fixcon = (p_beta0 * p_atmosTau - p_alpha1 + p_beta1) / ((p_alpha1 + p_beta1) * p_atmosTau + 2.0 * (p_alpha2 + p_beta2));
103 p_gammax = p_wha2 * p_beta0;
104 p_gammay = 1.0 - p_wha2 * p_alpha0;
107 p_sbar = 1.0 - ((2.0 - p_atmosWha * p_alpha0) * p_alpha1 + p_atmosWha * p_beta0 * p_beta1);
109 SetOldTau(p_atmosTau);
110 SetOldWha(p_atmosWha);
114 hpsq1 = pow((1.0 + p_atmosHnorm), 2.0) - 1.0;
115 munot = cos((
PI / 180.0) * incidence);
116 maxval = max(1.0e-30, hpsq1 + munot * munot);
117 munotp = p_atmosHnorm / (sqrt(maxval) - munot);
118 munotp = max(munotp, p_atmosTau / 69.0);
119 mu = cos((
PI / 180.0) * emission);
120 maxval = max(1.0e-30, hpsq1 + mu * mu);
121 mup = p_atmosHnorm / (sqrt(maxval) - mu);
122 mup = max(mup, p_atmosTau / 69.0);
125 maxval = max(1.0e-30, munotp);
126 xx = -p_atmosTau / maxval;
134 emunot = exp(-p_atmosTau / munotp);
137 maxval = max(1.0e-30, mup);
138 xx = -p_atmosTau / maxval;
147 emu = exp(-p_atmosTau / mup);
150 xmunot = 1.0 + p_delta * munotp * (1.0 - emunot);
151 ymunot = emunot + p_delta * munotp * (1.0 - emunot);
152 xmu = 1.0 + p_delta * mup * (1.0 - emu);
153 ymu = emu + p_delta * mup * (1.0 - emu);
156 if(p_atmosWha == 1.0) {
157 fix = p_fixcon * munotp * (xmunot + ymunot);
158 xmunot = xmunot + fix;
159 ymunot = ymunot + fix;
160 fix = p_fixcon * mup * (xmu + ymu);
166 gmunot = p_gammax * xmunot + p_gammay * ymunot;
167 gmu = p_gammax * xmu + p_gammay * ymu;
170 p_pstd = 0.25 * p_atmosWha * munotp / (munotp + mup) * (xmunot * xmu - ymunot * ymu);
171 p_trans = gmunot * gmu;
174 p_trans0 = emunot * emu;
179 p_transs = (emunot + 0.5 * (p_gammax * xmunot + p_gammay * ymunot - emunot)) * emu;
const double PI
The mathematical constant PI.
Isotropic atmos scattering model.
Container for cube-like labels.
Namespace for ISIS/Bullet specific routines.