- particleThe particle to filter for. At present cross sections can only be generated for neutrons or photons, if 'electron' or 'positron' are selected an error will be thrown.
C++ Type:MooseEnum
Controllable:No
Description:The particle to filter for. At present cross sections can only be generated for neutrons or photons, if 'electron' or 'positron' are selected an error will be thrown.
- tally_typeThe type of spatial tally to use
C++ Type:MooseEnum
Controllable:No
Description:The type of spatial tally to use
SetupMGXSAction
SetupMGXSAction
can only set up multi-group cross section generation in problems which contain a OpenMCCellAverageProblem in the [Problem]
block. Otherwise, attempting to add multi-group cross sections will result in an error.
Overview
The SetupMGXSAction
action is responsible for automating the generation of MGXS on Cardinal's mesh mirror for coupled deterministic codes. The type of spatial discretization used for MGXS homogenization is selected by setting tally_type
to cell
(to select a distributed cell tally) or to mesh
(to select an unstructured mesh tally). The energy groups boundaries used can either be specified in energy_boundaries
, or a common group structure can be selected by setting group_structure
. The type of particle to filter for can be selected in particle
- at present valid options include neutron
and photon
cross sections. The tally estimator used to generate the MGXS can be selected by setting estimator
. Please note that if you request the generation of MGXS derived from nu-scatter
/ nu-fission
scores the choice of estimator will be overriden to analog
(a limitation of the current implementation), and setting tally_type = mesh
requires a non-tracklength estimator. A description of the group properties available through this action can be found below.
Supported Group Properties
SetupMGXSAction
implements MGXS generation in a manner similar to that of OpenMC's MGXS Python API. We provide a brief overview of this approach below; for additional details we refer users to OpenMC's MGXS documentation.
Total Cross Sections
At a minimum, this action always computes total MGXS, which is computed with the following formula:
(1)
where
(2)
and
(3)
is the homogenized total MGXS, is the homogenization volume (determined by tally_type
), is the continuous-energy total macroscopic cross section, and is the continuous energy angular flux.
Absorption Cross Sections
Absorption cross sections can be added by setting add_absorption = true
, and are calculated with the following:
(4)
where
(5)
is the homogenized absorption MGXS and is the equivalent continuous-energy macroscopic cross section.
Nu-Scattering Matrices
By default this action adds MGXS scattering matrices with particle multiplication. If the user does not wish to compute nu-scatter
matrices, add_scattering
can be set to false
to disable them. Scattering cross sections are expanded in Legendre moments of , where is the direction entering a scattering reaction and is the direction exiting a scattering reaction. The maximum order of the Legendre expansion can be specified by setting legendre_order
(where the default of 0 indicates isotropic scattering). At present, SetupMGXSAction
implements a 'simple' formulation of the scattering matrix where the elements are computed with analog
estimators:
(6)
where
(7)
is the homogenized nu-scatter MGXS, is the equivalent continuous-energy macroscopic cross section, are the Legendre polynomials, and indicates the energy entering a scattering reaction. SetupMGXSAction
supports transport corrected P0 () scattering cross sections, which are computed with the following:
(8)
where is the Khronecker delta function. The transport correction can be applied by setting transport_correction = true
.
Nu-Fission Cross Sections
Nu-fission (neutron production) cross sections can be added by setting add_fission = true
, and are calculated with the following:
(9)
where
(10)
is the homogenized neutron production MGXS and is the equivalent continuous-energy macroscopic cross section. The tallies used to compute are also used to compute , necessitating the use of an analog
estimator for . This cross section is not available for photons.
Discrete Chi Spectra
Discrete chi spectra can also be added by setting add_fission = true
, and are computed with the following:
(11)
where
(12)
and
(13)
is the homogenized MG chi spectra and is the equivalent continuous-energy spectra. The need to know the entering and exiting energies for the nu-fission reaction rate necessitates the use of an analog
estimator for . This property is not available for photons.
Fission Heating Values
Fission heating values can be added by setting add_fission_heating = true
, and are computed with the following:
(14)
where
(15)
is the homogenized MG fission heating cross section and is the equivalent continuous-energy cross section. This property is not available for photons.
Inverse Velocity Values
Inverse velocity values can be added by setting add_inverse_velocity = true
, and are computed with the following:
(16)
where
(17)
is the homogenized MG inverse velocity and is the associated continuous energy velocity.
Particle Diffusion Coefficients
Particle diffusion coefficients can be added by setting add_diffusion_coefficient = true
, and are computed with the following:
(18)
(19)
is the homogenized MG diffusion coefficient and is the homogenized transport MGXS.
Example Input Syntax
The example below computes every available group property using a distributed cell tally for spatial homogenization and the CASMO-2 energy group structure.
[Problem<<<{"href": "../index.html"}>>>]
type = OpenMCCellAverageProblem
verbose = true
cell_level = 0
power = 1.0
source_rate_normalization = 'kappa_fission'
# Some tally results will be missed as photon transport is enabled, but we filter MGXS tallies by a single particle type.
# This forces us to disable global normalization.
normalize_by_global_tally = false
[MGXS<<<{"href": "index.html"}>>>]
tally_type<<<{"description": "The type of spatial tally to use"}>>> = cell
particle<<<{"description": "The particle to filter for. At present cross sections can only be generated for neutrons or photons, if 'electron' or 'positron' are selected an error will be thrown."}>>> = neutron
group_structure<<<{"description": "The energy group structure to use from a list of popular group structures."}>>> = CASMO_2
estimator<<<{"description": "The type of estimator to use with the tallies added for MGXS generation. This is not applied to scattering / fission scores as the filters applied to those scores only support analog estimators."}>>> = 'analog'
hide_tally_vars<<<{"description": "Whether or not tally variables used to compute multi-group cross sections are hidden in exodus output."}>>> = true
add_scattering<<<{"description": "Whether or not the scattering multi-group cross section matrix should be generated."}>>> = true
legendre_order<<<{"description": "The order of the Legendre expansion in scattering angle to use for generating scattering cross sections. Defaults to 0."}>>> = 0
transport_correction<<<{"description": "Whether the in-group scattering cross section should include a P0 transport correction or not."}>>> = true
add_fission<<<{"description": "Whether or not fission multi-group cross sections (neutron production and the discrete chi spectrum) should be generated."}>>> = true
add_fission_heating<<<{"description": "Whether or not per-group fission heating (kappa-fission) values should be generated."}>>> = true
add_inverse_velocity<<<{"description": "Whether or not per-group inverse velocities should be generated."}>>> = true
add_diffusion_coefficient<<<{"description": "Whether or not per-group particle diffusion coefficients should be generated."}>>> = true
add_absorption<<<{"description": "Whether or not absorption multi-group cross sections should be generated."}>>> = true
[]
[]
(cardinal/test/tests/neutronics/gen_mgxs/all_mgxs_cell.i)Input Parameters
- active__all__ If specified only the blocks named will be visited and made active
Default:__all__
C++ Type:std::vector<std::string>
Controllable:No
Description:If specified only the blocks named will be visited and made active
- add_absorptionFalseWhether or not absorption multi-group cross sections should be generated.
Default:False
C++ Type:bool
Controllable:No
Description:Whether or not absorption multi-group cross sections should be generated.
- add_diffusion_coefficientFalseWhether or not per-group particle diffusion coefficients should be generated.
Default:False
C++ Type:bool
Controllable:No
Description:Whether or not per-group particle diffusion coefficients should be generated.
- add_fissionFalseWhether or not fission multi-group cross sections (neutron production and the discrete chi spectrum) should be generated.
Default:False
C++ Type:bool
Controllable:No
Description:Whether or not fission multi-group cross sections (neutron production and the discrete chi spectrum) should be generated.
- add_fission_heatingFalseWhether or not per-group fission heating (kappa-fission) values should be generated.
Default:False
C++ Type:bool
Controllable:No
Description:Whether or not per-group fission heating (kappa-fission) values should be generated.
- add_inverse_velocityFalseWhether or not per-group inverse velocities should be generated.
Default:False
C++ Type:bool
Controllable:No
Description:Whether or not per-group inverse velocities should be generated.
- add_scatteringTrueWhether or not the scattering multi-group cross section matrix should be generated.
Default:True
C++ Type:bool
Controllable:No
Description:Whether or not the scattering multi-group cross section matrix should be generated.
- blockThe list of block ids (SubdomainID) to which this action will be applied
C++ Type:std::vector<SubdomainName>
Controllable:No
Description:The list of block ids (SubdomainID) to which this action will be applied
- energy_boundariesThe energy boundaries to use to form energy bins. The boundaries must be provided in ascending order in terms of energy.
C++ Type:std::vector<double>
Unit:(no unit assumed)
Controllable:No
Description:The energy boundaries to use to form energy bins. The boundaries must be provided in ascending order in terms of energy.
- estimatortracklengthThe type of estimator to use with the tallies added for MGXS generation. This is not applied to scattering / fission scores as the filters applied to those scores only support analog estimators.
Default:tracklength
C++ Type:MooseEnum
Controllable:No
Description:The type of estimator to use with the tallies added for MGXS generation. This is not applied to scattering / fission scores as the filters applied to those scores only support analog estimators.
- group_structureThe energy group structure to use from a list of popular group structures.
C++ Type:MooseEnum
Controllable:No
Description:The energy group structure to use from a list of popular group structures.
- hide_tally_varsTrueWhether or not tally variables used to compute multi-group cross sections are hidden in exodus output.
Default:True
C++ Type:bool
Controllable:No
Description:Whether or not tally variables used to compute multi-group cross sections are hidden in exodus output.
- inactiveIf specified blocks matching these identifiers will be skipped.
C++ Type:std::vector<std::string>
Controllable:No
Description:If specified blocks matching these identifiers will be skipped.
- legendre_order0The order of the Legendre expansion in scattering angle to use for generating scattering cross sections. Defaults to 0.
Default:0
C++ Type:unsigned int
Controllable:No
Description:The order of the Legendre expansion in scattering angle to use for generating scattering cross sections. Defaults to 0.
- transport_correctionTrueWhether the in-group scattering cross section should include a P0 transport correction or not.
Default:True
C++ Type:bool
Controllable:No
Description:Whether the in-group scattering cross section should include a P0 transport correction or not.
- void_diffusion_coefficient1000The value the diffusion coefficient should take in a void region.
Default:1000
C++ Type:double
Unit:(no unit assumed)
Controllable:No
Description:The value the diffusion coefficient should take in a void region.
Optional Parameters
- control_tagsAdds user-defined labels for accessing object parameters via control logic.
C++ Type:std::vector<std::string>
Controllable:No
Description:Adds user-defined labels for accessing object parameters via control logic.