- bin_labelThe label that is used for this filter's bins.
C++ Type:std::string
Controllable:No
Description:The label that is used for this filter's bins.
- filter_idThe id of the OpenMC filter that this class should provide to Cardinal tallies.
C++ Type:int
Controllable:No
Description:The id of the OpenMC filter that this class should provide to Cardinal tallies.
FromXMLFilter
FromXMLFilter
can only be added to problems when the input file contains a OpenMCCellAverageProblem in the [Problem]
block. Otherwise, attempting to add this filter will result in an error.
Description
The FromXMLFilter
object provides a thin wrapper around an arbitrary OpenMC filter which has been added to the problem through the problem through the tallies.xml
OpenMC input file. FromXMLFilter
fetches the filter through a filter id provided in filter_id
which must match the id of a filter in tallies.xml
. The bins of this filter are labelled with a string provided in bin_label
.
FromXMLFilter
will error if you attempt to use one of OpenMC's functional expansion filters. These include the LegendreFilter, SpatialLegendreFilter, SphericalHarmonicsFilter, ZernikeFilter, ZernikeRadialFilter, and EnergyFunctionFilter. Cardinal requires each tally bin in a score to have the same units in order to compute a tally sum and tally mean for normalization; this may not be the case for tallies which use a functional expansion filter. This behavior can be overridden by setting allow_expansion_filters = true
, however Cardinal may produce erroneous results during tally normalization. It is the user's responsibility to ensure that any errors caused by the use of a functional expansion filter are corrected during post-processing or other stages of a Cardinal simulation.
Example Input File Syntax
As an example, a MeshTally named Flux
applies a FromXMLFilter
named SPH_XML
to compute the first four spherical harmonics moments of a l = 1
spherical harmonics expansion. The SphericalHarmonicsFilter
is added through the tallies.xml
file with an id = 1
. Note that allow_expansion_filters = true
, but no renormalization is performed so the computed spherical harmonics moments are erroneous.
[Problem]
type = OpenMCCellAverageProblem
verbose = true
power = 1e4
temperature_blocks = '100'
cell_level = 0
initial_properties = xml
source_rate_normalization = 'kappa_fission'
check_tally_sum = false
normalize_by_global_tally = true
[Tallies]
[Heating]
type = CellTally
score = 'kappa_fission'
blocks = '100'
[]
[Flux]
type = MeshTally
score = 'flux'
mesh_template = ../../meshes/sphere.e
mesh_translations = '0 0 0
0 0 4
0 0 8'
filters = 'SPH_XML'
[]
[]
[Filters]
[SPH_XML]
type = FromXMLFilter
filter_id = 1
bin_label = 'sph'
allow_expansion_filters = true
[]
[]
[]
(test/tests/neutronics/filters/xml/mesh.i)Input Parameters
- allow_expansion_filtersFalseWhether functional expansion filters are allowed or not. Tallies with these filters are likely to fail automatic normalization as a sum over all bins may not make sense for a certain functional expansion.
Default:False
C++ Type:bool
Controllable:No
Description:Whether functional expansion filters are allowed or not. Tallies with these filters are likely to fail automatic normalization as a sum over all bins may not make sense for a certain functional expansion.
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.
- enableTrueSet the enabled status of the MooseObject.
Default:True
C++ Type:bool
Controllable:No
Description:Set the enabled status of the MooseObject.