From fd40a874cc315c38285dfbeeb080a7c92b51f749 Mon Sep 17 00:00:00 2001 From: Paul Romano Date: Fri, 13 Nov 2020 13:33:35 -0600 Subject: [PATCH] Remove unnecessary sampling in angle-energy distributions --- src/secondary_correlated.cpp | 8 -------- src/secondary_kalbach.cpp | 8 -------- 2 files changed, 16 deletions(-) diff --git a/src/secondary_correlated.cpp b/src/secondary_correlated.cpp index 4a1ccad6e..f79104efb 100644 --- a/src/secondary_correlated.cpp +++ b/src/secondary_correlated.cpp @@ -156,14 +156,6 @@ CorrelatedAngleEnergy::CorrelatedAngleEnergy(hid_t group) void CorrelatedAngleEnergy::sample( double E_in, double& E_out, double& mu, uint64_t* seed) const { - // <<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<< REMOVE THIS <<<<<<<<<<<<<<<<<<<<<<<<<<<<< - // Before the secondary distribution refactor, an isotropic polar cosine was - // always sampled but then overwritten with the polar cosine sampled from the - // correlated distribution. To preserve the random number stream, we keep - // this dummy sampling here but can remove it later (will change answers) - mu = 2.0 * prn(seed) - 1.0; - // <<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<< REMOVE THIS <<<<<<<<<<<<<<<<<<<<<<<<<<<<< - // Find energy bin and calculate interpolation factor -- if the energy is // outside the range of the tabulated energies, choose the first or last bins auto n_energy_in = energy_.size(); diff --git a/src/secondary_kalbach.cpp b/src/secondary_kalbach.cpp index 6a31a4376..414c776bd 100644 --- a/src/secondary_kalbach.cpp +++ b/src/secondary_kalbach.cpp @@ -115,14 +115,6 @@ KalbachMann::KalbachMann(hid_t group) void KalbachMann::sample(double E_in, double& E_out, double& mu, uint64_t* seed) const { - // <<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<< REMOVE THIS <<<<<<<<<<<<<<<<<<<<<<<<<<<<< - // Before the secondary distribution refactor, an isotropic polar cosine was - // always sampled but then overwritten with the polar cosine sampled from the - // correlated distribution. To preserve the random number stream, we keep - // this dummy sampling here but can remove it later (will change answers) - mu = 2.0*prn(seed) - 1.0; - // <<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<< REMOVE THIS <<<<<<<<<<<<<<<<<<<<<<<<<<<<< - // Find energy bin and calculate interpolation factor -- if the energy is // outside the range of the tabulated energies, choose the first or last bins auto n_energy_in = energy_.size();