Fix bug in delayed group index in MG mode tallies

This commit is contained in:
Paul Romano 2019-07-22 10:10:53 -05:00
parent cca3012a53
commit 020c0c306f
3 changed files with 4 additions and 20 deletions

View file

@ -522,7 +522,7 @@ Mgxs::get_xs(int xstype, int gin, const int* gout, const double* mu,
break;
case MG_GET_XS_DECAY_RATE:
if (dg != nullptr) {
val = xs_t->decay_rate(a, *dg + 1);
val = xs_t->decay_rate(a, *dg);
} else {
val = xs_t->decay_rate(a, 0);
}

View file

@ -263,21 +263,13 @@ get_nuclide_xs(int index, int xstype, int gin, const int* gout,
{
int gout_c;
const int* gout_c_p;
int dg_c;
const int* dg_c_p;
if (gout != nullptr) {
gout_c = *gout - 1;
gout_c_p = &gout_c;
} else {
gout_c_p = gout;
}
if (dg != nullptr) {
dg_c = *dg - 1;
dg_c_p = &dg_c;
} else {
dg_c_p = dg;
}
return data::nuclides_MG[index].get_xs(xstype, gin - 1, gout_c_p, mu, dg_c_p);
return data::nuclides_MG[index].get_xs(xstype, gin - 1, gout_c_p, mu, dg);
}
//==============================================================================
@ -288,21 +280,13 @@ get_macro_xs(int index, int xstype, int gin, const int* gout,
{
int gout_c;
const int* gout_c_p;
int dg_c;
const int* dg_c_p;
if (gout != nullptr) {
gout_c = *gout - 1;
gout_c_p = &gout_c;
} else {
gout_c_p = gout;
}
if (dg != nullptr) {
dg_c = *dg - 1;
dg_c_p = &dg_c;
} else {
dg_c_p = dg;
}
return data::macro_xs[index].get_xs(xstype, gin - 1, gout_c_p, mu, dg_c_p);
return data::macro_xs[index].get_xs(xstype, gin - 1, gout_c_p, mu, dg);
}
//==============================================================================

View file

@ -1 +1 @@
15e00a46742e973d7c3c5defe427e6f76a4f1b661538cf54957712751410218dc64301fe12ccb8dbed3f2d51d19b3e99d2b615a3e98c46f9954894e96667dc23
508cd056f2d9409a536e487512df34c683720ea45b9100316efb31c19927890c4cacd92f38817d74fcf491bbe4bdb78a0215a798d5a078e0575e3fd94cedf0bd