Skip to content

Commit

Permalink
Update rpkt.cc
Browse files Browse the repository at this point in the history
  • Loading branch information
lukeshingles committed Aug 31, 2024
1 parent 1f115fa commit 28821e8
Showing 1 changed file with 2 additions and 10 deletions.
12 changes: 2 additions & 10 deletions rpkt.cc
Original file line number Diff line number Diff line change
Expand Up @@ -365,13 +365,7 @@ void electron_scatter_rpkt(Packet &pkt) {
old_dir_cmf[1] * cos(tsc);
new_dir_cmf[2] = sin(tsc) * cos(phisc) * sqrt(1 - pow(old_dir_cmf[2], 2.)) + old_dir_cmf[2] * cos(tsc);
} else {
new_dir_cmf[0] = sin(tsc) * cos(phisc);
new_dir_cmf[1] = sin(tsc) * sin(phisc);
if (old_dir_cmf[2] > 0) {
new_dir_cmf[2] = cos(tsc);
} else {
new_dir_cmf[2] = -cos(tsc);
}
new_dir_cmf = {sin(tsc) * cos(phisc), sin(tsc) * sin(phisc), (old_dir_cmf[2] > 0) ? cos(tsc) : -cos(tsc)};
}

// Need to rotate Stokes Parameters in the scattering plane
Expand Down Expand Up @@ -546,9 +540,7 @@ void rpkt_event_boundbound(Packet &pkt, const MacroAtomState &pktmastate, const

pkt.absorptiontype = pktmastate.activatingline;
pkt.absorptionfreq = pkt.nu_rf;
pkt.absorptiondir[0] = pkt.dir[0];
pkt.absorptiondir[1] = pkt.dir[1];
pkt.absorptiondir[2] = pkt.dir[2];
pkt.absorptiondir = pkt.dir;
pkt.type = TYPE_MA;

if constexpr (TRACK_ION_STATS) {
Expand Down

0 comments on commit 28821e8

Please sign in to comment.