mirror of
https://github.com/openmc-dev/openmc.git
synced 2026-07-27 05:35:49 -04:00
Fix bug in delayed group index in MG mode tallies
This commit is contained in:
parent
cca3012a53
commit
020c0c306f
3 changed files with 4 additions and 20 deletions
|
|
@ -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);
|
||||
}
|
||||
|
||||
//==============================================================================
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue