F90_NONE Removal (MGMC tallying optimization) (#2785)

This commit is contained in:
John Tramm 2023-11-28 15:20:54 -06:00 committed by GitHub
parent e8faccdc93
commit 1d4cd9b0aa
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
3 changed files with 6 additions and 7 deletions

View file

@ -317,7 +317,6 @@ enum class GlobalTally { K_COLLISION, K_ABSORPTION, K_TRACKLENGTH, LEAKAGE };
// Miscellaneous
constexpr int C_NONE {-1};
constexpr int F90_NONE {0}; // TODO: replace usage of this with C_NONE
// Interpolation rules
enum class Interpolation {

View file

@ -257,10 +257,10 @@ private:
vector<int> cell_last_; //!< coordinates for all levels
// Energy data
double E_; //!< post-collision energy in eV
double E_last_; //!< pre-collision energy in eV
int g_ {0}; //!< post-collision energy group (MG only)
int g_last_; //!< pre-collision energy group (MG only)
double E_; //!< post-collision energy in eV
double E_last_; //!< pre-collision energy in eV
int g_ {C_NONE}; //!< post-collision energy group (MG only)
int g_last_; //!< pre-collision energy group (MG only)
// Other physical data
double wgt_ {1.0}; //!< particle weight

View file

@ -59,7 +59,7 @@ void EnergyFilter::set_bins(gsl::span<const double> bins)
void EnergyFilter::get_all_bins(
const Particle& p, TallyEstimator estimator, FilterMatch& match) const
{
if (p.g() != F90_NONE && matches_transport_groups_) {
if (p.g() != C_NONE && matches_transport_groups_) {
if (estimator == TallyEstimator::TRACKLENGTH) {
match.bins_.push_back(data::mg.num_energy_groups_ - p.g() - 1);
} else {
@ -98,7 +98,7 @@ std::string EnergyFilter::text_label(int bin) const
void EnergyoutFilter::get_all_bins(
const Particle& p, TallyEstimator estimator, FilterMatch& match) const
{
if (p.g() != F90_NONE && matches_transport_groups_) {
if (p.g() != C_NONE && matches_transport_groups_) {
match.bins_.push_back(data::mg.num_energy_groups_ - p.g() - 1);
match.weights_.push_back(1.0);