mirror of
https://github.com/openmc-dev/openmc.git
synced 2026-07-28 22:26:08 -04:00
Per the suggestion of @GiudGiud, added the _divide_by_density = False to the applicable delayed MGXS classes.
This commit is contained in:
parent
9abaf3fb2e
commit
17c8efbaae
1 changed files with 18 additions and 4 deletions
|
|
@ -392,7 +392,7 @@ class MDGXS(MGXS):
|
|||
nuclides=query_nuclides, value=value)
|
||||
|
||||
# Divide by atom number densities for microscopic cross sections
|
||||
if xs_type == 'micro':
|
||||
if xs_type == 'micro' and self._divide_by_density:
|
||||
if self.by_nuclide:
|
||||
densities = self.get_nuclide_densities(nuclides)
|
||||
else:
|
||||
|
|
@ -860,7 +860,7 @@ class MDGXS(MGXS):
|
|||
df = df[df['group out'].isin(groups)]
|
||||
|
||||
# If user requested micro cross sections, divide out the atom densities
|
||||
if xs_type == 'micro':
|
||||
if xs_type == 'micro' and self._divide_by_density:
|
||||
if self.by_nuclide:
|
||||
densities = self.get_nuclide_densities(nuclides)
|
||||
else:
|
||||
|
|
@ -1005,6 +1005,11 @@ class ChiDelayed(MDGXS):
|
|||
|
||||
"""
|
||||
|
||||
# Store whether or not the number density should be removed for microscopic
|
||||
# values of this data; since this chi data is normalized to 1.0, the
|
||||
# data should not be divided by the number density
|
||||
_divide_by_density = False
|
||||
|
||||
def __init__(self, domain=None, domain_type=None, energy_groups=None,
|
||||
delayed_groups=None, by_nuclide=False, name='',
|
||||
num_polar=1, num_azimuthal=1):
|
||||
|
|
@ -1089,7 +1094,6 @@ class ChiDelayed(MDGXS):
|
|||
|
||||
return self._get_homogenized_mgxs(other_mgxs, 'delayed-nu-fission-in')
|
||||
|
||||
|
||||
def get_slice(self, nuclides=[], groups=[], delayed_groups=[]):
|
||||
"""Build a sliced ChiDelayed for the specified nuclides and energy
|
||||
groups.
|
||||
|
|
@ -1653,6 +1657,11 @@ class Beta(MDGXS):
|
|||
|
||||
"""
|
||||
|
||||
# Store whether or not the number density should be removed for microscopic
|
||||
# values of this data; since the beta is not a microscopic or macroscopic
|
||||
# quantity, it should not be divided by the number density
|
||||
_divide_by_density = False
|
||||
|
||||
def __init__(self, domain=None, domain_type=None, energy_groups=None,
|
||||
delayed_groups=None, by_nuclide=False, name='',
|
||||
num_polar=1, num_azimuthal=1):
|
||||
|
|
@ -1838,6 +1847,11 @@ class DecayRate(MDGXS):
|
|||
|
||||
"""
|
||||
|
||||
# Store whether or not the number density should be removed for microscopic
|
||||
# values of this data; since the decay rates are not microscopic or
|
||||
# macroscopic quantities, it should not be divided by the number density.
|
||||
_divide_by_density = False
|
||||
|
||||
def __init__(self, domain=None, domain_type=None, energy_groups=None,
|
||||
delayed_groups=None, by_nuclide=False, name='',
|
||||
num_polar=1, num_azimuthal=1):
|
||||
|
|
@ -2161,7 +2175,7 @@ class MatrixMDGXS(MDGXS):
|
|||
nuclides=query_nuclides, value=value)
|
||||
|
||||
# Divide by atom number densities for microscopic cross sections
|
||||
if xs_type == 'micro':
|
||||
if xs_type == 'micro' and self._divide_by_density:
|
||||
if self.by_nuclide:
|
||||
densities = self.get_nuclide_densities(nuclides)
|
||||
else:
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue