- blockSubdomains for which to add tallies in OpenMC. If not provided, tallies will be applied over the entire domain corresponding to the [Mesh] block.
C++ Type:std::vector<SubdomainName>
Controllable:No
Description:Subdomains for which to add tallies in OpenMC. If not provided, tallies will be applied over the entire domain corresponding to the [Mesh] block.
- blocksThis parameter is deprecated, use 'block' instead!
C++ Type:std::vector<SubdomainName>
Controllable:No
Description:This parameter is deprecated, use 'block' instead!
- check_equal_mapped_tally_volumesFalseWhether to check if the tallied cells map to regions in the mesh of equal volume. This can be helpful to ensure that the volume normalization of OpenMC's tallies doesn't introduce any unintentional distortion just because the mapped volumes are different. You should only set this to true if your OpenMC tally cells are all the same volume!
Default:False
C++ Type:bool
Controllable:No
Description:Whether to check if the tallied cells map to regions in the mesh of equal volume. This can be helpful to ensure that the volume normalization of OpenMC's tallies doesn't introduce any unintentional distortion just because the mapped volumes are different. You should only set this to true if your OpenMC tally cells are all the same volume!
- check_tally_sumFalseWhether to check consistency between the local tallies with a global tally sum. This will require that the integral of the local tally matches a tally with no filters (defined over the entire phase space).
Default:False
C++ Type:bool
Controllable:No
Description:Whether to check consistency between the local tallies with a global tally sum. This will require that the integral of the local tally matches a tally with no filters (defined over the entire phase space).
- equal_tally_volume_abs_tol1e-08Absolute tolerance for comparing tally volumes
Default:1e-08
C++ Type:double
Unit:(no unit assumed)
Range:equal_tally_volume_abs_tol > 0
Controllable:No
Description:Absolute tolerance for comparing tally volumes
- estimatorType of tally estimator to use in OpenMC
C++ Type:MooseEnum
Controllable:No
Description:Type of tally estimator to use in OpenMC
- filtersExternal filters to add to this tally.
C++ Type:std::vector<std::string>
Controllable:No
Description:External filters to add to this tally.
- nameAuxiliary variable name(s) to use for OpenMC tallies. If not specified, defaults to the names of the scores
C++ Type:std::vector<std::string>
Controllable:No
Description:Auxiliary variable name(s) to use for OpenMC tallies. If not specified, defaults to the names of the scores
- normalize_by_global_tallyTrueWhether to normalize local tallies by a global tally (true) or else by the sum of the local tally (false)
Default:True
C++ Type:bool
Controllable:No
Description:Whether to normalize local tallies by a global tally (true) or else by the sum of the local tally (false)
- outputUNRELAXED field(s) to output from OpenMC for each tally score. unrelaxed_tally_std_dev will write the standard deviation of each tally into auxiliary variables named *_std_dev. unrelaxed_tally_rel_error will write the relative standard deviation (unrelaxed_tally_std_dev / unrelaxed_tally) of each tally into auxiliary variables named *_rel_error. unrelaxed_tally will write the raw unrelaxed tally into auxiliary variables named *_raw (replace * with 'name').
C++ Type:MultiMooseEnum
Controllable:No
Description:UNRELAXED field(s) to output from OpenMC for each tally score. unrelaxed_tally_std_dev will write the standard deviation of each tally into auxiliary variables named *_std_dev. unrelaxed_tally_rel_error will write the relative standard deviation (unrelaxed_tally_std_dev / unrelaxed_tally) of each tally into auxiliary variables named *_rel_error. unrelaxed_tally will write the raw unrelaxed tally into auxiliary variables named *_raw (replace * with 'name').
- scoreScore(s) to use in the OpenMC tallies. If not specified, defaults to 'kappa_fission'
C++ Type:MultiMooseEnum
Controllable:No
Description:Score(s) to use in the OpenMC tallies. If not specified, defaults to 'kappa_fission'
- triggerTrigger criterion to determine when OpenMC simulation is complete based on tallies. If multiple scores are specified in 'score, this same trigger is applied to all scores.
C++ Type:MultiMooseEnum
Controllable:No
Description:Trigger criterion to determine when OpenMC simulation is complete based on tallies. If multiple scores are specified in 'score, this same trigger is applied to all scores.
- trigger_ignore_zeros0 Whether tally bins with zero scores are ignored when computing the tally trigger. If only one value of 'trigger_ignore_zeros' is provided, that value is applied to all tally scores.
Default:0
C++ Type:std::vector<bool>
Controllable:No
Description:Whether tally bins with zero scores are ignored when computing the tally trigger. If only one value of 'trigger_ignore_zeros' is provided, that value is applied to all tally scores.
- trigger_thresholdThreshold for the tally trigger
C++ Type:std::vector<double>
Unit:(no unit assumed)
Range:trigger_threshold > 0
Controllable:No
Description:Threshold for the tally trigger
CellTally
Description
The CellTally class wraps an OpenMC tally with a distributed cell filter to enable data transfer from CSG cells to a MooseMesh mirror of the OpenMC geometry. The cell to element mapping established by the OpenMCCellAverageProblem is used to facilitate this data transfer to the mesh mirror. When using a CellTally, block specifies which blocks in the [Mesh] should be tallied. Then, any OpenMC cells that map to those blocks are added to a cell tally, with one bin for each unique cell ID/instance combination. check_equal_mapped_tally_volumes is used to confirm whether each cell in the CellTally has the same mapped volume on the MooseMesh (to a tolerance specified in equal_tally_volume_abs_tol).
Cardinal supports several tally scores which can be specified in the score parameter when adding a tally. Options include:
heating: total nuclear heatingheating_local: same as theheatingscore, except that energy from secondary photons is deposited locallykappa_fission: recoverable energy from fission, including prompt sources (fission fragments, prompt neutrons, prompt gammas) and delayed sources (delayed neutrons, delayed gammas, delayed betas). Neutrino energy is neglected. The energy from photons is assumed to deposit locally.fission_q_prompt: the prompt components of thekappa_fissionscore, except that the energy released is a function of the incident energy by linking to optional fission energy release data.fission_q_recoverable: same as thekappa_fissionscore, except that the score depends on the incident energy by linking to optional fission energy release datadamage_energy: damage energy productionflux: particle scalar fluxH3_production: tritium production reaction ratetotal: the total reaction rateabsorption: the absorption reaction ratescatter: the scattering reaction ratenu_scatter: the scattering reaction rate combined with the total (n, xn) reaction ratefission: the fission reaction ratenu_fission: the fission neutron production rateprompt_nu_fission: the prompt fission neutron production ratedelayed_nu_fission: the delayed fission neutron production ratedecay_rate: the neutron precursor decay constant weighted by the delayed fission neutron production rateinverse_velocity: one over the particle velocity weighted by the particle flux
To obtain the true precursor decay constant or inverse velocity, you need to divide decay_rate by delayed_nu_fission and inverse_velocity by flux (respectively). This requires the addition of either delayed_nu_fission or flux and some additional post-processing.
For more information on the specific meanings of these various scores, please consult the OpenMC tally documentation. Table 1 compares the units from OpenMC and the units of the AuxVariables created for all tally scores supported by Cardinal. Note that for all area or volume units in Table 1, that those units match whatever unit is used in the [Mesh]. The names of the tally auxvariables added by the OpenMCCellAverageProblem can be modified by specifying a name for each score in name.
Table 1: Tally units from OpenMC and the conversion in Cardinal.
| Tally score | OpenMC Units | Cardinal Units |
|---|---|---|
heating | eV / source particle | W / volume |
heating_local | eV / source particle | W / volume |
kappa_fission | eV / source particle | W / volume |
fission_q_prompt | eV / source particle | W / volume |
fission_q_recoverable | eV / source particle | W / volume |
damage_energy | eV / source particle | eV / volume / second |
flux | particle - cm / source particle | particle / area / second |
H3_production | tritium / source particle | tritium / volume / second |
total | total reactions / source particle | total reactions / volume / second |
absorption | absorption reactions / source particle | absorption reactions / volume / second |
scatter | scattering reactions / source particle | scattering reactions / volume / second |
nu_scatter | nu-scattering reactions / source particle | nu-scattering reactions / volume / second |
fission | fission reactions / source particle | fission reactions / volume / second |
nu_fission | nu-fission reactions / source particle | nu-fission reactions / volume / second |
prompt_nu_fission | prompt nu-fission reactions / source particle | prompt nu-fission reactions / volume / second |
delayed_nu_fission | delayed nu-fission reactions / source particle | delayed nu-fission reactions / volume / second |
decay_rate | delayed nu-fission reactions / source particle / s | delayed nu-fission reactions / volume / second^2 |
inverse_velocity | particle-seconds / source particle | particles / volume |
This tally is capable of controlling OpenMC execution through the use of tally triggers. Tallies currently support active batch termination through a relative error indicator, which can be enabled by setting trigger to rel_err for each score in the tally. Scores which do not need to control active batch termination can have a value of none set. If enabled, an appropriate relative error must be set for each score in trigger_threshold.
Certain aspects of tally results can be output as auxiliary variables to the mesh:
unrelaxed_tally: unrelaxed tally; this will append_rawto the tally name and output to the mesh mirrorunrelaxed_tally_rel_error: unrelaxed tally relative error; this will append_rel_errorto the tally name and output to the mesh mirrorunrelaxed_tally_std_dev: unrelaxed tally standard deviation; this will append_std_devto the tally and output to the mesh mirror
Example Input File Syntax
As an example, this CellTally scores kappa_fission (the default tally score) on block 0 and stores the result in a variable named heat_source. This corresponds to tallying the heating for three different fuel pebbles.
[Problem<<<{"href": "../../syntax/Problem/index.html"}>>>]
type = OpenMCCellAverageProblem
verbose = true
power = 1500.0
temperature_blocks = '0'
cell_level = 1
scaling = 100.0
[Tallies<<<{"href": "../../syntax/Problem/Tallies/index.html"}>>>]
[heat_source]
type = CellTally<<<{"description": "A class which implements distributed cell tallies.", "href": "CellTally.html"}>>>
block<<<{"description": "Subdomains for which to add tallies in OpenMC. If not provided, tallies will be applied over the entire domain corresponding to the [Mesh] block."}>>> = '0'
name<<<{"description": "Auxiliary variable name(s) to use for OpenMC tallies. If not specified, defaults to the names of the scores"}>>> = heat_source
[]
[]
[](tutorials/pebbles/openmc.i)Input 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.
Advanced Parameters
Input Files
- (test/tests/userobjects/openmc_nuclide_densities/no_change.i)
- (test/tests/neutronics/dagmc/implicit_comp_material/openmc.i)
- (test/tests/neutronics/dagmc/cell_tallies/with_scaling.i)
- (tutorials/gas_assembly/openmc.i)
- (test/tests/userobjects/volume_calculation/instances/openmc.i)
- (tutorials/pincell_multiphysics/openmc.i)
- (test/tests/userobjects/openmc_tally_editor/openmc_base.i)
- (test/tests/postprocessors/fission_tally_relative_error/multi.i)
- (test/tests/neutronics/filters/energy/cell.i)
- (test/tests/neutronics/dagmc/with_csg/multiple_dag/openmc.i)
- (test/tests/userobjects/volume_calculation/scaling.i)
- (test/tests/neutronics/symmetry/rotational/openmc.i)
- (test/tests/neutronics/filters/sh/openmc_l1.i)
- (test/tests/neutronics/heat_source/default_tally_blocks.i)
- (tutorials/openmc_subchannel/two_coupled/openmc.i)
- (test/tests/neutronics/heat_source/partial_mapping_openmc_union.i)
- (test/tests/neutronics/fixed_source/mapping_solid.i)
- (test/tests/openmc_errors/level/phase_too_high/fluid_too_high.i)
- (test/tests/neutronics/feedback/density_per_cell/openmc.i)
- (test/tests/neutronics/heat_source/from_postprocessor.i)
- (test/tests/neutronics/tally_system/multi_estimator.i)
- (test/tests/neutronics/symmetry/openmc.i)
- (test/tests/neutronics/feedback/triso/different_fill_univs/openmc.i)
- (test/tests/neutronics/tallies/reaction_rates/openmc.i)
- (test/tests/neutronics/triggers/tally_rel_err.i)
- (test/tests/neutronics/relaxation/cell_tallies/openmc_adapt.i)
- (test/tests/neutronics/dagmc/cell_tallies/null_density.i)
- (test/tests/neutronics/filters/sh/openmc_l0_from_l1.i)
- (test/tests/neutronics/filters/polar/mesh.i)
- (test/tests/neutronics/feedback/single_level/openmc.i)
- (test/tests/neutronics/heat_source/partial_mapping_moose_union.i)
- (test/tests/neutronics/fixed_source/mapping_all.i)
- (test/tests/neutronics/gen_mgxs/mgxs_aux/generic_mgxs.i)
- (test/tests/neutronics/gen_mgxs/photon_xs/mgxs_photon.i)
- (test/tests/neutronics/photon/openmc.i)
- (test/tests/neutronics/relaxation/cell_tallies/openmc_nonaligned.i)
- (test/tests/neutronics/filters/energy/mesh.i)
- (test/tests/userobjects/openmc_nuclide_densities/thermal_density.i)
- (test/tests/neutronics/filters/xml/mesh.i)
- (test/tests/neutronics/triggers/ignore_zeros/ignore_zero.i)
- (test/tests/neutronics/relaxation/cell_tallies/multi_tally.i)
- (test/tests/neutronics/solid/openmc_zero.i)
- (test/tests/neutronics/dagmc/wrong_uo.i)
- (test/tests/neutronics/tallies/tritium/openmc.i)
- (test/tests/postprocessors/fission_tally_relative_error/ratio.i)
- (test/tests/neutronics/heat_source/block_restrict_err.i)
- (test/tests/openmc_errors/block_mappings/skipping_moose_feedback.i)
- (test/tests/neutronics/feedback/multi_component_temp/openmc_incorrect_length.i)
- (test/tests/openmc_errors/densities/void_density.i)
- (test/tests/neutronics/feedback/multi_component_temp/multi_vars.i)
- (test/tests/postprocessors/eigenvalue/openmc.i)
- (test/tests/neutronics/symmetry/triso/openmc.i)
- (test/tests/neutronics/heat_source/multi_tally_mapping_solid.i)
- (test/tests/neutronics/heat_source/distrib_cell/solid.i)
- (test/tests/neutronics/tally_grad/finite_diff/openmc_dup.i)
- (test/tests/neutronics/dagmc/with_csg/dag_lattice_outer/openmc.i)
- (test/tests/postprocessors/fission_tally_relative_error/openmc.i)
- (test/tests/neutronics/mg/doppler_slab_lin/openmc_base.i)
- (test/tests/controls/openmc_nuclide_densities/error.i)
- (test/tests/neutronics/filters/particle/cell.i)
- (test/tests/neutronics/gen_mgxs/all_mgxs_cell_l0.i)
- (test/tests/neutronics/tally_system/multi_cell_relax.i)
- (test/tests/neutronics/heat_source/mapping_all.i)
- (test/tests/userobjects/openmc_cell_transform/multiple_cells/translate_cells.i)
- (test/tests/neutronics/gen_mgxs/mgxs_aux/mg_tc_scatter_xs.i)
- (test/tests/neutronics/dagmc/properties.i)
- (test/tests/neutronics/dagmc/cell_tallies/openmc.i)
- (test/tests/openmc_errors/incorrect_var_setup/incorrect_var_type.i)
- (test/tests/openmc_errors/level/total_too_high/level_too_high.i)
- (tutorials/lwr_solid/openmc.i)
- (test/tests/neutronics/feedback/unmapped_moose/openmc.i)
- (test/tests/neutronics/adaptivity/unchanged_sub.i)
- (test/tests/neutronics/indicators/rel_err/openmc_dup.i)
- (test/tests/neutronics/gen_mgxs/all_mgxs_cell_l1.i)
- (test/tests/neutronics/dagmc/cell_tallies/csg_step_2/openmc.i)
- (test/tests/neutronics/filters/legendre/cell.i)
- (test/tests/neutronics/solid/openmc_missing_pebble.i)
- (test/tests/openmc_errors/zero_tally/openmc.i)
- (test/tests/neutronics/dagmc/with_csg/dag_lattice/openmc.i)
- (test/tests/postprocessors/fission_tally_relative_error/openmc_dup.i)
- (test/tests/neutronics/tallies/reaction_rates/openmc_mgxs_rxn.i)
- (test/tests/neutronics/feedback/different_units/openmc_cm.i)
- (test/tests/postprocessors/eigenvalue/xml_directory/openmc.i)
- (test/tests/neutronics/feedback/triso/cache/openmc.i)
- (test/tests/neutronics/filters/filter_no_norm_score.i)
- (test/tests/userobjects/openmc_cell_transform/empty_cell_ids.i)
- (test/tests/neutronics/tally_system/multi_cell.i)
- (test/tests/neutronics/dagmc/with_csg/multi_cell_dag/openmc.i)
- (tutorials/gas_compact/openmc.i)
- (test/tests/openmc_errors/tallies/length.i)
- (test/tests/neutronics/gen_mgxs/mgxs_aux/mg_diffusion_coeff.i)
- (test/tests/userobjects/openmc_nuclide_densities/openmc.i)
- (test/tests/openmc_errors/block_mappings/unequal_volumes.i)
- (test/tests/neutronics/dagmc/density_skin/only_solid.i)
- (test/tests/neutronics/axisymmetric/openmc.i)
- (test/tests/openmc_errors/block_mappings/nonexistent_block.i)
- (test/tests/neutronics/moving_mesh/cell_tally.i)
- (test/tests/neutronics/dagmc/with_csg/mixed_feedback/openmc.i)
- (test/tests/neutronics/heat_source/mapping_solid.i)
- (test/tests/neutronics/output/cell.i)
- (test/tests/neutronics/tally_system/same_scores.i)
- (test/tests/neutronics/dagmc/cell_tallies/one_bin.i)
- (test/tests/neutronics/filters/sh/openmc_l1_mult.i)
- (test/tests/neutronics/feedback/multiple_levels/openmc.i)
- (test/tests/neutronics/dagmc/density_skin/csg_step_2/openmc.i)
- (test/tests/neutronics/tallies/reaction_rates/openmc_delayed_rxn.i)
- (test/tests/neutronics/source/openmc.i)
- (test/tests/neutronics/relaxation/cell_tallies/openmc.i)
- (test/tests/neutronics/feedback/lattice/openmc.i)
- (test/tests/controls/openmc_nuclide_densities/openmc.i)
- (test/tests/openmc_errors/densities/zero_density.i)
- (test/tests/neutronics/filters/legendre/cell_l0_from_l1.i)
- (test/tests/neutronics/filters/no_filter.i)
- (test/tests/neutronics/flux/flux.i)
- (tutorials/gas_compact_multiphysics/openmc_thm.i)
- (tutorials/openmc_subchannel/all_coupled/openmc.i)
- (test/tests/neutronics/dagmc/density_skin/disjoint_bins.i)
- (test/tests/neutronics/heat_source/cell_volumes.i)
- (test/tests/neutronics/tally_system/multi_cell_triggers.i)
- (test/tests/neutronics/heat_source/mapping_fluid.i)
- (test/tests/neutronics/heat_source/multi_tally.i)
- (test/tests/openmc_errors/block_mappings/no_overlap.i)
- (tutorials/gas_compact_multiphysics/openmc_nek.i)
- (test/tests/neutronics/filters/azimuthal/cell.i)
- (test/tests/neutronics/filters/mesh_sum_gold.i)
- (test/tests/neutronics/feedback/interchangeable/openmc.i)
- (test/tests/neutronics/heat_source/custom_name.i)
- (test/tests/neutronics/filters/azimuthal/mesh.i)
- (test/tests/userobjects/openmc_cell_transform/cells_shadow.i)
- (test/tests/neutronics/tally_system/cell_with_unmapped.i)
- (test/tests/neutronics/relaxation/cell_tallies/output_fission_tally.i)
- (test/tests/neutronics/filters/energy/mesh_sum.i)
- (test/tests/neutronics/filters/polar/mesh_sum.i)
- (test/tests/neutronics/feedback/triso/missing_triso_fill/openmc.i)
- (test/tests/openmc_errors/tallies/separate_tallies.i)
- (test/tests/userobjects/openmc_cell_transform/rotate_cells.i)
- (test/tests/neutronics/feedback/multi_component_temp/openmc.i)
- (test/tests/neutronics/filters/energy_out/cell.i)
- (test/tests/neutronics/dagmc/with_csg/openmc.i)
- (test/tests/neutronics/dagmc/density_skin/openmc.i)
- (test/tests/openmc_errors/block_mappings/multiple_phases.i)
- (test/tests/neutronics/feedback/lattice/openmc_scores.i)
- (test/tests/neutronics/filters/azimuthal/mesh_sum.i)
- (tutorials/pebbles/openmc.i)
- (test/tests/neutronics/filters/delayed/cell.i)
- (test/tests/neutronics/feedback/multi_component_density/openmc.i)
- (test/tests/neutronics/filters/polar/cell.i)
- (test/tests/neutronics/indicators/od/openmc_dup.i)
- (test/tests/userobjects/volume_calculation/no_vol.i)
- (test/tests/neutronics/feedback/triso/openmc.i)
- (test/tests/userobjects/openmc_nuclide_densities/only_density.i)
- (test/tests/userobjects/volume_calculation/openmc.i)
- (doc/content/source/actions/multi_tally_example.i)
- (test/tests/neutronics/kinetics/geom_reset/one_bin.i)
- (test/tests/neutronics/filters/multi_filter.i)
- (test/tests/openmc_errors/block_mappings/multiple_tally_settings.i)
- (test/tests/neutronics/feedback/multi_component_density/openmc_incorrect_length.i)
- (test/tests/neutronics/dagmc/implicit_comp_material/csg_equivalent/openmc.i)
- (test/tests/neutronics/dagmc/implicit_comp_material/without_graveyard/openmc.i)
- (test/tests/neutronics/triggers/multi_rel_err.i)
- (test/tests/userobjects/openmc_cell_transform/scaled.i)
- (test/tests/neutronics/filters/xml/cell.i)
- (test/tests/neutronics/relaxation/cell_tallies/dufek_gudowski.i)
- (doc/content/source/problems/smallest_openmc_input.i)
- (test/tests/neutronics/fixed_source/flux.i)
- (test/tests/neutronics/flux/missing_norm.i)
- (test/tests/neutronics/dagmc/with_csg/dag_cell_not_root/openmc.i)
- (test/tests/neutronics/feedback/different_units/openmc.i)
- (test/tests/neutronics/tally_system/multi_diff.i)
- (test/tests/postprocessors/openmc_particles/openmc.i)
- (tutorials/openmc_subchannel/openmc/openmc.i)
- (test/tests/userobjects/openmc_cell_transform/translate_cells.i)
- (test/tests/neutronics/dagmc/cell_tallies/csg_step_1/openmc.i)
- (test/tests/neutronics/adaptivity/cell.i)
- (test/tests/postprocessors/reactivity/openmc.i)
(tutorials/pebbles/openmc.i)
[Mesh]
[pebble]
type = SphereMeshGenerator
nr = 2
radius = 0.015
[]
[repeat]
type = CombinerGenerator
inputs = pebble
positions = '0 0 0.02
0 0 0.06
0 0 0.10'
[]
[]
[AuxVariables]
[cell_temperature]
family = MONOMIAL
order = CONSTANT
[]
[]
[AuxKernels]
[cell_temperature]
type = CellTemperatureAux
variable = cell_temperature
[]
[]
[Problem]
type = OpenMCCellAverageProblem
verbose = true
power = 1500.0
temperature_blocks = '0'
cell_level = 1
scaling = 100.0
[Tallies]
[heat_source]
type = CellTally
block = '0'
name = heat_source
[]
[]
[]
[Executioner]
type = Transient
[]
[Outputs]
exodus = true
csv = true
[]
[Postprocessors]
[heat_source]
type = ElementIntegralVariablePostprocessor
variable = heat_source
[]
[max_tally_rel_err]
type = TallyRelativeError
[]
[k]
type = KEigenvalue
[]
[]
(test/tests/userobjects/openmc_nuclide_densities/no_change.i)
[Mesh]
[g]
type = GeneratedMeshGenerator
dim = 3
nx = 8
ny = 8
nz = 8
xmin = -12.5
xmax = 87.5
ymin = -12.5
ymax = 37.5
zmin = -12.5
zmax = 12.5
[]
[]
[ICs]
[temp]
type = ConstantIC
variable = temp
value = 500.0
[]
[]
[Problem]
type = OpenMCCellAverageProblem
verbose = true
temperature_blocks = '0'
cell_level = 0
power = 100.0
[Tallies]
[Cell]
type = CellTally
block = '0'
[]
[]
[]
[UserObjects]
[mat1]
type = OpenMCNuclideDensities
material_id = 1
names = 'U235'
densities = '0.02'
[]
[]
[Postprocessors]
[k]
type = KEigenvalue
[]
[]
[Executioner]
type = Steady
[]
[Outputs]
csv = true
[]
(test/tests/neutronics/dagmc/implicit_comp_material/openmc.i)
[Mesh]
type = FileMesh
file = ../mesh_tallies/slab.e
allow_renumbering = false
[]
x0 = 12.5
x1 = 37.5
x2 = 62.5
T0 = 600.0
dT = 50.0
[Functions]
[temp]
type = ParsedFunction
expression = 'if (x <= ${x0}, ${fparse T0 - dT}, if (x <= ${x1}, ${T0}, if (x <= ${x2}, ${fparse T0 + dT}, ${fparse T0 + 2 * dT})))'
[]
[]
[AuxKernels]
[temp]
type = FunctionAux
variable = temp
function = temp
execute_on = timestep_begin
[]
[]
[Problem]
type = OpenMCCellAverageProblem
verbose = true
temperature_blocks = '1 2'
cell_level = 0
power = 100.0
skinner = moab
[Tallies]
[Cell]
type = CellTally
block = '1 2'
[]
[]
[]
[UserObjects]
[moab]
type = MoabSkinner
temperature_min = ${fparse T0 - dT}
temperature_max = ${fparse T0 + 2 * dT}
n_temperature_bins = 4
temperature = temp
build_graveyard = true
implicit_complement_material="h2o"
graveyard_scale_inner = 1.1
graveyard_scale_outer = 1.2
[]
[]
[Postprocessors]
[k]
type = KEigenvalue
[]
[k_std_dev]
type = KEigenvalue
output = 'std_dev'
[]
[]
[Executioner]
type = Steady
[]
[Outputs]
csv = true
[]
(test/tests/neutronics/dagmc/cell_tallies/with_scaling.i)
scale = 100.0
[Mesh]
[file]
type = FileMeshGenerator
file = scale_in.e
[]
[]
[AuxVariables]
[cell_temperature]
family = MONOMIAL
order = CONSTANT
[]
[]
[AuxKernels]
[cell_temperature]
type = CellTemperatureAux
variable = cell_temperature
[]
[]
[Functions]
[temp]
type = ParsedFunction
expression = '500.0 + 10.0*x*${scale}'
[]
[]
[AuxKernels]
[temp]
type = FunctionAux
variable = temp
function = temp
execute_on = timestep_begin
[]
[]
[Problem]
type = OpenMCCellAverageProblem
verbose = true
scaling = ${scale}
temperature_blocks = '1 2'
cell_level = 0
power = 16.0
skinner = moab
[Tallies]
[Cell]
type = CellTally
block = '1 2'
[]
[]
[]
[UserObjects]
[moab]
type = MoabSkinner
temperature_min = 300.0
temperature_max = 1500.0
n_temperature_bins = 10
temperature = temp
build_graveyard = true
[]
[]
[Postprocessors]
[k]
type = KEigenvalue
[]
[]
[Executioner]
type = Transient
num_steps = 1
[]
[Outputs]
exodus = true
[]
(tutorials/gas_assembly/openmc.i)
!include common_input.i
num_layers_for_THM = 50 # number of elements in the THM model; for the converged
# case, we set this to 150
[Mesh]
# mesh mirror for the solid regions
[solid]
type = FileMeshGenerator
file = solid_mesh_in.e
[]
# create a mesh for a single coolant channel; because we will receive uniform
# temperatures and densities from THM on each x-y plane, we can use a very coarse
# mesh in the radial direction
[coolant_face]
type = AnnularMeshGenerator
nr = 1
nt = 8
rmin = 0.0
rmax = ${fparse channel_diameter / 2.0}
[]
[extrude]
type = AdvancedExtruderGenerator
input = coolant_face
num_layers = ${num_layers_for_THM}
direction = '0 0 1'
heights = '${height}'
top_boundary = '300' # inlet
bottom_boundary = '400' # outlet
[]
[rename]
type = RenameBlockGenerator
input = extrude
old_block = '1'
new_block = '101'
[]
# repeat the coolant channels and then combine together to get a combined mesh mirror
[repeat]
type = CombinerGenerator
inputs = rename
positions_file = coolant_channel_positions.txt
[]
[add]
type = CombinerGenerator
inputs = 'solid repeat'
[]
[]
[AuxVariables]
[material_id]
family = MONOMIAL
order = CONSTANT
[]
[cell_temperature]
family = MONOMIAL
order = CONSTANT
[]
[cell_density]
family = MONOMIAL
order = CONSTANT
[]
[thm_temp_wall]
block = '101'
[]
[flux]
[]
# just for postprocessing purposes
[thm_pressure]
block = '101'
[]
[thm_velocity]
block = '101'
[]
[z]
family = MONOMIAL
order = CONSTANT
block = 'compacts'
[]
[]
[AuxKernels]
[material_id]
type = CellMaterialIDAux
variable = material_id
[]
[cell_temperature]
type = CellTemperatureAux
variable = cell_temperature
[]
[cell_density]
type = CellDensityAux
variable = cell_density
[]
[density]
type = FluidDensityAux
variable = density
p = ${outlet_P}
T = thm_temp
fp = helium
execute_on = 'timestep_begin linear'
[]
[z]
type = ParsedAux
variable = z
use_xyzt = true
expression = 'z'
[]
[]
[ICs]
[fluid_temp_wall]
type = FunctionIC
variable = thm_temp_wall
function = temp_ic
[]
[fluid_temp]
type = FunctionIC
variable = thm_temp
function = temp_ic
[]
[heat_source]
type = ConstantIC
variable = heat_source
block = 'compacts'
value = ${fparse power / (n_bundles * n_fuel_compacts_per_block) / (pi * compact_diameter * compact_diameter / 4.0 * height)}
[]
[]
[Functions]
[temp_ic]
type = ParsedFunction
expression = '${inlet_T} + (${height} - z) / ${height} * ${power} / ${mdot} / ${fluid_Cp}'
[]
[]
[FluidProperties]
[helium]
type = IdealGasFluidProperties
molar_mass = 4e-3
gamma = 1.668282 # should correspond to Cp = 5189 J/kg/K
k = 0.2556
mu = 3.22639e-5
[]
[]
[Problem]
type = OpenMCCellAverageProblem
identical_cell_fills = '2'
power = ${fparse power / n_bundles}
scaling = 100.0
cell_level = 1
relaxation = constant
relaxation_factor = 0.5
# to get a faster-running tutorial, we use only 1000 particles per batch; converged
# results are instead obtained by increasing this parameter to 10000. We also use fewer
# batches to speed things up; the converged results were obtained with 500 inactive batches
# and 2000 active batches
particles = 1000
inactive_batches = 200
batches = 1000
# we will read temperature from THM (for the fluid) and MOOSE (for the solid)
# into variables we name as 'solid_temp' and 'thm_temp'. This syntax will automatically
# create those variabes for us
temperature_variables = 'solid_temp; thm_temp'
temperature_blocks = '1 2 4; 101'
density_blocks = '101'
[Tallies]
[heat_source]
type = CellTally
block = '2'
name = heat_source
check_equal_mapped_tally_volumes = true
output = 'unrelaxed_tally_std_dev'
[]
[]
[]
[MultiApps]
[bison]
type = TransientMultiApp
input_files = 'solid.i'
execute_on = timestep_begin
[]
[thm]
type = FullSolveMultiApp
input_files = 'thm.i'
execute_on = timestep_end
max_procs_per_app = 1
bounding_box_padding = '0.1 0.1 0'
positions_file = coolant_channel_positions.txt
output_in_position = true
[]
[]
[Transfers]
[solid_temp_to_openmc]
type = MultiAppGeometricInterpolationTransfer
source_variable = T
variable = solid_temp
from_multi_app = bison
[]
[heat_flux_to_openmc]
type = MultiAppGeneralFieldNearestLocationTransfer
source_variable = flux
variable = flux
from_multi_app = bison
from_boundaries = 'fluid_solid_interface'
to_boundaries = 'fluid_solid_interface'
from_postprocessors_to_be_preserved = flux_integral
to_postprocessors_to_be_preserved = flux_integral
[]
[source_to_bison]
type = MultiAppGeneralFieldShapeEvaluationTransfer
source_variable = heat_source
variable = power
to_multi_app = bison
from_postprocessors_to_be_preserved = heat_source
to_postprocessors_to_be_preserved = power
[]
[thm_temp_to_bison]
type = MultiAppGeometricInterpolationTransfer
source_variable = thm_temp_wall
variable = thm_temp
to_multi_app = bison
[]
[q_wall_to_thm]
type = MultiAppGeneralFieldUserObjectTransfer
variable = q_wall
to_multi_app = thm
source_user_object = q_wall_avg
[]
[T_wall_from_thm]
type = MultiAppGeneralFieldNearestLocationTransfer
source_variable = T_wall
from_multi_app = thm
variable = thm_temp_wall
to_boundaries = 'fluid_solid_interface'
[]
[T_bulk_from_thm]
type = MultiAppGeneralFieldNearestLocationTransfer
source_variable = T
from_multi_app = thm
variable = thm_temp
[]
# just for postprocessing purposes
[pressure_from_thm]
type = MultiAppGeneralFieldNearestLocationTransfer
source_variable = p
from_multi_app = thm
variable = thm_pressure
[]
[velocity_from_thm]
type = MultiAppGeneralFieldNearestLocationTransfer
source_variable = vel_z
from_multi_app = thm
variable = thm_velocity
[]
[]
[UserObjects]
[q_wall_avg]
type = NearestPointLayeredSideAverage
boundary = 'fluid_solid_interface'
variable = flux
# Note: make this to match the num_elems in the channel
direction = z
num_layers = ${num_layers_for_THM}
points_file = coolant_channel_positions.txt
direction_min = 0.0
direction_max = ${height}
[]
[average_power_axial]
type = LayeredAverage
variable = heat_source
direction = z
num_layers = ${num_layers_for_plots}
block = 'compacts'
[]
[average_fluid_axial]
type = LayeredAverage
variable = thm_temp
direction = z
num_layers = ${num_layers_for_plots}
block = '101'
[]
[average_pressure]
type = LayeredAverage
variable = thm_pressure
direction = z
num_layers = ${num_layers_for_plots}
block = '101'
[]
[average_axial_velocity]
type = LayeredAverage
variable = thm_velocity
direction = z
num_layers = ${num_layers_for_plots}
block = '101'
[]
[]
[VectorPostprocessors]
[power_avg]
type = SpatialUserObjectVectorPostprocessor
userobject = average_power_axial
[]
[fluid_avg]
type = SpatialUserObjectVectorPostprocessor
userobject = average_fluid_axial
[]
[pressure_avg]
type = SpatialUserObjectVectorPostprocessor
userobject = average_pressure
[]
[velocity_avg]
type = SpatialUserObjectVectorPostprocessor
userobject = average_axial_velocity
[]
[]
[Postprocessors]
[flux_integral]
type = SideIntegralVariablePostprocessor
variable = flux
boundary = 'fluid_solid_interface'
execute_on = 'transfer linear'
[]
[heat_source]
type = ElementIntegralVariablePostprocessor
variable = heat_source
execute_on = 'transfer initial timestep_end'
[]
[max_tally_rel_err]
type = TallyRelativeError
value_type = max
[]
[k]
type = KEigenvalue
[]
[k_std_dev]
type = KEigenvalue
output = 'std_dev'
[]
[min_power]
type = ElementExtremeValue
variable = heat_source
value_type = min
block = 'compacts'
[]
[max_power]
type = ElementExtremeValue
variable = heat_source
value_type = max
block = 'compacts'
[]
[z_max_power]
type = ElementExtremeValue
proxy_variable = heat_source
variable = z
block = 'compacts'
[]
[max_Tf]
type = ElementExtremeValue
variable = thm_temp
block = '101'
[]
[P_in]
type = SideAverageValue
variable = thm_pressure
boundary = '300'
[]
[pressure_drop]
type = LinearCombinationPostprocessor
pp_names = 'P_in'
pp_coefs = '1.0'
b = '${fparse -outlet_P}'
[]
[]
[Executioner]
type = Transient
num_steps = 10
[]
[Outputs]
exodus = true
csv = true
hide = 'P_in flux_integral z'
[]
(test/tests/userobjects/volume_calculation/instances/openmc.i)
[Mesh]
type = FileMesh
file = ../../../neutronics/meshes/pincell.e
[]
[AuxVariables]
[cell_vol]
family = MONOMIAL
order = CONSTANT
[]
[]
[AuxKernels]
[cell_vol]
type = CellVolumeAux
variable = cell_vol
volume_type = actual
[]
[]
[Problem]
type = OpenMCCellAverageProblem
power = 500.0
temperature_blocks = '1 2 3'
density_blocks = '2'
verbose = true
cell_level = 1
volume_calculation = vol
initial_properties = xml
[Tallies]
[Cell]
type = CellTally
block = '1'
name = heat_source
[]
[]
[]
[UserObjects]
[vol]
type = OpenMCVolumeCalculation
n_samples = 1000
[]
[]
[Executioner]
type = Steady
[]
[Postprocessors]
[p1]
type = PointValue
variable = cell_vol
point = '0.0 0.0 0.5'
[]
[p2]
type = PointValue
variable = cell_vol
point = '0.0 0.0 1.5'
[]
[p3]
type = PointValue
variable = cell_vol
point = '0.0 0.0 2.5'
[]
[p4]
type = PointValue
variable = cell_vol
point = '0.0 0.0 3.5'
[]
[p5]
type = PointValue
variable = cell_vol
point = '0.0 0.0 4.5'
[]
[p6]
type = PointValue
variable = cell_vol
point = '0.0 0.0 5.5'
[]
[p7]
type = PointValue
variable = cell_vol
point = '0.0 0.0 6.5'
[]
[p8]
type = PointValue
variable = cell_vol
point = '0.0 0.0 7.5'
[]
[p9]
type = PointValue
variable = cell_vol
point = '0.0 0.0 8.5'
[]
[p10]
type = PointValue
variable = cell_vol
point = '0.0 0.0 9.5'
[]
[]
[Outputs]
csv = true
[]
(tutorials/pincell_multiphysics/openmc.i)
inlet_T = 573.0 # inlet temperature
power = 1e3 # total power (W)
Re = 500.0 # Reynolds number
outlet_P = 1e6
height = 0.5 # total height of the domain
Df = 0.825e-2 # fuel diameter
pin_diameter = 0.97e-2 # pin outer diameter
pin_pitch = 1.28e-2 # pin pitch
mu = 8.8e-5 # fluid dynamic viscosity
rho = 723.6 # fluid density
Cp = 5512.0 # fluid isobaric specific heat capacity
Rf = ${fparse Df / 2.0}
flow_area = ${fparse pin_pitch * pin_pitch - pi * pin_diameter * pin_diameter / 4.0}
wetted_perimeter = ${fparse pi * pin_diameter}
hydraulic_diameter = ${fparse 4.0 * flow_area / wetted_perimeter}
U_ref = ${fparse Re * mu / rho / hydraulic_diameter}
mdot = ${fparse rho * U_ref * flow_area}
dT = ${fparse power / mdot / Cp}
[Mesh]
[solid]
type = FileMeshGenerator
file = solid_in.e
[]
[]
[AuxVariables]
# These auxiliary variables are all just for visualizing the solution and
# the mapping - none of these are part of the calculation sequence
[material_id]
family = MONOMIAL
order = CONSTANT
[]
[cell_temperature]
family = MONOMIAL
order = CONSTANT
[]
[cell_density]
family = MONOMIAL
order = CONSTANT
[]
[]
[AuxKernels]
[material_id]
type = CellMaterialIDAux
variable = material_id
[]
[cell_temperature]
type = CellTemperatureAux
variable = cell_temperature
[]
[cell_density]
type = CellDensityAux
variable = cell_density
[]
[density]
type = FluidDensityAux
variable = density
p = ${outlet_P}
T = nek_temp
fp = sodium
execute_on = 'INITIAL TIMESTEP_END'
[]
[]
[FluidProperties]
[sodium]
type = SodiumSaturationFluidProperties
[]
[]
[ICs]
[nek_temp]
type = FunctionIC
variable = nek_temp
function = temp_ic
[]
[solid_temp]
type = FunctionIC
variable = solid_temp
function = temp_ic
[]
[heat_source]
type = ConstantIC
variable = heat_source
block = '2'
value = ${fparse power / (pi * Rf * Rf * height)}
[]
[]
[Functions]
[temp_ic]
type = ParsedFunction
expression = '${inlet_T} + z / ${height} * ${dT}'
[]
[]
[Problem]
type = OpenMCCellAverageProblem
power = ${power}
scaling = 100.0
density_blocks = '1'
cell_level = 0
# This automatically creates these variables and will read from the non-default choice of 'temp'
temperature_variables = 'solid_temp; nek_temp'
temperature_blocks = '2 3; 1'
relaxation = robbins_monro
# Set some parameters for when we terminate the OpenMC solve in each iteration;
# this will run a minimum of 30 batches, and after that, terminate once reaching
# the specified std. dev. of k and rel. err. of the fission tally
inactive_batches = 20
batches = 30
k_trigger = std_dev
k_trigger_threshold = 7.5e-4
batch_interval = 50
max_batches = 1000
[Tallies]
[heat_source]
type = CellTally
block = '2'
name = heat_source
check_equal_mapped_tally_volumes = true
trigger = rel_err
trigger_threshold = 2e-2
output = unrelaxed_tally_std_dev
[]
[]
[]
[MultiApps]
[bison]
type = TransientMultiApp
input_files = 'bison.i'
execute_on = timestep_begin
sub_cycling = true
[]
[]
[Transfers]
[solid_temp_to_openmc]
type = MultiAppGeneralFieldShapeEvaluationTransfer
source_variable = T
variable = solid_temp
from_multi_app = bison
[]
[source_to_bison]
type = MultiAppCopyTransfer
source_variable = heat_source
variable = power
to_multi_app = bison
from_blocks = '2'
to_blocks = '2'
[]
[temp_from_nek]
type = MultiAppGeneralFieldShapeEvaluationTransfer
source_variable = nek_temp
from_multi_app = bison
variable = nek_temp
[]
[]
[Outputs]
exodus = true
csv = true
[]
[Executioner]
type = Transient
dt = 0.5
num_steps = 10
[]
[Postprocessors]
[max_tally_rel_err]
type = TallyRelativeError
value_type = max
[]
[k]
type = KEigenvalue
[]
[k_std_dev]
type = KEigenvalue
output = 'std_dev'
[]
[]
(test/tests/userobjects/openmc_tally_editor/openmc_base.i)
[Mesh]
[g]
type = GeneratedMeshGenerator
dim = 3
nx = 8
ny = 8
nz = 8
xmin = -12.5
xmax = 87.5
ymin = -12.5
ymax = 37.5
zmin = -12.5
zmax = 12.5
[]
[]
[Problem]
type = OpenMCCellAverageProblem
cell_level = 0
power = 100.0
[Tallies]
[Cell]
type = CellTally
block = '0'
[]
[]
[]
[Postprocessors]
[power_1]
type = PointValue
variable = kappa_fission
point = '0.0 -12.0 0.0'
[]
[power_2]
type = PointValue
variable = kappa_fission
point = '0.0 37.0 0.0'
[]
[]
[Executioner]
type = Steady
[]
[Outputs]
csv = true
[]
(test/tests/postprocessors/fission_tally_relative_error/multi.i)
[Mesh]
[sphere]
type = FileMeshGenerator
file = ../../neutronics/meshes/sphere.e
[]
[solid]
type = CombinerGenerator
inputs = sphere
positions = '0 0 0
0 0 4
0 0 8'
[]
[solid_ids]
type = SubdomainIDGenerator
input = solid
subdomain_id = '100'
[]
[]
[Problem]
type = OpenMCCellAverageProblem
power = 100.0
temperature_blocks = '100'
cell_level = 0
initial_properties = xml
[Tallies]
[Cell]
type = CellTally
block = '100'
score = 'heating kappa_fission'
check_tally_sum = false
# this outputs the fission tally standard deviation in space
output = 'unrelaxed_tally_std_dev'
[]
[]
[]
[Executioner]
type = Transient
num_steps = 1
[]
[Postprocessors]
[max_rel_err_ht]
type = TallyRelativeError
value_type = max
tally_score = 'heating'
[]
[min_rel_err_ht]
type = TallyRelativeError
value_type = min
tally_score = 'heating'
[]
[avg_rel_err_ht]
type = TallyRelativeError
value_type = average
tally_score = 'heating'
[]
[max_rel_err_kf]
type = TallyRelativeError
value_type = max
tally_score = 'kappa_fission'
[]
[min_rel_err_kf]
type = TallyRelativeError
value_type = min
tally_score = 'kappa_fission'
[]
[avg_rel_err_kf]
type = TallyRelativeError
value_type = average
tally_score = 'kappa_fission'
[]
[]
[Outputs]
csv = true
[]
(test/tests/neutronics/filters/energy/cell.i)
[Mesh]
[sphere]
type = FileMeshGenerator
file = ../../meshes/sphere.e
[]
[solid]
type = CombinerGenerator
inputs = sphere
positions = '0 0 0
0 0 4
0 0 8'
[]
[solid_ids]
type = SubdomainIDGenerator
input = solid
subdomain_id = '100'
[]
[fluid]
type = FileMeshGenerator
file = ../../heat_source/stoplight.exo
[]
[fluid_ids]
type = SubdomainIDGenerator
input = fluid
subdomain_id = '200'
[]
[combine]
type = CombinerGenerator
inputs = 'solid_ids fluid_ids'
[]
allow_renumbering = false
[]
[Problem]
type = OpenMCCellAverageProblem
verbose = true
power = 1e4
temperature_blocks = '100'
cell_level = 0
initial_properties = xml
source_rate_normalization = 'kappa_fission'
[Tallies]
[Heating]
type = CellTally
score = 'kappa_fission'
block = '100 200'
[]
[Flux]
type = CellTally
score = 'flux'
block = '100 200'
filters = 'Energy'
[]
[]
[Filters]
[Energy]
type = EnergyFilter
# CASMO 2 group structure for testing. May result in some missed particles
[]
[]
[]
[Postprocessors]
[Pebble_1_Flux_1]
type = PointValue
point = '0 0 0'
variable = flux_g1
[]
[Pebble_2_Flux_1]
type = PointValue
point = '0 0 4'
variable = flux_g1
[]
[Pebble_3_Flux_1]
type = PointValue
point = '0 0 8'
variable = flux_g1
[]
[Pebble_1_Flux_2]
type = PointValue
point = '0 0 0'
variable = flux_g2
[]
[Pebble_2_Flux_2]
type = PointValue
point = '0 0 4'
variable = flux_g2
[]
[Pebble_3_Flux_2]
type = PointValue
point = '0 0 8'
variable = flux_g2
[]
[]
[Executioner]
type = Steady
[]
[Outputs]
csv = true
[]
(test/tests/neutronics/dagmc/with_csg/multiple_dag/openmc.i)
[Mesh]
[slab]
type = FileMeshGenerator
file = ../../mesh_tallies/slab.e
[]
allow_renumbering = false
parallel_type = replicated
[]
[AuxVariables]
[cell_temperature]
family = MONOMIAL
order = CONSTANT
[]
[]
[AuxKernels]
[cell_temperature]
type = CellTemperatureAux
variable = cell_temperature
[]
[]
[AuxKernels]
[temp]
type = ConstantAux
variable = temp
value = 500.0
execute_on = timestep_begin
[]
[]
[Problem]
type = OpenMCCellAverageProblem
verbose = true
temperature_blocks = '1 2'
cell_level = 1
power = 100.0
skinner = moab
[Tallies]
[Cell]
type = CellTally
block = '1 2'
[]
[]
[]
[UserObjects]
[moab]
type = MoabSkinner
temperature_min = 0.0
temperature_max = 1000.0
n_temperature_bins = 1
temperature = temp
build_graveyard = true
[]
[]
[Postprocessors]
[k]
type = KEigenvalue
[]
[]
[Executioner]
type = Transient
num_steps = 2
[]
[Outputs]
exodus = true
hide = 'temp'
[]
(test/tests/userobjects/volume_calculation/scaling.i)
[Mesh]
[sphere]
type = FileMeshGenerator
file = ../../neutronics/meshes/sphere.e
[]
[solid]
type = CombinerGenerator
inputs = sphere
positions = '0 0 0
0 0 4
0 0 8'
[]
[solid_ids]
type = SubdomainIDGenerator
input = solid
subdomain_id = '100'
[]
[fluid]
type = FileMeshGenerator
file = ../../neutronics/heat_source/stoplight.exo
[]
[fluid_ids]
type = SubdomainIDGenerator
input = fluid
subdomain_id = '200'
[]
[combine]
type = CombinerGenerator
inputs = 'solid_ids fluid_ids'
[]
[scale]
type = TransformGenerator
input = combine
transform = scale
vector_value = '0.01 0.01 0.01'
[]
[]
[AuxVariables]
[cell_vol]
family = MONOMIAL
order = CONSTANT
[]
[]
[AuxKernels]
[cell_vol]
type = CellVolumeAux
variable = cell_vol
volume_type = actual
[]
[]
[Problem]
type = OpenMCCellAverageProblem
power = 100.0
temperature_blocks = '100 200'
density_blocks = '200'
verbose = true
scaling = 100.0
cell_level = 0
initial_properties = xml
volume_calculation = vol
[Tallies]
[Cell]
type = CellTally
block = '100 200'
name = heat_source
[]
[]
[]
[Executioner]
type = Steady
[]
[UserObjects]
[vol]
type = OpenMCVolumeCalculation
n_samples = 10000
[]
[]
[Postprocessors]
[vol_1]
type = PointValue
variable = cell_vol
point = '0.0 0.0 0.0'
[]
[vol_2]
type = PointValue
variable = cell_vol
point = '0.0 0.0 0.04'
[]
[vol_3]
type = PointValue
variable = cell_vol
point = '0.0 0.0 0.08'
[]
[vol_4]
type = PointValue
variable = cell_vol
point = '0.0 0.0 0.02'
[]
[]
[Outputs]
csv = true
[]
(test/tests/neutronics/symmetry/rotational/openmc.i)
[Mesh]
[solid]
type = FileMeshGenerator
file = solid_mesh_in.e
[]
[]
[AuxVariables]
[cell_temperature]
family = MONOMIAL
order = CONSTANT
[]
[]
[AuxKernels]
[cell_temperature]
type = CellTemperatureAux
variable = cell_temperature
[]
[]
[ICs]
[temp]
type = FunctionIC
variable = temp
function = temp
block = 'graphite 200'
[]
[temp_fuel]
type = FunctionIC
variable = temp
function = temp_fuel
block = 'compacts'
[]
[]
# We set an initial temperature distribution that is NOT symmetry about the imposed
# symmmetry plane; by checking the cell temperature, we can ensure that the data
# mapping is done correctly (in addition to checking that the *extracted* heat source
# reflects the imposed symmetry)
[Functions]
[temp]
type = ParsedFunction
expression = '500+(exp(10*x)+exp(10*y))*50'
[]
[temp_fuel]
type = ParsedFunction
expression = '500+(exp(10*x)+exp(10*y))*50 + 100'
[]
[]
[Problem]
type = OpenMCCellAverageProblem
power = 1000.0
scaling = 100.0
temperature_blocks = '1 2 200'
cell_level = 1
symmetry_mapper = sym
[Tallies]
[Cell]
type = CellTally
block = '2'
[]
[]
[]
[UserObjects]
[sym]
type = SymmetryPointGenerator
normal = '${fparse -sqrt(3.0) / 2.0} 0.5 0.0'
rotation_axis = '0.0 0.0 1.0'
rotation_angle = 60.0
[]
[]
[Postprocessors]
[heat_source]
type = ElementIntegralVariablePostprocessor
variable = kappa_fission
block = '2'
[]
# check a few of the pins to be sure that the reflected heat source matches
[pin]
type = PointValue
variable = kappa_fission
point = '0.097 0.097 4.0'
[]
[pin1]
type = PointValue
variable = kappa_fission
point = '0.036 0.13 4.0'
[]
[diff1]
type = DifferencePostprocessor
value1 = pin1
value2 = pin
[]
[pin2]
type = PointValue
variable = kappa_fission
point = '-0.13 0.0313 4.0'
[]
[diff2]
type = DifferencePostprocessor
value1 = pin2
value2 = pin
[]
[pin3]
type = PointValue
variable = kappa_fission
point = '-0.13 -0.032 4.0'
[]
[diff3]
type = DifferencePostprocessor
value1 = pin3
value2 = pin
[]
[pin4]
type = PointValue
variable = kappa_fission
point = '0.039 -0.13 4.0'
[]
[diff4]
type = DifferencePostprocessor
value1 = pin4
value2 = pin
[]
[pin5]
type = PointValue
variable = kappa_fission
point = '0.09 -0.1 4.0'
[]
[diff5]
type = DifferencePostprocessor
value1 = pin5
value2 = pin
[]
[]
[Executioner]
type = Transient
num_steps = 1
[]
[Outputs]
exodus = true
csv = true
hide = 'temp pin pin1 pin2 pin3 pin4 pin5'
[]
(test/tests/neutronics/filters/sh/openmc_l1.i)
[Mesh]
[sphere]
type = FileMeshGenerator
file = ../../meshes/sphere.e
[]
[solid]
type = CombinerGenerator
inputs = sphere
positions = '0 0 0
0 0 4
0 0 8'
[]
[solid_ids]
type = SubdomainIDGenerator
input = solid
subdomain_id = '100'
[]
[fluid]
type = FileMeshGenerator
file = ../../heat_source/stoplight.exo
[]
[fluid_ids]
type = SubdomainIDGenerator
input = fluid
subdomain_id = '200'
[]
[combine]
type = CombinerGenerator
inputs = 'solid_ids fluid_ids'
[]
allow_renumbering = false
[]
[Problem]
type = OpenMCCellAverageProblem
verbose = true
power = 1e4
temperature_blocks = '100'
cell_level = 0
initial_properties = xml
source_rate_normalization = 'kappa_fission'
[Tallies]
[Heating]
type = CellTally
score = 'kappa_fission'
block = '100 200'
[]
[Flux]
type = CellTally
score = 'flux'
block = '100 200'
filters = 'SH'
[]
[]
[Filters]
[SH]
type = SphericalHarmonicsFilter
order = 1
[]
[]
[]
[Postprocessors]
[Pebble_1_Flux_l0_m0]
type = PointValue
point = '0 0 0'
variable = flux_l0_mpos0
[]
[Pebble_1_Flux_l1_m1]
type = PointValue
point = '0 0 0'
variable = flux_l1_mpos1
[]
[Pebble_1_Flux_l1_mn1]
type = PointValue
point = '0 0 0'
variable = flux_l1_mneg1
[]
[]
[Executioner]
type = Steady
[]
[Outputs]
csv = true
[]
(test/tests/neutronics/heat_source/default_tally_blocks.i)
[Mesh]
[sphere]
type = FileMeshGenerator
file = ../meshes/sphere.e
[]
[solid]
type = CombinerGenerator
inputs = sphere
positions = '0 0 0
0 0 4
0 0 8'
[]
[solid_ids]
type = SubdomainIDGenerator
input = solid
subdomain_id = '100'
[]
[fluid]
type = FileMeshGenerator
file = stoplight.exo
[]
[fluid_ids]
type = SubdomainIDGenerator
input = fluid
subdomain_id = '200'
[]
[combine]
type = CombinerGenerator
inputs = 'solid_ids fluid_ids'
[]
[]
[Problem]
type = OpenMCCellAverageProblem
power = 100.0
temperature_blocks = '100 200'
density_blocks = '200'
verbose = true
cell_level = 0
initial_properties = xml
[Tallies]
[Cell]
type = CellTally
name = heat_source
block = '100 200'
[]
[]
[]
[Executioner]
type = Steady
[]
[Postprocessors]
[heat_source]
type = ElementIntegralVariablePostprocessor
variable = heat_source
[]
[fluid_heat_source]
type = ElementIntegralVariablePostprocessor
variable = heat_source
block = '200'
[]
[solid_heat_source]
type = ElementIntegralVariablePostprocessor
variable = heat_source
block = '100'
[]
[]
[Outputs]
execute_on = final
exodus = true
hide = 'density'
[]
(tutorials/openmc_subchannel/two_coupled/openmc.i)
!include ../common.i
[Mesh]
[file]
type = FileMeshGenerator
file = ../meshes/mesh_in.e
[]
[]
[Problem]
type = OpenMCCellAverageProblem
power = ${power}
lowest_cell_level = 2
scaling = 100
temperature_blocks = 'helium fuel clad sodium'
density_blocks = 'sodium'
xml_directory = '../openmc'
[Tallies]
[power]
type = CellTally
score = 'kappa_fission'
[]
[]
[]
[ICs]
[temp]
type = ConstantIC
variable = temp
value = ${inlet_temperature}
[]
[density]
type = ConstantIC
variable = density
value = ${fparse 1.00423e3 + -0.21390*inlet_temperature+-1.1046e-5*inlet_temperature^2}
[]
[]
[AuxVariables]
[cell_temperature]
family = MONOMIAL
order = CONSTANT
[]
[cell_density]
family = MONOMIAL
order = CONSTANT
[]
[]
[AuxKernels]
[cell_temperature]
type = CellTemperatureAux
variable = cell_temperature
[]
[cell_density]
type = CellDensityAux
variable = cell_density
[]
[]
[Executioner]
type = Transient
num_steps = 5
[]
[Outputs]
exodus = true
[]
[MultiApps]
[conduction]
type = TransientMultiApp
input_files = 'conduction.i'
sub_cycling = true
execute_on = timestep_end
[]
[]
[Transfers]
[power_to_conduction]
type = MultiAppGeneralFieldNearestLocationTransfer
to_multi_app = conduction
source_variable = kappa_fission
variable = heat_source
from_postprocessors_to_be_preserved = openmc_power_integral
to_postprocessors_to_be_preserved = conduction_power_integral
[]
[solid_temperature_from_conduction]
type = MultiAppGeneralFieldNearestLocationTransfer
from_multi_app = conduction
source_variable = T
variable = temp
to_blocks = 'fuel clad helium'
[]
[]
[Postprocessors]
[openmc_power_integral]
type = ElementIntegralVariablePostprocessor
variable = kappa_fission
execute_on = 'transfer timestep_end'
[]
[]
(test/tests/neutronics/heat_source/partial_mapping_openmc_union.i)
# In this input, OpenMCs domain includes the entire MOOSE domain, but some
# OpenMC cells are not mapped anywhere (we treat this by removing one sphere
# from the MOOSE mesh).
[Mesh]
[sphere]
type = FileMeshGenerator
file = ../meshes/sphere.e
[]
[solid]
type = CombinerGenerator
inputs = sphere
positions = '0 0 0
0 0 4'
[]
[solid_ids]
type = SubdomainIDGenerator
input = solid
subdomain_id = '100'
[]
[fluid]
type = FileMeshGenerator
file = stoplight.exo
[]
[fluid_ids]
type = SubdomainIDGenerator
input = fluid
subdomain_id = '200'
[]
[combine]
type = CombinerGenerator
inputs = 'solid_ids fluid_ids'
[]
[]
[Problem]
type = OpenMCCellAverageProblem
power = 100.0
temperature_blocks = '100 200'
density_blocks = '200'
initial_properties = xml
verbose = true
cell_level = 0
[Tallies]
[Cell]
type = CellTally
name = heat_source
block = '100 200'
# We are skipping some feedback with fissile regions, so we need to turn off the check
check_tally_sum = false
[]
[]
[]
[Executioner]
type = Steady
[]
[Postprocessors]
[heat_source]
type = ElementIntegralVariablePostprocessor
variable = heat_source
block = '100 200'
[]
[fluid_heat_source]
type = ElementIntegralVariablePostprocessor
variable = heat_source
block = '200'
[]
[solid_heat_source]
type = ElementIntegralVariablePostprocessor
variable = heat_source
block = '100'
[]
[]
[Outputs]
exodus = true
csv = true
hide = 'density'
[]
(test/tests/neutronics/fixed_source/mapping_solid.i)
[Mesh]
[sphere]
type = FileMeshGenerator
file = ../meshes/sphere.e
[]
[solid]
type = CombinerGenerator
inputs = sphere
positions = '0 0 0
0 0 4
0 0 8'
[]
[solid_ids]
type = SubdomainIDGenerator
input = solid
subdomain_id = '100'
[]
[fluid]
type = FileMeshGenerator
file = ../heat_source/stoplight.exo
[]
[fluid_ids]
type = SubdomainIDGenerator
input = fluid
subdomain_id = '200'
[]
[combine]
type = CombinerGenerator
inputs = 'solid_ids fluid_ids'
[]
[]
[Problem]
type = OpenMCCellAverageProblem
verbose = true
source_strength = 1e12
temperature_blocks = '100'
cell_level = 0
initial_properties = xml
[Tallies]
[Cell]
type = CellTally
block = '100'
# we are omitting the fluid regions from feedback (which have some fissile material),
# so we need to explicitly skip the tally check
check_tally_sum = false
[]
[]
[]
[Executioner]
type = Transient
num_steps = 1
[]
[Postprocessors]
[heat_source_solid]
type = ElementIntegralVariablePostprocessor
variable = kappa_fission
block = '100'
[]
[]
[Outputs]
csv = true
[]
(test/tests/openmc_errors/level/phase_too_high/fluid_too_high.i)
[Mesh]
[sphere]
# Mesh of a single pebble with outer radius of 1.5 (cm)
type = FileMeshGenerator
file = ../../../neutronics/meshes/sphere.e
[]
[solid]
type = CombinerGenerator
inputs = sphere
positions = '0 0 0
0 0 4
0 0 8'
[]
[solid_ids]
type = SubdomainIDGenerator
input = solid
subdomain_id = '100'
[]
[fluid]
type = FileMeshGenerator
file = ../../../neutronics/heat_source/stoplight.exo
[]
[fluid_ids]
type = SubdomainIDGenerator
input = fluid
subdomain_id = '200'
[]
[combine]
type = CombinerGenerator
inputs = 'solid_ids fluid_ids'
[]
[]
[Problem]
type = OpenMCCellAverageProblem
power = 70.0
temperature_blocks = '100 200'
density_blocks = '200'
verbose = true
# skip the data transfer of temperature into OpenMC for the first time step
# so that we can just use the ICs set in OpenMCs XML files
initial_properties = xml
# For this setup, the fluid cells only exist on coordinate level 0, even though
# the highest coordinate level across the entire problem is 1
cell_level = 1
[Tallies]
[Cell]
type = CellTally
block = '100 200'
[]
[]
[]
[Executioner]
type = Transient
num_steps = 1
[]
[Outputs]
exodus = true
[]
(test/tests/neutronics/feedback/density_per_cell/openmc.i)
[Mesh]
type = FileMesh
file = ../../meshes/pincell.e
[]
[ICs]
[temp]
type = FunctionIC
variable = temp
function = temp
[]
[density]
type = FunctionIC
variable = density
function = density
[]
[]
[Functions]
[temp]
type = ParsedFunction
expression = '500'
[]
[density]
type = ParsedFunction
expression = '800+z*10'
[]
[]
[AuxVariables]
[material_id]
family = MONOMIAL
order = CONSTANT
[]
[cell_density]
family = MONOMIAL
order = CONSTANT
[]
[]
[AuxKernels]
[material_id]
type = CellMaterialIDAux
variable = material_id
[]
[cell_density]
type = CellDensityAux
variable = cell_density
execute_on = 'timestep_end'
[]
[]
[Problem]
type = OpenMCCellAverageProblem
verbose = true
power = 500.0
temperature_blocks = '1 2 3'
density_blocks = '2'
cell_level = 0
[Tallies]
[Cell]
type = CellTally
block = '1'
[]
[]
[]
[Postprocessors]
[avg_density]
type = ElementAverageValue
variable = density
block = '2'
[]
[rho1]
type = PointValue
variable = cell_density
point = '0.5 0 1.5'
[]
[rho2]
type = PointValue
variable = cell_density
point = '0.5 0 8.5'
[]
[mat1]
type = PointValue
variable = material_id
point = '0.5 0 1.5'
[]
[mat2]
type = PointValue
variable = material_id
point = '0.5 0 8.5'
[]
[k]
type = KEigenvalue
value_type = collision
[]
[]
[Executioner]
type = Steady
[]
[Outputs]
csv = true
[]
(test/tests/neutronics/heat_source/from_postprocessor.i)
[Mesh]
[sphere]
type = FileMeshGenerator
file = ../meshes/sphere.e
[]
[solid]
type = CombinerGenerator
inputs = sphere
positions = '0 0 0
0 0 4
0 0 8'
[]
[solid_ids]
type = SubdomainIDGenerator
input = solid
subdomain_id = '100'
[]
[fluid]
type = FileMeshGenerator
file = stoplight.exo
[]
[fluid_ids]
type = SubdomainIDGenerator
input = fluid
subdomain_id = '200'
[]
[combine]
type = CombinerGenerator
inputs = 'solid_ids fluid_ids'
[]
[]
[Postprocessors]
[p]
type = Receiver
default = 100.0
[]
[]
[Problem]
type = OpenMCCellAverageProblem
power = p
temperature_blocks = '100 200'
density_blocks = '200'
verbose = true
cell_level = 0
initial_properties = xml
[Tallies]
[Cell]
type = CellTally
block = '100 200'
name = heat_source
[]
[]
[]
[Executioner]
type = Steady
[]
[Postprocessors]
[heat_source]
type = ElementIntegralVariablePostprocessor
variable = heat_source
[]
[fluid_heat_source]
type = ElementIntegralVariablePostprocessor
variable = heat_source
block = '200'
[]
[solid_heat_source]
type = ElementIntegralVariablePostprocessor
variable = heat_source
block = '100'
[]
[]
[Outputs]
execute_on = final
exodus = true
hide = 'density p'
[]
(test/tests/neutronics/tally_system/multi_estimator.i)
[Mesh]
[sphere]
type = FileMeshGenerator
file = ../meshes/sphere.e
[]
[solid]
type = CombinerGenerator
inputs = sphere
positions = '0 0 0
0 0 4
0 0 8'
[]
[solid_ids]
type = SubdomainIDGenerator
input = solid
subdomain_id = '100'
[]
[fluid]
type = FileMeshGenerator
file = ../heat_source/stoplight.exo
[]
[fluid_ids]
type = SubdomainIDGenerator
input = fluid
subdomain_id = '200'
[]
[combine]
type = CombinerGenerator
inputs = 'solid_ids fluid_ids'
[]
[]
[Problem]
type = OpenMCCellAverageProblem
verbose = true
power = 1e4
temperature_blocks = '100'
cell_level = 0
initial_properties = xml
source_rate_normalization = 'kappa_fission'
[Tallies]
[Cell_1]
type = CellTally
score = kappa_fission
block = '100 200'
estimator = tracklength
[]
[Cell_2]
type = CellTally
score = flux
block = '100 200'
estimator = collision
[]
[]
[]
[Postprocessors]
[Pebble_1_Heat]
type = PointValue
point = '0 0 0'
variable = kappa_fission
[]
[Pebble_2_Heat]
type = PointValue
point = '0 0 4'
variable = kappa_fission
[]
[Pebble_3_Heat]
type = PointValue
point = '0 0 8'
variable = kappa_fission
[]
[Pebble_1_Flux]
type = PointValue
point = '0 0 0'
variable = flux
[]
[Pebble_2_Flux]
type = PointValue
point = '0 0 4'
variable = flux
[]
[Pebble_3_Flux]
type = PointValue
point = '0 0 8'
variable = flux
[]
[]
[Executioner]
type = Steady
[]
[Outputs]
csv = true
[]
(test/tests/neutronics/symmetry/openmc.i)
num_layers = 1
channel_diameter = 0.016 # diameter of the coolant channels (m)
height = 6.343 # height of the full core (m)
[Mesh]
# mesh mirror for the solid regions
[solid]
type = FileMeshGenerator
file = solid_mesh_in.e
[]
# create a mesh for a single coolant channel; because we will receive uniform
# temperatures and densities on each x-y plane, we can use a very coarse
# mesh in the radial direction
[coolant_face]
type = AnnularMeshGenerator
nr = 1
nt = 8
rmin = 0.0
rmax = ${fparse channel_diameter / 2.0}
[]
[extrude]
type = AdvancedExtruderGenerator
input = coolant_face
num_layers = ${num_layers}
direction = '0 0 1'
heights = '${height}'
top_boundary = '300' # inlet
bottom_boundary = '400' # outlet
[]
[rename]
type = RenameBlockGenerator
input = extrude
old_block = '1'
new_block = '101'
[]
# repeat the coolant channels and then combine together to get a combined mesh mirror
[repeat]
type = CombinerGenerator
inputs = rename
positions_file = coolant_channel_positions.txt
[]
[add]
type = CombinerGenerator
inputs = 'solid repeat'
[]
[]
[Problem]
type = OpenMCCellAverageProblem
initial_properties = 'xml'
power = 1000.0
scaling = 100.0
temperature_blocks = '1 2 101'
density_blocks = '101'
cell_level = 1
symmetry_mapper = sym
[Tallies]
[Cell]
type = CellTally
block = '2'
[]
[]
[]
[UserObjects]
[sym]
type = SymmetryPointGenerator
normal = '${fparse -sqrt(3.0) / 2.0} 0.5 0.0'
[]
[]
[Postprocessors]
[heat_source]
type = ElementIntegralVariablePostprocessor
variable = kappa_fission
block = 2
[]
# check a few of the pins to be sure that the reflected heat source matches
[pin1_l]
type = PointValue
variable = kappa_fission
point = '0.0096 0.0489 4.0'
[]
[pin1_r]
type = PointValue
variable = kappa_fission
point = '0.0389 0.0326 4.0'
[]
[diff1]
type = DifferencePostprocessor
value1 = pin1_l
value2 = pin1_r
[]
[pin2_l]
type = PointValue
variable = kappa_fission
point = '-0.019 0.0329 4.0'
[]
[pin2_r]
type = PointValue
variable = kappa_fission
point = '0.0363 0.0 4.0'
[]
[diff2]
type = DifferencePostprocessor
value1 = pin2_l
value2 = pin2_r
[]
[pin3_l]
type = PointValue
variable = kappa_fission
point = '0.0463 0.115 4.0'
[]
[pin3_r]
type = PointValue
variable = kappa_fission
point = '0.0770 0.098 4.0'
[]
[diff3]
type = DifferencePostprocessor
value1 = pin3_l
value2 = pin3_r
[]
[]
[Executioner]
type = Transient
num_steps = 1
[]
[Outputs]
exodus = true
csv = true
hide = 'pin1_l pin1_r pin2_l pin2_r pin3_l pin3_r'
[]
(test/tests/neutronics/feedback/triso/different_fill_univs/openmc.i)
[Mesh]
[solid]
type = FileMeshGenerator
file = ../solid.e
[]
[]
[Problem]
type = OpenMCCellAverageProblem
verbose = true
# this input should error because the universes filling the tally cells
# dont match identically
identical_cell_fills = '2'
check_identical_cell_fills = true
power = 100.0
scaling = 100.0
temperature_blocks = '1 2'
cell_level = 1
[Tallies]
[Cell]
type = CellTally
block = '2'
check_equal_mapped_tally_volumes = true
[]
[]
[]
[Executioner]
type = Transient
[]
(test/tests/neutronics/tallies/reaction_rates/openmc.i)
[Mesh]
[sphere]
type = FileMeshGenerator
file = ../../meshes/sphere.e
[]
[solid]
type = CombinerGenerator
inputs = sphere
positions = '0 0 0
0 0 4
0 0 8'
[]
[solid_ids]
type = SubdomainIDGenerator
input = solid
subdomain_id = '100'
[]
[fluid]
type = FileMeshGenerator
file = ../../heat_source/stoplight.exo
[]
[fluid_ids]
type = SubdomainIDGenerator
input = fluid
subdomain_id = '200'
[]
[combine]
type = CombinerGenerator
inputs = 'solid_ids fluid_ids'
[]
[]
[Problem]
type = OpenMCCellAverageProblem
verbose = true
source_strength = 1e6
temperature_blocks = '100 200'
density_blocks = '200'
cell_level = 0
initial_properties = xml
[Tallies]
[Cell]
type = CellTally
score = 'absorption fission scatter total'
block = '100 200'
[]
[]
[]
[Executioner]
type = Steady
[]
[Postprocessors]
[total_abs]
type = ElementIntegralVariablePostprocessor
variable = absorption
[]
[fluid_abs]
type = PointValue
variable = absorption
point = '0.0 0.0 2.0'
[]
[pebble1_abs]
type = PointValue
variable = absorption
point = '0.0 0.0 0.0'
[]
[pebble2_abs]
type = PointValue
variable = absorption
point = '0.0 0.0 4.0'
[]
[pebble3_abs]
type = PointValue
variable = absorption
point = '0.0 0.0 8.0'
[]
[max_err_abs]
type = TallyRelativeError
tally_score = 'absorption'
[]
[total_fis]
type = ElementIntegralVariablePostprocessor
variable = fission
[]
[fluid_fis]
type = PointValue
variable = fission
point = '0.0 0.0 2.0'
[]
[pebble1_fis]
type = PointValue
variable = fission
point = '0.0 0.0 0.0'
[]
[pebble2_fis]
type = PointValue
variable = fission
point = '0.0 0.0 4.0'
[]
[pebble3_fis]
type = PointValue
variable = fission
point = '0.0 0.0 8.0'
[]
[max_err_fis]
type = TallyRelativeError
tally_score = 'fission'
[]
[total_sca]
type = ElementIntegralVariablePostprocessor
variable = scatter
[]
[fluid_sca]
type = PointValue
variable = scatter
point = '0.0 0.0 2.0'
[]
[pebble1_sca]
type = PointValue
variable = scatter
point = '0.0 0.0 0.0'
[]
[pebble2_sca]
type = PointValue
variable = scatter
point = '0.0 0.0 4.0'
[]
[pebble3_sca]
type = PointValue
variable = scatter
point = '0.0 0.0 8.0'
[]
[max_err_sca]
type = TallyRelativeError
tally_score = 'scatter'
[]
[total_tot]
type = ElementIntegralVariablePostprocessor
variable = total
[]
[fluid_tot]
type = PointValue
variable = total
point = '0.0 0.0 2.0'
[]
[pebble1_tot]
type = PointValue
variable = total
point = '0.0 0.0 0.0'
[]
[pebble2_tot]
type = PointValue
variable = total
point = '0.0 0.0 4.0'
[]
[pebble3_tot]
type = PointValue
variable = total
point = '0.0 0.0 8.0'
[]
[max_err_tot]
type = TallyRelativeError
tally_score = 'total'
[]
[]
[Outputs]
execute_on = final
csv = true
[]
(test/tests/neutronics/triggers/tally_rel_err.i)
[Mesh]
[sphere]
type = FileMeshGenerator
file = ../meshes/sphere.e
[]
[solid]
type = CombinerGenerator
inputs = sphere
positions = '0 0 0
0 0 4
0 0 8'
[]
[solid_ids]
type = SubdomainIDGenerator
input = solid
subdomain_id = '100'
[]
[]
[Problem]
type = OpenMCCellAverageProblem
power = 100.0
cell_level = 0
max_batches = 200
[Tallies]
[Cell]
type = CellTally
block = '100'
trigger = rel_err
trigger_threshold = 2e-2
normalize_by_global_tally = false
[]
[]
[]
[Executioner]
type = Transient
num_steps = 1
[]
[Postprocessors]
[max_tally_err]
type = TallyRelativeError
[]
[]
[Outputs]
csv = true
[]
(test/tests/neutronics/relaxation/cell_tallies/openmc_adapt.i)
[Mesh]
[pebble]
type = FileMeshGenerator
file = ../../meshes/sphere_in_m.e
[]
[repeat]
type = CombinerGenerator
inputs = pebble
positions = '0 0 0.02
0 0 0.06
0 0 0.10'
[]
[set_block_ids]
type = SubdomainIDGenerator
input = repeat
subdomain_id = 0
[]
[]
[AuxKernels]
[temp]
type = FunctionAux
variable = temp
function = axial
execute_on = initial
[]
[]
[Functions]
[axial]
type = ParsedFunction
expression = '500 + z / 0.10 * 100'
[]
[]
[Adaptivity]
[Markers/uniform]
type = UniformMarker
mark = refine
[]
[]
[Problem]
type = OpenMCCellAverageProblem
verbose = true
power = 100.0
temperature_blocks = '0'
cell_level = 1
scaling = 100.0
relaxation = robbins_monro
[Tallies]
[Cell]
type = CellTally
block = '0'
[]
[]
[]
[Executioner]
type = Transient
num_steps = 3
[]
[Outputs]
csv = true
[]
(test/tests/neutronics/dagmc/cell_tallies/null_density.i)
[Mesh]
type = FileMesh
file = ../mesh_tallies/slab.e
allow_renumbering = false
[]
x0 = 12.5
x1 = 37.5
x2 = 62.5
[AuxVariables]
[cell_temperature]
family = MONOMIAL
order = CONSTANT
[]
[]
[AuxKernels]
[cell_temperature]
type = CellTemperatureAux
variable = cell_temperature
[]
[]
T0 = 600.0
dT = 50.0
[Functions]
[temp]
type = ParsedFunction
expression = 'if (x <= ${x0}, ${fparse T0 - dT}, if (x <= ${x1}, ${T0}, if (x <= ${x2}, ${fparse T0 + dT}, ${fparse T0 + 2 * dT})))'
[]
[]
[AuxKernels]
[temp]
type = FunctionAux
variable = temp
function = temp
execute_on = timestep_begin
[]
[]
[ICs]
[density]
type = ConstantIC
variable = density
value = 11000.0
[]
[]
[Problem]
type = OpenMCCellAverageProblem
verbose = true
temperature_blocks = '1 2'
density_blocks = '1 2'
cell_level = 0
power = 100.0
skinner = moab
[Tallies]
[Cell]
type = CellTally
block = '1 2'
[]
[]
[]
[UserObjects]
[moab]
type = MoabSkinner
temperature_min = ${fparse T0 - dT}
temperature_max = ${fparse T0 + 2 * dT}
n_temperature_bins = 4
temperature = temp
build_graveyard = true
# Effectively no density skinning at all, because theres just one bin.
# Results should be the same as if there was no density skinning enabled.
density_min = 0.0
density_max = 15000.0
n_density_bins = 1
density = density
[]
[]
[Postprocessors]
[k]
type = KEigenvalue
[]
[]
[Executioner]
type = Transient
num_steps = 2
[]
[Outputs]
exodus = true
hide = 'density cell_instance'
[]
(test/tests/neutronics/filters/sh/openmc_l0_from_l1.i)
[Mesh]
[sphere]
type = FileMeshGenerator
file = ../../meshes/sphere.e
[]
[solid]
type = CombinerGenerator
inputs = sphere
positions = '0 0 0
0 0 4
0 0 8'
[]
[solid_ids]
type = SubdomainIDGenerator
input = solid
subdomain_id = '100'
[]
[fluid]
type = FileMeshGenerator
file = ../../heat_source/stoplight.exo
[]
[fluid_ids]
type = SubdomainIDGenerator
input = fluid
subdomain_id = '200'
[]
[combine]
type = CombinerGenerator
inputs = 'solid_ids fluid_ids'
[]
allow_renumbering = false
[]
[Problem]
type = OpenMCCellAverageProblem
verbose = true
power = 1e4
temperature_blocks = '100'
cell_level = 0
initial_properties = xml
source_rate_normalization = 'kappa_fission'
[Tallies]
[Heating]
type = CellTally
score = 'kappa_fission'
block = '100 200'
[]
[Flux]
type = CellTally
score = 'flux'
block = '100 200'
filters = 'Energy SH'
[]
[]
[Filters]
[Energy]
type = EnergyFilter
# CASMO 2 group structure for testing. May result in some missed particles
energy_boundaries = '0.0 6.25e-1 2.0e7'
[]
[SH]
type = SphericalHarmonicsFilter
order = 1
[]
[]
[]
[Postprocessors]
[Pebble_1_Flux_g1_l0_m0]
type = PointValue
point = '0 0 0'
variable = flux_g1_l0_mpos0
[]
[Pebble_1_Flux_g2_l0_m0]
type = PointValue
point = '0 0 0'
variable = flux_g2_l0_mpos0
[]
[]
[Executioner]
type = Steady
[]
[Outputs]
csv = true
[]
(test/tests/neutronics/filters/polar/mesh.i)
[Mesh]
[sphere]
type = FileMeshGenerator
file = ../../meshes/sphere.e
[]
[solid]
type = CombinerGenerator
inputs = sphere
positions = '0 0 0
0 0 4
0 0 8'
[]
[solid_ids]
type = SubdomainIDGenerator
input = solid
subdomain_id = '100'
[]
allow_renumbering = false
[]
[Problem]
type = OpenMCCellAverageProblem
verbose = true
power = 1e4
temperature_blocks = '100'
cell_level = 0
initial_properties = xml
source_rate_normalization = 'kappa_fission'
[Tallies]
[Heating]
type = CellTally
score = 'kappa_fission'
block = '100'
# Disable global normalization since we have a loosely fitting mesh tally.
normalize_by_global_tally = false
[]
[Flux]
type = MeshTally
score = 'flux'
mesh_template = ../../meshes/sphere.e
mesh_translations = '0 0 0
0 0 4
0 0 8'
filters = 'Polar'
# Disable global normalization since we have a loosely fitting mesh tally.
normalize_by_global_tally = false
[]
[]
[Filters]
[Polar]
type = PolarAngleFilter
num_equal_divisions = 2
[]
[]
[]
[Postprocessors]
[Total_Flux_Theta1]
type = ElementIntegralVariablePostprocessor
variable = flux_theta1
[]
[Total_Flux_Theta2]
type = ElementIntegralVariablePostprocessor
variable = flux_theta2
[]
[]
[Executioner]
type = Steady
[]
[Outputs]
csv = true
[]
(test/tests/neutronics/feedback/single_level/openmc.i)
[Mesh]
type = FileMesh
file = ../../meshes/pincell.e
[]
[AuxVariables]
[cell_temperature]
family = MONOMIAL
order = CONSTANT
[]
[material_id]
family = MONOMIAL
order = CONSTANT
[]
[cell_density]
family = MONOMIAL
order = CONSTANT
[]
[]
[AuxKernels]
[material_id]
type = CellMaterialIDAux
variable = material_id
[]
[cell_temperature]
type = CellTemperatureAux
variable = cell_temperature
execute_on = 'timestep_end'
[]
[cell_density]
type = CellDensityAux
variable = cell_density
execute_on = 'timestep_end'
[]
[]
[Problem]
type = OpenMCCellAverageProblem
power = 500.0
temperature_blocks = '1 2 3'
density_blocks = '2'
verbose = true
cell_level = 0
[Tallies]
[Cell]
type = CellTally
block = '1 2 3'
[]
[]
[]
[Executioner]
type = Transient
[]
[Postprocessors]
[kappa_fission]
type = ElementIntegralVariablePostprocessor
variable = kappa_fission
[]
[fluid_kappa_fission]
type = ElementIntegralVariablePostprocessor
variable = kappa_fission
block = '2'
[]
[solid_kappa_fission]
type = ElementIntegralVariablePostprocessor
variable = kappa_fission
block = '1 3'
[]
[]
[Outputs]
exodus = true
[]
(test/tests/neutronics/heat_source/partial_mapping_moose_union.i)
# In this input, MOOSEs domain contains the entire OpenMC domain, but some
# MOOSE elements arent mapped anywhere (this is facilitated by adding an
# extra pebble to the MOOSE mesh).
[Mesh]
[sphere]
type = FileMeshGenerator
file = ../meshes/sphere.e
[]
[solid]
type = CombinerGenerator
inputs = sphere
positions = '0 0 0
0 0 4
0 0 8
9 9 9'
[]
[solid_ids]
type = SubdomainIDGenerator
input = solid
subdomain_id = '100'
[]
[fluid]
type = FileMeshGenerator
file = stoplight.exo
[]
[fluid_ids]
type = SubdomainIDGenerator
input = fluid
subdomain_id = '200'
[]
[combine]
type = CombinerGenerator
inputs = 'solid_ids fluid_ids'
[]
[]
[Problem]
type = OpenMCCellAverageProblem
power = 100.0
temperature_blocks = '100 200'
density_blocks = '200'
initial_properties = xml
verbose = true
cell_level = 0
[Tallies]
[Cell]
type = CellTally
name = heat_source
block = '100 200'
[]
[]
[]
[Executioner]
type = Steady
[]
[Postprocessors]
[heat_source]
type = ElementIntegralVariablePostprocessor
variable = heat_source
block = '100 200'
[]
[fluid_heat_source]
type = ElementIntegralVariablePostprocessor
variable = heat_source
block = '200'
[]
[solid_heat_source]
type = ElementIntegralVariablePostprocessor
variable = heat_source
block = '100'
[]
[]
[Outputs]
csv = true
exodus = true
hide = 'density'
[]
(test/tests/neutronics/fixed_source/mapping_all.i)
[Mesh]
[sphere]
type = FileMeshGenerator
file = ../meshes/sphere.e
[]
[solid]
type = CombinerGenerator
inputs = sphere
positions = '0 0 0
0 0 4
0 0 8'
[]
[solid_ids]
type = SubdomainIDGenerator
input = solid
subdomain_id = '100'
[]
[fluid]
type = FileMeshGenerator
file = ../heat_source/stoplight.exo
[]
[fluid_ids]
type = SubdomainIDGenerator
input = fluid
subdomain_id = '200'
[]
[combine]
type = CombinerGenerator
inputs = 'solid_ids fluid_ids'
[]
[]
[Problem]
type = OpenMCCellAverageProblem
verbose = true
source_strength = 1e12
temperature_blocks = '100 200'
density_blocks = '200'
cell_level = 0
initial_properties = xml
[Tallies]
[Cell]
type = CellTally
block = '100 200'
[]
[]
[]
[Executioner]
type = Transient
num_steps = 1
[]
[Postprocessors]
[heat_source]
type = ElementIntegralVariablePostprocessor
variable = kappa_fission
[]
[heat_source_fluid]
type = ElementIntegralVariablePostprocessor
variable = kappa_fission
block = '200'
[]
[heat_source_solid]
type = ElementIntegralVariablePostprocessor
variable = kappa_fission
block = '100'
[]
[]
[Outputs]
csv = true
[]
(test/tests/neutronics/gen_mgxs/mgxs_aux/generic_mgxs.i)
[Mesh]
[sphere]
type = FileMeshGenerator
file = ../../meshes/sphere.e
[]
[solid1]
type = SubdomainIDGenerator
input = sphere
subdomain_id = '100'
[]
allow_renumbering = false
[]
[AuxVariables]
[total_xs_g1]
type = MooseVariable
order = CONSTANT
family = MONOMIAL
[]
[zero_flux]
type = MooseVariable
order = CONSTANT
family = MONOMIAL
initial_condition = '0.0'
[]
[]
[AuxKernels]
[comp_total_g1]
type = ComputeMGXSAux
variable = total_xs_g1
rxn_rates = 'total_g1'
normalize_by = 'flux_g1'
[]
[]
[Problem]
type = OpenMCCellAverageProblem
initial_properties = xml
verbose = true
cell_level = 0
power = 1.0
source_rate_normalization = 'kappa_fission'
[Tallies]
[Cell_KF]
type = CellTally
score = 'kappa_fission'
block = '100'
normalize_by_global_tally = false
[]
[Cell_Total_Flux]
type = CellTally
score = 'total flux'
block = '100'
filters = 'Energy'
normalize_by_global_tally = false
[]
[]
[Filters]
[Energy]
type = EnergyFilter
energy_boundaries = '0.0 6.25e-1 2.0e7'
reverse_bins = true
[]
[]
[]
[Executioner]
type = Steady
[]
[Postprocessors]
[result]
type = PointValue
point = '0 0 0'
variable = total_xs_g1
[]
[]
[Outputs]
execute_on = final
csv = true
[]
(test/tests/neutronics/gen_mgxs/photon_xs/mgxs_photon.i)
[Mesh]
[sphere]
type = FileMeshGenerator
file = ../../meshes/sphere.e
[]
[solid1]
type = SubdomainIDGenerator
input = sphere
subdomain_id = '100'
[]
allow_renumbering = false
[]
[Problem]
type = OpenMCCellAverageProblem
initial_properties = xml
verbose = true
cell_level = 0
power = 1.0
source_rate_normalization = 'kappa_fission'
[Tallies/Cell]
type = CellTally
block = '100'
# 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]
tally_type = cell
particle = photon
group_structure = CASMO_2
estimator = 'tracklength'
normalize_by_global_tally = false
hide_tally_vars = true
add_scattering = false
legendre_order = 0
transport_correction = true
add_fission = false
add_fission_heating = false
add_inverse_velocity = false
add_diffusion_coefficient = false
add_absorption = false
[]
[]
[Executioner]
type = Steady
[]
[Postprocessors]
[total_xs_g1]
type = PointValue
point = '0 0 0'
variable = total_xs_g1
[]
[total_xs_g2]
type = PointValue
point = '0 0 0'
variable = total_xs_g2
[]
[]
[Outputs]
execute_on = final
csv = true
[]
(test/tests/neutronics/photon/openmc.i)
[Mesh]
type = FileMesh
file = ../meshes/pincell.e
[]
[Problem]
type = OpenMCCellAverageProblem
power = 500.0
cell_level = 1
[Tallies]
[Cell]
type = CellTally
block = '1'
score = 'heating'
estimator = tracklength
[]
[]
[]
[Executioner]
type = Transient
[]
(test/tests/neutronics/relaxation/cell_tallies/openmc_nonaligned.i)
[Mesh]
[pebble]
type = FileMeshGenerator
file = ../../meshes/sphere_in_m.e
[]
[repeat]
type = CombinerGenerator
inputs = pebble
positions = '0 0 0.02
0 0 0.10'
[]
[set_block_ids]
type = SubdomainIDGenerator
input = repeat
subdomain_id = 0
[]
[]
[AuxKernels]
[temp]
type = FunctionAux
variable = temp
function = axial
execute_on = initial
[]
[]
[Functions]
[axial]
type = ParsedFunction
expression = '500 + z / 0.10 * 100'
[]
[]
[Problem]
type = OpenMCCellAverageProblem
verbose = true
power = 1500.0
temperature_blocks = '0'
cell_level = 1
scaling = 100.0
[Tallies]
[Cell]
type = CellTally
block = '0'
# our problem is missing overlap for fissile regions, so our local and global tallies
# wont match
check_tally_sum = false
[]
[]
[]
[Executioner]
type = Transient
num_steps = 3
[]
[Outputs]
csv = true
exodus = true
[]
[Postprocessors]
[p1]
type = PointValue
variable = kappa_fission
point = '0.0 0.0 0.02'
[]
[p2]
type = PointValue
variable = kappa_fission
point = '0.0 0.0 0.10'
[]
[heat_source]
type = ElementIntegralVariablePostprocessor
variable = kappa_fission
[]
[]
(test/tests/neutronics/filters/energy/mesh.i)
[Mesh]
[sphere]
type = FileMeshGenerator
file = ../../meshes/sphere.e
[]
[solid]
type = CombinerGenerator
inputs = sphere
positions = '0 0 0
0 0 4
0 0 8'
[]
[solid_ids]
type = SubdomainIDGenerator
input = solid
subdomain_id = '100'
[]
allow_renumbering = false
[]
[Problem]
type = OpenMCCellAverageProblem
verbose = true
power = 1e4
temperature_blocks = '100'
cell_level = 0
initial_properties = xml
source_rate_normalization = 'kappa_fission'
[Tallies]
[Heating]
type = CellTally
score = 'kappa_fission'
block = '100'
# Disable global normalization since we have a loosely fitting mesh tally.
normalize_by_global_tally = false
[]
[Flux]
type = MeshTally
score = 'flux'
mesh_template = ../../meshes/sphere.e
mesh_translations = '0 0 0
0 0 4
0 0 8'
filters = 'Energy'
# Disable global normalization since we have a loosely fitting mesh tally.
normalize_by_global_tally = false
[]
[]
[Filters]
[Energy]
type = EnergyFilter
# CASMO 2 group structure for testing. May result in some missed particles
energy_boundaries = '0.0 6.25e-1 2.0e7'
[]
[]
[]
[Postprocessors]
[Total_Flux_1]
type = ElementIntegralVariablePostprocessor
variable = flux_g1
[]
[Total_Flux_2]
type = ElementIntegralVariablePostprocessor
variable = flux_g2
[]
[]
[Executioner]
type = Steady
[]
[Outputs]
csv = true
[]
(test/tests/userobjects/openmc_nuclide_densities/thermal_density.i)
[Mesh]
[g]
type = GeneratedMeshGenerator
dim = 3
nx = 8
ny = 8
nz = 8
xmin = -12.5
xmax = 87.5
ymin = -12.5
ymax = 37.5
zmin = -12.5
zmax = 12.5
[]
[]
[ICs]
[temp]
type = ConstantIC
variable = temp
value = 500.0
[]
[density]
type = ConstantIC
variable = density
value = 500.0
[]
[]
[Problem]
type = OpenMCCellAverageProblem
verbose = true
temperature_blocks = '0'
density_blocks = '0'
cell_level = 0
power = 100.0
[Tallies]
[Cell]
type = CellTally
block = '0'
[]
[]
[]
[UserObjects]
[mat1]
type = OpenMCNuclideDensities
material_id = 1
names = 'U235 U238'
densities = '0.01 0.02'
[]
[]
[Postprocessors]
[k]
type = KEigenvalue
[]
[]
[Executioner]
type = Steady
[]
[Outputs]
csv = true
[]
(test/tests/neutronics/filters/xml/mesh.i)
[Mesh]
[sphere]
type = FileMeshGenerator
file = ../../meshes/sphere.e
[]
[solid]
type = CombinerGenerator
inputs = sphere
positions = '0 0 0
0 0 4
0 0 8'
[]
[solid_ids]
type = SubdomainIDGenerator
input = solid
subdomain_id = '100'
[]
allow_renumbering = false
[]
[Problem]
type = OpenMCCellAverageProblem
verbose = true
power = 1e4
temperature_blocks = '100'
cell_level = 0
initial_properties = xml
source_rate_normalization = 'kappa_fission'
[Tallies]
[Heating]
type = CellTally
score = 'kappa_fission'
block = '100'
check_tally_sum = false
normalize_by_global_tally = true
[]
[Flux]
type = MeshTally
score = 'flux'
mesh_template = ../../meshes/sphere.e
mesh_translations = '0 0 0
0 0 4
0 0 8'
filters = 'SPH_XML'
check_tally_sum = false
normalize_by_global_tally = true
[]
[]
[Filters]
[SPH_XML]
type = FromXMLFilter
filter_id = 1
bin_label = 'sph'
allow_expansion_filters = true
[]
[]
[]
[Postprocessors]
[Total_Flux_l0_m0]
type = ElementIntegralVariablePostprocessor
variable = flux_sph1
[]
[Total_Flux_l1_mn1]
type = ElementIntegralVariablePostprocessor
variable = flux_sph2
[]
[Total_Flux_l1_m0]
type = ElementIntegralVariablePostprocessor
variable = flux_sph3
[]
[Total_Flux_l1_m1]
type = ElementIntegralVariablePostprocessor
variable = flux_sph4
[]
[]
[Executioner]
type = Steady
[]
[Outputs]
csv = true
[]
(test/tests/neutronics/triggers/ignore_zeros/ignore_zero.i)
[Mesh]
[sphere]
type = FileMeshGenerator
file = ../../meshes/sphere.e
[]
[solid]
type = CombinerGenerator
inputs = sphere
positions = '0 0 0
0 0 4
0 0 8'
[]
[solid_ids]
type = SubdomainIDGenerator
input = solid
subdomain_id = '100'
[]
[fluid]
type = FileMeshGenerator
file = ../../heat_source/stoplight.exo
[]
[fluid_ids]
type = SubdomainIDGenerator
input = fluid
subdomain_id = '200'
[]
[combine]
type = CombinerGenerator
inputs = 'solid_ids fluid_ids'
[]
[]
[Problem]
type = OpenMCCellAverageProblem
source_strength = 1e6
verbose = true
temperature_blocks = '100 200'
density_blocks = '200'
cell_level = 0
initial_properties = xml
max_batches = 200
[Tallies]
[Cell]
type = CellTally
score = 'H3_production'
block = '100 200'
trigger = 'rel_err'
# If tally bins with zeros are ignored, this will fire immediately since
# the fluid region doesn't have a tritium production score.
trigger_threshold = '1.0'
trigger_ignore_zeros = 'true'
[]
[]
[]
[Executioner]
type = Steady
[]
[Postprocessors]
[max_err]
type = TallyRelativeError
tally_score = 'H3_production'
[]
[]
[Outputs]
execute_on = final
csv = true
[]
(test/tests/neutronics/relaxation/cell_tallies/multi_tally.i)
[Mesh]
[pebble]
type = FileMeshGenerator
file = ../../meshes/sphere_in_m.e
[]
[repeat]
type = CombinerGenerator
inputs = pebble
positions = '0 0 0.02
0 0 0.10'
[]
[set_block_ids]
type = SubdomainIDGenerator
input = repeat
subdomain_id = 0
[]
[]
[AuxKernels]
[temp]
type = FunctionAux
variable = temp
function = axial
execute_on = initial
[]
[]
[Functions]
[axial]
type = ParsedFunction
expression = '500 + z / 0.10 * 100'
[]
[]
[Problem]
type = OpenMCCellAverageProblem
verbose = true
power = 1500.0
temperature_blocks = '0'
cell_level = 1
scaling = 100.0
[Tallies]
[Cell]
type = CellTally
score = 'kappa_fission heating'
name = 'heat_source heating'
block = '0'
# our problem is missing overlap for fissile regions, so our local and global tallies
# wont match
check_tally_sum = false
[]
[]
[]
[Executioner]
type = Transient
num_steps = 3
[]
[Outputs]
csv = true
[]
[Postprocessors]
[kf]
type = ElementIntegralVariablePostprocessor
variable = heat_source
[]
[peb1_kf]
type = PointValue
variable = heat_source
point = '0 0 0.02'
[]
[peb2_kf]
type = PointValue
variable = heat_source
point = '0 0 0.10'
[]
[heating]
type = ElementIntegralVariablePostprocessor
variable = heating
[]
[peb1_ht]
type = PointValue
variable = heating
point = '0 0 0.02'
[]
[peb2_ht]
type = PointValue
variable = heating
point = '0 0 0.10'
[]
[]
(test/tests/neutronics/solid/openmc_zero.i)
# This is a vertical stack of three pebbles, with a 1 meter thick layer of flibe
# on the outer periphery and on the top and bottom, to get a k closer to 1.0.
#
# This input just checks that setting a power of zero in the OpenMC model does not
# give any different results from a MOOSE-standalone case with zero power.
[Mesh]
[sphere]
# Mesh of a single pebble with outer radius of 1.5 (cm)
type = FileMeshGenerator
file = ../meshes/sphere.e
[]
[multiple]
type = CombinerGenerator
inputs = sphere
positions = '0 0 0
0 0 4
0 0 8'
[]
[]
[Problem]
type = OpenMCCellAverageProblem
power = 0.0
cell_level = 0
temperature_blocks = '1'
[Tallies]
[Cell]
type = CellTally
block = '1'
name = heat_source
[]
[]
[]
[Executioner]
type = Transient
[]
[Outputs]
exodus = true
[]
(test/tests/neutronics/dagmc/wrong_uo.i)
[Mesh]
[file]
type = FileMeshGenerator
file = ../meshes/tet_cube.e
[]
parallel_type = replicated
[]
[Problem]
type = OpenMCCellAverageProblem
cell_level = 0
temperature_blocks = '1'
power = 1000.0
skinner = moab
[Tallies]
[Mesh]
type = CellTally
block = '1'
[]
[]
[]
[UserObjects]
[moab]
type = NearestNodeNumberUO
point = '0.0 0.0 0.0'
[]
[]
[Executioner]
type = Steady
[]
(test/tests/neutronics/tallies/tritium/openmc.i)
[Mesh]
[sphere]
type = FileMeshGenerator
file = ../../meshes/sphere.e
[]
[solid]
type = CombinerGenerator
inputs = sphere
positions = '0 0 0
0 0 4
0 0 8'
[]
[solid_ids]
type = SubdomainIDGenerator
input = solid
subdomain_id = '100'
[]
[fluid]
type = FileMeshGenerator
file = ../../heat_source/stoplight.exo
[]
[fluid_ids]
type = SubdomainIDGenerator
input = fluid
subdomain_id = '200'
[]
[combine]
type = CombinerGenerator
inputs = 'solid_ids fluid_ids'
[]
[]
[Problem]
type = OpenMCCellAverageProblem
source_strength = 1e6
verbose = true
temperature_blocks = '100 200'
density_blocks = '200'
cell_level = 0
initial_properties = xml
[Tallies]
[Cell]
type = CellTally
score = 'H3_production'
block = '100 200'
[]
[]
[]
[Executioner]
type = Steady
[]
[Postprocessors]
[total_H3]
type = ElementIntegralVariablePostprocessor
variable = H3_production
[]
[fluid_H3]
type = PointValue
variable = H3_production
point = '0.0 0.0 2.0'
[]
[pebble1_H3]
type = PointValue
variable = H3_production
point = '0.0 0.0 0.0'
[]
[pebble2_H3]
type = PointValue
variable = H3_production
point = '0.0 0.0 4.0'
[]
[pebble3_H3]
type = PointValue
variable = H3_production
point = '0.0 0.0 8.0'
[]
[vol_fluid]
type = VolumePostprocessor
block = '200'
[]
[vol_solid]
type = VolumePostprocessor
block = '100'
[]
[max_err]
type = TallyRelativeError
tally_score = 'H3_production'
[]
[]
[Outputs]
execute_on = final
csv = true
exodus = true
[]
(test/tests/postprocessors/fission_tally_relative_error/ratio.i)
[Mesh]
[sphere]
type = FileMeshGenerator
file = ../../neutronics/meshes/sphere.e
[]
[solid]
type = CombinerGenerator
inputs = sphere
positions = '0 0 0
0 0 4
0 0 8'
[]
[]
[Problem]
type = OpenMCCellAverageProblem
power = 100.0
cell_level = 0
initial_properties = xml
[Tallies]
[Cell]
type = CellTally
block = '1'
score = 'heating kappa_fission'
output = 'unrelaxed_tally_std_dev'
check_tally_sum = false
[]
[]
[]
# the ratio of the std_dev variable and the output tally should give
# the relative error in the tallies.out
[AuxVariables]
[heating_rel_err]
family = MONOMIAL
order = CONSTANT
[]
[kappa_fission_rel_err]
family = MONOMIAL
order = CONSTANT
[]
[]
[AuxKernels]
[heating]
type = ParsedAux
variable = heating_rel_err
expression = 'heating_std_dev / heating'
coupled_variables = 'heating_std_dev heating'
[]
[kappa_fission]
type = ParsedAux
variable = kappa_fission_rel_err
expression = 'kappa_fission_std_dev / kappa_fission'
coupled_variables = 'kappa_fission_std_dev kappa_fission'
[]
[]
[Executioner]
type = Transient
num_steps = 1
[]
[Postprocessors]
[heating_max]
type = ElementExtremeValue
value_type = max
variable = heating_rel_err
[]
[heating_min]
type = ElementExtremeValue
value_type = min
variable = heating_rel_err
[]
[kf_max]
type = ElementExtremeValue
value_type = max
variable = kappa_fission_rel_err
[]
[kf_min]
type = ElementExtremeValue
value_type = min
variable = kappa_fission_rel_err
[]
[max_ht]
type = TallyRelativeError
value_type = max
tally_score = 'heating'
[]
[min_ht]
type = TallyRelativeError
value_type = min
tally_score = 'heating'
[]
[avg_ht]
type = TallyRelativeError
value_type = average
tally_score = 'heating'
[]
[max_kf]
type = TallyRelativeError
value_type = max
tally_score = 'kappa_fission'
[]
[min_kf]
type = TallyRelativeError
value_type = min
tally_score = 'kappa_fission'
[]
[avg_kf]
type = TallyRelativeError
value_type = average
tally_score = 'kappa_fission'
[]
[]
[Outputs]
csv = true
[]
(test/tests/neutronics/heat_source/block_restrict_err.i)
[Mesh]
[sphere]
type = FileMeshGenerator
file = ../meshes/sphere.e
[]
[solid]
type = CombinerGenerator
inputs = sphere
positions = '0 0 0'
[]
[solid_ids]
type = SubdomainIDGenerator
input = solid
subdomain_id = '100'
[]
[fluid]
type = FileMeshGenerator
file = stoplight.exo
[]
[fluid_ids]
type = SubdomainIDGenerator
input = fluid
subdomain_id = '200'
[]
[combine]
type = CombinerGenerator
inputs = 'solid_ids fluid_ids'
[]
[]
[Problem]
type = OpenMCCellAverageProblem
power = 100.0
initial_properties = xml
verbose = true
cell_level = 0
[Tallies]
[Cell]
type = CellTally
name = heat_source
# This input has fissile material in the fluid phase, so we will get a warning
# that we are neglecting some of the global kappa-fission distribution; so here
# the power is the total power of the OpenMC problem, and only a fraction of this
# will be computed in the solid pebbles
block = '100'
# We are skipping some feedback with fissile regions, so we need to turn off the check
check_tally_sum = false
[]
[]
[]
[Executioner]
type = Steady
[]
[Postprocessors]
[solid_heat_source]
type = ElementIntegralVariablePostprocessor
variable = heat_source
block = '200'
[]
[]
(test/tests/openmc_errors/block_mappings/skipping_moose_feedback.i)
# This input tests what happens if the OpenMC domain is fully enclosed in
# the MOOSE domain such that all OpenMC cells are coupled, but some MOOSE
# cells do not map anywhere in OpenMC. We should print a warning.
[Mesh]
[sphere]
# Mesh of a single pebble with outer radius of 1.5 (cm)
type = FileMeshGenerator
file = ../../neutronics/meshes/sphere.e
[]
[solid]
# Combine together to form four pebbles; this mesh would be the same as
# whatever is used to solve for the solid phase. One of these pebbles
# will be far outside the OpenMC domain, and will be unmapped
type = CombinerGenerator
inputs = sphere
positions = '0 0 0
0 0 4
0 0 8
9 9 9'
[]
[solid_ids]
type = SubdomainIDGenerator
input = solid
subdomain_id = '100'
[]
[fluid]
# Mesh of the fluid phase; this mesh would be the same as whatever is used to
# solve for the fluid phase
type = FileMeshGenerator
file = stoplight.exo
[]
[fluid_ids]
type = SubdomainIDGenerator
input = fluid
subdomain_id = '200'
[]
[combine]
type = CombinerGenerator
inputs = 'solid_ids fluid_ids'
[]
[]
[Problem]
type = OpenMCCellAverageProblem
power = 70.0
temperature_blocks = '100 200'
density_blocks = '200'
cell_level = 0
initial_properties = xml
[Tallies]
[Cell]
type = CellTally
block = '100'
[]
[]
[]
[Executioner]
type = Transient
num_steps = 1
[]
[Outputs]
exodus = true
[]
(test/tests/neutronics/feedback/multi_component_temp/openmc_incorrect_length.i)
[Mesh]
type = FileMesh
file = ../../meshes/pincell.e
[]
[ICs]
[solid_temp]
type = ConstantIC
variable = solid_temp
value = 800
blocks = '1 3'
[]
[fluid_temp]
type = ConstantIC
variable = fluid_temp
value = 600
blocks = '2'
[]
[]
[Problem]
type = OpenMCCellAverageProblem
power = 500.0
cell_level = 1
temperature_variables = 'solid_temp; fluid_temp'
temperature_blocks = '1'
[Tallies]
[Cell]
type = CellTally
block = '1'
[]
[]
[]
[Executioner]
type = Transient
[]
(test/tests/openmc_errors/densities/void_density.i)
[Mesh]
[m]
type = GeneratedMeshGenerator
dim = 3
xmin = -2
xmax = 2
ymin = -2
ymax = 2
zmin = -2
zmax = 10
nx = 5
ny = 5
nz = 5
[]
[id]
type = SubdomainIDGenerator
input = m
subdomain_id = 1
[]
[]
[ICs]
[t]
type = ConstantIC
variable = temp
value = 500.0
[]
[rho]
type = ConstantIC
variable = density
value = 1000.0
[]
[]
[Problem]
type = OpenMCCellAverageProblem
power = 10.0
temperature_blocks = '1'
density_blocks = '1'
verbose = true
cell_level = 0
[Tallies]
[Cell]
type = CellTally
block = '1'
[]
[]
[]
[Executioner]
type = Transient
[]
[Outputs]
exodus = true
[]
(test/tests/neutronics/feedback/multi_component_temp/multi_vars.i)
[Mesh]
[load]
type = FileMeshGenerator
file = ../../meshes/pincell.e
[]
[split_fuel]
type = ParsedSubdomainMeshGenerator
combinatorial_geometry = 'z < 5.0'
excluded_subdomains = '3 2'
block_id = 10
input = load
[]
[]
[AuxVariables]
[cell_temp]
family = MONOMIAL
order = CONSTANT
[]
[collated_temp]
family = MONOMIAL
order = CONSTANT
[]
[]
[AuxKernels]
[cell_temp]
type = CellTemperatureAux
variable = cell_temp
[]
[collated_solid_temp]
type = ProjectionAux
variable = collated_temp
v = solid_temp
block = '1 3'
execute_on = timestep_begin
[]
[collated_fluid_temp]
type = ProjectionAux
variable = collated_temp
v = fluid_temp
block = '2'
execute_on = timestep_begin
[]
[collated_other_temp]
type = ProjectionAux
variable = collated_temp
v = other_temp
block = '10'
execute_on = timestep_begin
[]
[]
[ICs]
[solid_temp]
type = ConstantIC
variable = solid_temp
value = 800
[]
[fluid_temp]
type = ConstantIC
variable = fluid_temp
value = 600
[]
[other_temp]
type = ConstantIC
variable = other_temp
value = 400
[]
[]
[Problem]
type = OpenMCCellAverageProblem
power = 500.0
cell_level = 0
verbose = true
temperature_variables = 'solid_temp; fluid_temp; other_temp'
temperature_blocks = '1 3; 2; 10'
[Tallies]
[Cell]
type = CellTally
block = '1 3 2 10'
[]
[]
[]
[Executioner]
type = Steady
[]
[Postprocessors]
[max_temp]
type = ElementExtremeValue
variable = cell_temp
value_type = max
[]
[min_temp]
type = ElementExtremeValue
variable = cell_temp
value_type = min
[]
[avg_temp]
type = ElementAverageValue
variable = collated_temp
[]
[]
[Outputs]
exodus = true
csv = true
[]
(test/tests/postprocessors/eigenvalue/openmc.i)
[Mesh]
[sphere]
type = FileMeshGenerator
file = ../../neutronics/meshes/sphere.e
[]
[solid]
type = CombinerGenerator
inputs = sphere
positions = '0 0 0
0 0 4
0 0 8'
[]
[solid_ids]
type = SubdomainIDGenerator
input = solid
subdomain_id = '100'
[]
[]
[Problem]
type = OpenMCCellAverageProblem
power = 100.0
temperature_blocks = '100'
cell_level = 0
initial_properties = xml
[Tallies]
[Cell]
type = CellTally
block = '100'
check_tally_sum = false
[]
[]
[]
[Executioner]
type = Transient
num_steps = 1
[]
[Postprocessors]
[k_collision]
type = KEigenvalue
value_type = 'collision'
[]
[k_absorption]
type = KEigenvalue
value_type = 'absorption'
[]
[k_tracklength]
type = KEigenvalue
value_type = 'tracklength'
[]
[k_combined]
type = KEigenvalue
value_type = 'combined'
[]
[k_collision_std_dev]
type = KEigenvalue
output = 'std_dev'
value_type = 'collision'
[]
[k_absorption_std_dev]
type = KEigenvalue
output = 'std_dev'
value_type = 'absorption'
[]
[k_tracklength_std_dev]
type = KEigenvalue
output = 'std_dev'
value_type = 'tracklength'
[]
[k_combined_std_dev]
type = KEigenvalue
output = 'std_dev'
value_type = 'combined'
[]
[k_collision_rel]
type = KEigenvalue
output = 'rel_err'
value_type = 'collision'
[]
[k_absorption_rel]
type = KEigenvalue
output = 'rel_err'
value_type = 'absorption'
[]
[k_tracklength_rel]
type = KEigenvalue
output = 'rel_err'
value_type = 'tracklength'
[]
[k_combined_rel]
type = KEigenvalue
output = 'rel_err'
value_type = 'combined'
[]
[]
[Outputs]
csv = true
[]
(test/tests/neutronics/symmetry/triso/openmc.i)
[Mesh]
[solid]
type = FileMeshGenerator
file = solid_mesh_in.e
[]
[]
[AuxVariables]
[cell_temperature]
family = MONOMIAL
order = CONSTANT
[]
[]
[AuxKernels]
[cell_temperature]
type = CellTemperatureAux
variable = cell_temperature
[]
[]
[ICs]
[temp]
type = FunctionIC
variable = temp
function = temp
block = 'graphite'
[]
[temp_fuel]
type = FunctionIC
variable = temp
function = temp_fuel
block = 'compacts'
[]
[]
# We set an initial temperature distribution that is NOT symmetry about the imposed
# symmmetry plane; by checking the cell temperature, we can ensure that the data
# mapping is done correctly (in addition to checking that the *extracted* heat source
# reflects the imposed symmetry)
[Functions]
[temp]
type = ParsedFunction
expression = '500+(exp(10*x)+exp(10*y))*50'
[]
[temp_fuel]
type = ParsedFunction
expression = '500+(exp(10*x)+exp(10*y))*50 + 100'
[]
[]
[Problem]
type = OpenMCCellAverageProblem
identical_cell_fills = 'compacts'
check_identical_cell_fills = true
power = 1000.0
scaling = 100.0
temperature_blocks = 'graphite compacts'
cell_level = 1
symmetry_mapper = sym
[Tallies]
[Cell]
type = CellTally
block = 'compacts'
check_equal_mapped_tally_volumes = true
[]
[]
[]
[UserObjects]
[sym]
type = SymmetryPointGenerator
normal = '-1.0 0.0 0.0'
[]
[]
[Executioner]
type = Transient
num_steps = 1
[]
[Postprocessors]
[heat_source]
type = ElementIntegralVariablePostprocessor
variable = kappa_fission
block = 'compacts'
[]
[]
[Outputs]
exodus = true
# it is hard to get parallel-reproducible results with high-scattering TRISO
# problems, so this input will only check on the mapping
hide = 'temp kappa_fission'
[]
(test/tests/neutronics/heat_source/multi_tally_mapping_solid.i)
[Mesh]
[sphere]
type = FileMeshGenerator
file = ../meshes/sphere.e
[]
[solid]
type = CombinerGenerator
inputs = sphere
positions = '0 0 0
0 0 4
0 0 8'
[]
[solid_ids]
type = SubdomainIDGenerator
input = solid
subdomain_id = '100'
[]
[fluid]
type = FileMeshGenerator
file = stoplight.exo
[]
[fluid_ids]
type = SubdomainIDGenerator
input = fluid
subdomain_id = '200'
[]
[combine]
type = CombinerGenerator
inputs = 'solid_ids fluid_ids'
[]
[]
[Problem]
type = OpenMCCellAverageProblem
power = 100.0
temperature_blocks = '100 200'
density_blocks = '200'
verbose = true
cell_level = 0
initial_properties = xml
[Tallies]
[Cell]
type = CellTally
score = 'kappa_fission heating'
block = '100'
normalize_by_global_tally = false
check_tally_sum = false
[]
[]
[]
[Executioner]
type = Transient
num_steps = 1
[]
[Postprocessors]
[solid_kappa_fission]
type = ElementIntegralVariablePostprocessor
variable = kappa_fission
block = '100'
[]
[solid_heating]
type = ADElementIntegralFunctorPostprocessor
functor = heating
block = '100'
[]
[]
[Outputs]
csv = true
[]
(test/tests/neutronics/heat_source/distrib_cell/solid.i)
[Mesh]
[sphere]
type = FileMeshGenerator
file = ../../meshes/sphere.e
[]
[solid]
type = CombinerGenerator
inputs = sphere
positions = '0 0 0
0 0 4
0 0 8'
[]
[solid_ids]
type = SubdomainIDGenerator
input = solid
subdomain_id = '100'
[]
[fluid]
type = FileMeshGenerator
file = ../stoplight.exo
[]
[fluid_ids]
type = SubdomainIDGenerator
input = fluid
subdomain_id = '200'
[]
[combine]
type = CombinerGenerator
inputs = 'solid_ids fluid_ids'
[]
[]
[Problem]
type = OpenMCCellAverageProblem
power = 100.0
temperature_blocks = '100 200'
density_blocks = '200'
# This turns off the density and temperature update on the first syncSolutions;
# this uses whatever temperature and densities are set in OpenMCs XML files for first step
initial_properties = xml
verbose = true
cell_level = 0
[Tallies]
[Cell]
type = CellTally
name = heat_source
block = '100 200'
[]
[]
[]
[Executioner]
type = Steady
[]
[Postprocessors]
[heat_source]
type = ElementIntegralVariablePostprocessor
variable = heat_source
[]
[]
[Outputs]
execute_on = final
exodus = true
hide = 'density'
[]
(test/tests/neutronics/tally_grad/finite_diff/openmc_dup.i)
[Mesh]
[sphere]
type = FileMeshGenerator
file = ../../meshes/sphere.e
[]
[solid1]
type = SubdomainIDGenerator
input = sphere
subdomain_id = '100'
[]
allow_renumbering = false
parallel_type = replicated
[]
[AuxVariables]
[grad_kappa_fission]
type = VectorMooseVariable
family = MONOMIAL_VEC
order = CONSTANT
[]
[mag_grad_kappa_fission]
family = MONOMIAL
order = CONSTANT
[]
[]
[AuxKernels]
[comp_grad_kappa_fission]
type = FDTallyGradAux
variable = grad_kappa_fission
score = 'kappa_fission'
[]
[mag_grad_kappa_fission]
type = VectorVariableMagnitudeAux
variable = mag_grad_kappa_fission
vector_variable = grad_kappa_fission
[]
[]
[Problem]
type = OpenMCCellAverageProblem
temperature_blocks = '100'
initial_properties = xml
verbose = true
cell_level = 0
power = 100.0
source_rate_normalization = 'kappa_fission'
normalization_tally = 'Cell'
[Tallies]
[Mesh]
type = MeshTally
score = 'kappa_fission'
name = 'mesh_kf'
normalize_by_global_tally = false
[]
[Cell]
type = CellTally
score = 'kappa_fission'
name = 'cell_kf'
normalize_by_global_tally = false
[]
[Cell_Flux]
type = CellTally
score = 'flux'
name = 'cell_flux'
normalize_by_global_tally = false
[]
[]
[]
[Executioner]
type = Steady
[]
[Postprocessors]
[max_grad]
type = ElementExtremeValue
variable = mag_grad_kappa_fission
value_type = max
[]
[]
[Outputs]
execute_on = final
csv = true
[]
(test/tests/neutronics/dagmc/with_csg/dag_lattice_outer/openmc.i)
[Mesh]
[slab]
type = FileMeshGenerator
file = ../../mesh_tallies/slab.e
[]
allow_renumbering = false
parallel_type = replicated
[]
[AuxVariables]
[cell_temperature]
family = MONOMIAL
order = CONSTANT
[]
[]
[AuxKernels]
[cell_temperature]
type = CellTemperatureAux
variable = cell_temperature
[]
[]
[AuxKernels]
[temp]
type = ConstantAux
variable = temp
value = 500.0
execute_on = timestep_begin
[]
[]
[Problem]
type = OpenMCCellAverageProblem
verbose = true
temperature_blocks = '1 2'
cell_level = 1
power = 100.0
skinner = moab
[Tallies]
[Cell]
type = CellTally
block = '1 2'
[]
[]
[]
[UserObjects]
[moab]
type = MoabSkinner
temperature_min = 0.0
temperature_max = 1000.0
n_temperature_bins = 1
temperature = temp
build_graveyard = true
[]
[]
[Postprocessors]
[k]
type = KEigenvalue
[]
[]
[Executioner]
type = Transient
num_steps = 2
[]
[Outputs]
exodus = true
hide = 'temp'
[]
(test/tests/postprocessors/fission_tally_relative_error/openmc.i)
[Mesh]
[sphere]
type = FileMeshGenerator
file = ../../neutronics/meshes/sphere.e
[]
[solid]
type = CombinerGenerator
inputs = sphere
positions = '0 0 0
0 0 4
0 0 8'
[]
[solid_ids]
type = SubdomainIDGenerator
input = solid
subdomain_id = '100'
[]
[]
[Problem]
type = OpenMCCellAverageProblem
power = 100.0
temperature_blocks = '100'
cell_level = 0
initial_properties = xml
[Tallies]
[Cell]
type = CellTally
block = '100'
check_tally_sum = false
# this outputs the fission tally standard deviation in space
output = 'unrelaxed_tally_std_dev'
[]
[]
[]
[Executioner]
type = Transient
num_steps = 1
[]
[Postprocessors]
[max_rel_err]
type = TallyRelativeError
value_type = max
[]
[min_rel_err]
type = TallyRelativeError
value_type = min
[]
[avg_rel_err]
type = TallyRelativeError
value_type = average
[]
[power_1]
type = PointValue
variable = kappa_fission
point = '0 0 0'
[]
[power_2]
type = PointValue
variable = kappa_fission
point = '0 0 4'
[]
[power_3]
type = PointValue
variable = kappa_fission
point = '0 0 8'
[]
[std_dev_1]
type = PointValue
variable = kappa_fission_std_dev
point = '0 0 0'
[]
[std_dev_2]
type = PointValue
variable = kappa_fission_std_dev
point = '0 0 4'
[]
[std_dev_3]
type = PointValue
variable = kappa_fission_std_dev
point = '0 0 8'
[]
[]
[Outputs]
csv = true
[]
(test/tests/neutronics/mg/doppler_slab_lin/openmc_base.i)
joule_per_ev = 1.60218e-19
q = ${fparse 1.0e6} # Energy release per absorption (eV)
Sigma0 = ${fparse 4.0 * 0.025} # Initial macroscopic XS, 1/cm
T0 = 293.6 # Surface temperature (K)
Y0 = 6.65e11 # Source intensity (n / cm2-s)
alpha = -0.0001 # Linear doppler Coefficient (1 / K)
k = 0.006 # Thermal conductivity (W / cm-K)
!include mesh.i
[AuxVariables]
[cell_temperature]
family = MONOMIAL
order = CONSTANT
[]
# Variables added to convert into proper heat source term for the power in the solid
[heat_source] # W / cm^3
family = MONOMIAL
order = CONSTANT
[]
[]
[AuxKernels]
[cell_temperature]
type = CellTemperatureAux
variable = cell_temperature
[]
# Change the unit of the 'flux' (neutrons / m^2 / s) into a volumetric power. This is
# based on Eq. (5b) in the paper, which shows the volumetric power is q / k * Sigma * flux
[compute_power]
type = ParsedAux
variable = heat_source
coupled_variables = 'flux temp'
expression = 'flux * ${q} * ${joule_per_ev} * ${Sigma0} * (1+(${alpha}/${Sigma0})*(temp-${T0}))'
execute_on = 'timestep_end'
[]
[]
[ICs]
[temp]
type = ConstantIC
variable = temp
value = ${T0}
[]
[]
[Problem]
type = OpenMCCellAverageProblem
verbose = true
source_strength = ${fparse Y0 * 2.0 * 2.0} # multiply by the left area to get units of neutrons / s
cell_level = 0
temperature_blocks = '0'
initial_properties = xml
particles = 1000
batches = 100
inactive_batches = 0
relaxation = 'constant'
[Tallies]
[heating]
type = CellTally
score = 'flux'
output = 'unrelaxed_tally_std_dev'
check_tally_sum = false
[]
[]
[]
[Executioner]
type = Transient
dt = 1.0
steady_state_detection = true
check_aux = true
num_steps = 3
[]
[MultiApps]
[solid]
type = TransientMultiApp
app_type = CardinalApp
input_files = 'solid.i'
execute_on = timestep_end
sub_cycling = true
[]
[]
[Transfers]
[solid_temp]
type = MultiAppGeneralFieldShapeEvaluationTransfer
source_variable = T
variable = temp
from_multi_app = solid
[]
[source_to_solid]
type = MultiAppGeneralFieldShapeEvaluationTransfer
source_variable = heat_source
variable = power
to_multi_app = solid
[]
[]
[Postprocessors]
[max_heat_source]
type = ElementExtremeValue
variable = heat_source
execute_on = 'timestep_begin'
[]
[max_flux]
type = ElementExtremeValue
variable = flux
[]
[max_temp]
type = ElementExtremeValue
variable = temp
[]
[]
[Outputs]
csv = true
execute_on = 'TIMESTEP_END'
[]
(test/tests/controls/openmc_nuclide_densities/error.i)
[Mesh]
[g]
type = GeneratedMeshGenerator
dim = 3
nx = 8
ny = 8
nz = 8
xmin = -12.5
xmax = 87.5
ymin = -12.5
ymax = 37.5
zmin = -12.5
zmax = 12.5
[]
[]
[Problem]
type = OpenMCCellAverageProblem
verbose = true
temperature_blocks = '0'
cell_level = 0
power = 100.0
[Tallies]
[Cell]
type = CellTally
block = 0
[]
[]
[]
[UserObjects]
[mat1]
type = OpenMCNuclideDensities
material_id = 1
names = 'U235'
densities = '0.02'
[]
[]
[Controls]
[c]
type = OpenMCNuclideDensitiesControl
user_object = none
names = 'U235'
densities = '0.01'
[]
[]
[Executioner]
type = Steady
[]
(test/tests/neutronics/filters/particle/cell.i)
[Mesh]
[sphere]
type = FileMeshGenerator
file = ../../meshes/sphere.e
[]
[solid]
type = CombinerGenerator
inputs = sphere
positions = '0 0 0
0 0 4
0 0 8'
[]
[solid_ids]
type = SubdomainIDGenerator
input = solid
subdomain_id = '100'
[]
[fluid]
type = FileMeshGenerator
file = ../../heat_source/stoplight.exo
[]
[fluid_ids]
type = SubdomainIDGenerator
input = fluid
subdomain_id = '200'
[]
[combine]
type = CombinerGenerator
inputs = 'solid_ids fluid_ids'
[]
allow_renumbering = false
[]
[Problem]
type = OpenMCCellAverageProblem
verbose = true
power = 1e4
temperature_blocks = '100'
cell_level = 0
initial_properties = xml
source_rate_normalization = 'kappa_fission'
[Tallies]
[Heating]
type = CellTally
score = 'heating'
block = '100 200'
filters = 'Particle'
[]
[]
[Filters]
[Particle]
type = ParticleFilter
particles = 'neutron photon electron positron'
[]
[]
[]
[Postprocessors]
[Pebble_1_heating_neutron]
type = PointValue
point = '0 0 0'
variable = heating_neutron
[]
[Pebble_2_heating_neutron]
type = PointValue
point = '0 0 4'
variable = heating_neutron
[]
[Pebble_3_heating_neutron]
type = PointValue
point = '0 0 8'
variable = heating_neutron
[]
[Pebble_1_heating_photon]
type = PointValue
point = '0 0 0'
variable = heating_photon
[]
[Pebble_2_heating_photon]
type = PointValue
point = '0 0 4'
variable = heating_photon
[]
[Pebble_3_heating_photon]
type = PointValue
point = '0 0 8'
variable = heating_photon
[]
[Pebble_1_heating_electron]
type = PointValue
point = '0 0 0'
variable = heating_electron
[]
[Pebble_2_heating_electron]
type = PointValue
point = '0 0 4'
variable = heating_electron
[]
[Pebble_3_heating_electron]
type = PointValue
point = '0 0 8'
variable = heating_electron
[]
[Pebble_1_heating_positron]
type = PointValue
point = '0 0 0'
variable = heating_positron
[]
[Pebble_2_heating_positron]
type = PointValue
point = '0 0 4'
variable = heating_positron
[]
[Pebble_3_heating_positron]
type = PointValue
point = '0 0 8'
variable = heating_positron
[]
[]
[Executioner]
type = Steady
[]
[Outputs]
csv = true
execute_on = 'TIMESTEP_END'
[]
(test/tests/neutronics/gen_mgxs/all_mgxs_cell_l0.i)
[Mesh]
[sphere]
type = FileMeshGenerator
file = ../meshes/sphere.e
[]
[solid1]
type = SubdomainIDGenerator
input = sphere
subdomain_id = '100'
[]
allow_renumbering = false
[]
[Problem]
type = OpenMCCellAverageProblem
verbose = true
cell_level = 0
power = 1.0
source_rate_normalization = 'kappa_fission'
[Tallies/Cell]
type = CellTally
block = '100'
normalize_by_global_tally = false
[]
[MGXS]
tally_type = cell
particle = neutron
group_structure = CASMO_2
estimator = 'analog'
normalize_by_global_tally = false
hide_tally_vars = true
add_scattering = true
legendre_order = 0
transport_correction = false
add_fission = false
add_fission_heating = false
add_inverse_velocity = false
add_diffusion_coefficient = false
add_absorption = false
[]
[]
[Executioner]
type = Steady
[]
[Postprocessors]
[scatter_xs_g1_gp1_l0]
type = PointValue
point = '0 0 0'
variable = scatter_xs_g1_gp1_l0
[]
[scatter_xs_g1_gp2_l0]
type = PointValue
point = '0 0 0'
variable = scatter_xs_g1_gp2_l0
[]
[scatter_xs_g2_gp1_l0]
type = PointValue
point = '0 0 0'
variable = scatter_xs_g2_gp1_l0
[]
[scatter_xs_g2_gp2_l0]
type = PointValue
point = '0 0 0'
variable = scatter_xs_g2_gp2_l0
[]
[]
[Outputs]
execute_on = final
csv = true
[]
(test/tests/neutronics/tally_system/multi_cell_relax.i)
[Mesh]
[sphere]
type = FileMeshGenerator
file = ../meshes/sphere.e
[]
[solid]
type = CombinerGenerator
inputs = sphere
positions = '0 0 0
0 0 4
0 0 8'
[]
[solid_ids]
type = SubdomainIDGenerator
input = solid
subdomain_id = '100'
[]
[fluid]
type = FileMeshGenerator
file = ../heat_source/stoplight.exo
[]
[fluid_ids]
type = SubdomainIDGenerator
input = fluid
subdomain_id = '200'
[]
[combine]
type = CombinerGenerator
inputs = 'solid_ids fluid_ids'
[]
[]
[AuxKernels]
[temp]
type = FunctionAux
variable = temp
function = axial
execute_on = initial
[]
[]
[Functions]
[axial]
type = ParsedFunction
expression = '500 + z / 0.10 * 100'
[]
[]
[Problem]
type = OpenMCCellAverageProblem
verbose = true
power = 1e4
temperature_blocks = '100'
cell_level = 0
initial_properties = xml
source_rate_normalization = 'kappa_fission'
relaxation = constant
relaxation_factor = 0.5
[Tallies]
[Cell_1]
type = CellTally
score = kappa_fission
block = '100 200'
[]
[Cell_2]
type = CellTally
score = flux
block = '100 200'
[]
[]
[]
[Postprocessors]
[Pebble_1_Heat]
type = PointValue
point = '0 0 0'
variable = kappa_fission
[]
[Pebble_2_Heat]
type = PointValue
point = '0 0 4'
variable = kappa_fission
[]
[Pebble_3_Heat]
type = PointValue
point = '0 0 8'
variable = kappa_fission
[]
[Pebble_1_Flux]
type = PointValue
point = '0 0 0'
variable = flux
[]
[Pebble_2_Flux]
type = PointValue
point = '0 0 4'
variable = flux
[]
[Pebble_3_Flux]
type = PointValue
point = '0 0 8'
variable = flux
[]
[]
[Executioner]
type = Transient
num_steps = 3
[]
[Outputs]
csv = true
[]
(test/tests/neutronics/heat_source/mapping_all.i)
[Mesh]
[sphere]
type = FileMeshGenerator
file = ../meshes/sphere.e
[]
[solid]
type = CombinerGenerator
inputs = sphere
positions = '0 0 0
0 0 4
0 0 8'
[]
[solid_ids]
type = SubdomainIDGenerator
input = solid
subdomain_id = '100'
[]
[fluid]
type = FileMeshGenerator
file = stoplight.exo
[]
[fluid_ids]
type = SubdomainIDGenerator
input = fluid
subdomain_id = '200'
[]
[combine]
type = CombinerGenerator
inputs = 'solid_ids fluid_ids'
[]
[]
[Problem]
type = OpenMCCellAverageProblem
power = 100.0
temperature_blocks = '100 200'
density_blocks = '200'
verbose = true
cell_level = 0
initial_properties = xml
[Tallies]
[Cell]
type = CellTally
block = '100 200'
name = heat_source
[]
[]
[]
[Executioner]
type = Steady
[]
[Postprocessors]
[heat_source]
type = ElementIntegralVariablePostprocessor
variable = heat_source
block = '100 200'
[]
[fluid_heat_source]
type = ElementIntegralVariablePostprocessor
variable = heat_source
block = '200'
[]
[solid_heat_source]
type = ElementIntegralVariablePostprocessor
variable = heat_source
block = '100'
[]
[]
[Outputs]
execute_on = final
exodus = true
hide = 'density'
[]
(test/tests/userobjects/openmc_cell_transform/multiple_cells/translate_cells.i)
[Mesh]
[pin]
type = ConcentricCircleMeshGenerator
num_sectors = 6
radii = '1.0'
rings = '3 3'
has_outer_square = on
pitch = 4.0
preserve_volumes = yes
smoothing_max_it = 3
[]
[assembly]
type = CartesianIDPatternedMeshGenerator
inputs = 'pin'
pattern = '0 0;
0 0'
assign_type = 'cell'
id_name = 'pin_id'
[]
[delete]
# Only keeping block 1 (fuel pins) for this test
type = BlockDeletionGenerator
input = assembly
block = 2
[]
[extrude]
type = AdvancedExtruderGenerator
direction = '0 0 1'
input = delete
heights = '30'
num_layers = '5'
[]
[translate]
type = TransformGenerator
input = extrude
transform = TRANSLATE_CENTER_ORIGIN
vector_value = '-12 12 0'
[]
[]
[GlobalParams]
displacements = 'disp_x disp_y disp_z'
use_displaced_mesh = true
[]
[Problem]
type = OpenMCCellAverageProblem
cell_level = 2
verbose = true
power = 100
[Tallies]
[heat]
type = CellTally
score = 'kappa_fission'
block = '1'
[]
[]
[]
[AuxVariables]
[disp_x]
[AuxKernel]
type = FunctionAux
variable = disp_x
function = disp_right_fn
[]
[]
[disp_y]
[AuxKernel]
type = FunctionAux
variable = disp_y
function = disp_top_fn
[]
[]
[disp_z]
[]
[]
[Functions]
[disp_top_fn]
type = ParsedFunction
expression = 'if(t>1,if(y>0,2*t,0),0)'
[]
[disp_right_fn]
type = ParsedFunction
expression = 'if(t>1,if(x>0,t,0),0)'
[]
[]
[Postprocessors]
[shift_top_row]
type = FunctionValuePostprocessor
function = disp_top_fn
[]
[shift_right_column]
type = FunctionValuePostprocessor
function = disp_right_fn
[]
[k]
type = KEigenvalue
[]
[power]
type = ElementIntegralVariablePostprocessor
variable = kappa_fission
block = '1'
[]
[]
[UserObjects]
[translate_top]
type = OpenMCCellTransform
transform_type = 'translation'
vector_value = '0 shift_top_row 0'
cell_ids = '2013 2014'
[]
[translate_right]
type = OpenMCCellTransform
transform_type = 'translation'
vector_value = 'shift_right_column 0 0'
cell_ids = '2012 2014'
[]
[]
[Executioner]
type = Transient
num_steps = 2
[]
[Outputs]
exodus = true
[]
(test/tests/neutronics/gen_mgxs/mgxs_aux/mg_tc_scatter_xs.i)
[Mesh]
[sphere]
type = FileMeshGenerator
file = ../../meshes/sphere.e
[]
[solid1]
type = SubdomainIDGenerator
input = sphere
subdomain_id = '100'
[]
allow_renumbering = false
[]
[AuxVariables]
[scatter_g1_g1_l0]
type = MooseVariable
order = CONSTANT
family = MONOMIAL
[]
[zero_flux]
type = MooseVariable
order = CONSTANT
family = MONOMIAL
initial_condition = '0.0'
[]
[]
[AuxKernels]
[comp_scatter_g1_g1_l0]
type = ComputeTCScatterMGXSAux
variable = scatter_g1_g1_l0
p0_scatter_rxn_rate = 'nu_scatter_g1_gp1_l1'
p1_scatter_rxn_rates = 'nu_scatter_g1_gp1_l1 nu_scatter_g2_gp1_l1'
scalar_flux = 'flux_g1'
[]
[]
[Problem]
type = OpenMCCellAverageProblem
initial_properties = xml
verbose = true
cell_level = 0
power = 1.0
source_rate_normalization = 'kappa_fission'
[Tallies]
[Cell_KF]
type = CellTally
score = 'kappa_fission'
block = '100'
normalize_by_global_tally = false
[]
[Cell_Total_Flux]
type = CellTally
score = 'total flux'
block = '100'
filters = 'Energy'
normalize_by_global_tally = false
[]
[Cell_Scatter]
type = CellTally
score = 'nu_scatter'
block = '100'
filters = 'Energy EnergyOut Legendre'
estimator = 'analog'
normalize_by_global_tally = false
[]
[]
[Filters]
[Energy]
type = EnergyFilter
energy_boundaries = '0.0 6.25e-1 2.0e7'
reverse_bins = true
[]
[EnergyOut]
type = EnergyOutFilter
energy_boundaries = '0.0 6.25e-1 2.0e7'
reverse_bins = true
[]
[Legendre]
type = AngularLegendreFilter
order = 1
[]
[]
[]
[Executioner]
type = Steady
[]
[Postprocessors]
[result]
type = PointValue
point = '0 0 0'
variable = scatter_g1_g1_l0
[]
[]
[Outputs]
execute_on = final
csv = true
[]
(test/tests/neutronics/dagmc/properties.i)
[Mesh]
[file]
type = FileMeshGenerator
file = ../meshes/tet_cube.e
[]
parallel_type = replicated
[]
[Problem]
type = OpenMCCellAverageProblem
cell_level = 0
temperature_blocks = '1'
power = 1000.0
skinner = moab
initial_properties = hdf5
[Tallies]
[Cell]
type = CellTally
block = '1'
[]
[]
[]
[UserObjects]
[moab]
type = MoabSkinner
temperature = temp
n_temperature_bins = 1
temperature_min = 0.0
temperature_max = 100.0
[]
[]
[Executioner]
type = Steady
[]
(test/tests/neutronics/dagmc/cell_tallies/openmc.i)
[Mesh]
type = FileMesh
file = ../mesh_tallies/slab.e
allow_renumbering = false
[]
x0 = 12.5
x1 = 37.5
x2 = 62.5
[AuxVariables]
[cell_temperature]
family = MONOMIAL
order = CONSTANT
[]
[]
[AuxKernels]
[cell_temperature]
type = CellTemperatureAux
variable = cell_temperature
[]
[]
T0 = 600.0
dT = 50.0
[Functions]
[temp]
type = ParsedFunction
expression = 'if (x <= ${x0}, ${fparse T0 - dT}, if (x <= ${x1}, ${T0}, if (x <= ${x2}, ${fparse T0 + dT}, ${fparse T0 + 2 * dT})))'
[]
[]
[AuxKernels]
[temp]
type = FunctionAux
variable = temp
function = temp
execute_on = timestep_begin
[]
[]
[Problem]
type = OpenMCCellAverageProblem
verbose = true
temperature_blocks = '1 2'
cell_level = 0
power = 100.0
skinner = moab
[Tallies]
[Cell]
type = CellTally
block = '1 2'
[]
[]
[]
[UserObjects]
[moab]
type = MoabSkinner
temperature_min = ${fparse T0 - dT}
temperature_max = ${fparse T0 + 2 * dT}
n_temperature_bins = 4
temperature = temp
build_graveyard = true
[]
[]
[Postprocessors]
[k]
type = KEigenvalue
[]
[]
[Executioner]
type = Transient
num_steps = 2
[]
[Outputs]
exodus = true
[]
(test/tests/openmc_errors/incorrect_var_setup/incorrect_var_type.i)
[Mesh]
[sphere]
type = FileMeshGenerator
file = ../../neutronics/meshes/sphere.e
[]
[solid]
type = CombinerGenerator
inputs = sphere
positions = '0 0 0
0 0 4
0 0 8
9 9 9'
[]
[solid_ids]
type = SubdomainIDGenerator
input = solid
subdomain_id = '100'
[]
[]
[AuxVariables]
[cell_id_n]
[]
[]
[AuxKernels]
[cell_id_n]
type = CellIDAux
variable = cell_id_n
[]
[]
[Problem]
type = OpenMCCellAverageProblem
power = 70.0
temperature_blocks = '100'
cell_level = 0
initial_properties = xml
[Tallies]
[Cell]
type = CellTally
block = '100'
[]
[]
[]
[Executioner]
type = Transient
num_steps = 1
[]
[Outputs]
exodus = true
[]
(test/tests/openmc_errors/level/total_too_high/level_too_high.i)
[Mesh]
[sphere]
# Mesh of a single pebble with outer radius of 1.5 (cm)
type = FileMeshGenerator
file = ../../../neutronics/meshes/sphere.e
[]
[solid]
type = CombinerGenerator
inputs = sphere
positions = '0 0 0
0 0 4
0 0 8'
[]
[solid_ids]
type = SubdomainIDGenerator
input = solid
subdomain_id = '100'
[]
[]
[Problem]
type = OpenMCCellAverageProblem
power = 70.0
temperature_blocks = '100'
verbose = true
# skip the data transfer of temperature into OpenMC for the first time step
# so that we can just use the ICs set in OpenMCs XML files
initial_properties = xml
cell_level = 1
[Tallies]
[Cell]
type = CellTally
block = '100'
[]
[]
[]
[Executioner]
type = Transient
num_steps = 1
[]
[Outputs]
exodus = true
[]
(tutorials/lwr_solid/openmc.i)
[Mesh]
[file]
type = FileMeshGenerator
file = mesh_in.e
[]
[]
[AuxVariables]
[cell_temperature]
family = MONOMIAL
order = CONSTANT
[]
[]
[AuxKernels]
[cell_temperature]
type = CellTemperatureAux
variable = cell_temperature
[]
[]
[Problem]
type = OpenMCCellAverageProblem
verbose = true
power = ${fparse 3000e6 / 273 / (17 * 17)}
temperature_blocks = '1 2 3'
cell_level = 0
volume_calculation = vol
[Tallies]
[heat_source]
type = CellTally
block = '2 3'
name = heat_source
[]
[]
[]
[UserObjects]
[vol]
type = OpenMCVolumeCalculation
n_samples = 100000
[]
[]
[Executioner]
type = Transient
[]
[Outputs]
exodus = true
csv = true
[]
[Postprocessors]
[heat_source]
type = ElementIntegralVariablePostprocessor
variable = heat_source
block = '2 3'
[]
[max_tally_rel_err]
type = TallyRelativeError
[]
[max_heat_source]
type = ElementExtremeValue
variable = heat_source
block = '2 3'
[]
[]
(test/tests/neutronics/feedback/unmapped_moose/openmc.i)
[Mesh]
[pincell]
type = FileMeshGenerator
file = ../../meshes/pincell.e
[]
[combine]
type = CombinerGenerator
inputs = 'pincell'
positions = '0 0 0
5 0 0'
[]
[]
[AuxVariables]
[cell_temperature]
family = MONOMIAL
order = CONSTANT
[]
[material_id]
family = MONOMIAL
order = CONSTANT
[]
[cell_density]
family = MONOMIAL
order = CONSTANT
[]
[]
[AuxKernels]
[material_id]
type = CellMaterialIDAux
variable = material_id
[]
[cell_temperature]
type = CellTemperatureAux
variable = cell_temperature
execute_on = 'timestep_end'
[]
[cell_density]
type = CellDensityAux
variable = cell_density
execute_on = 'timestep_end'
[]
[]
[Problem]
type = OpenMCCellAverageProblem
power = 500.0
temperature_blocks = '1 2 3'
density_blocks = '2'
verbose = true
cell_level = 0
[Tallies]
[Cell]
type = CellTally
block = '1 2 3'
[]
[]
[]
[Executioner]
type = Transient
[]
[Postprocessors]
[heat_source]
type = ElementIntegralVariablePostprocessor
variable = kappa_fission
[]
[fluid_heat_source]
type = ElementIntegralVariablePostprocessor
variable = kappa_fission
block = '2'
[]
[solid_heat_source]
type = ElementIntegralVariablePostprocessor
variable = kappa_fission
block = '1 3'
[]
[]
[Outputs]
exodus = true
[]
(test/tests/neutronics/adaptivity/unchanged_sub.i)
[Mesh]
[sphere]
type = FileMeshGenerator
file = ../meshes/sphere.e
[]
[solid_ids]
type = SubdomainIDGenerator
input = sphere
subdomain_id = '100'
[]
[solid]
type = CombinerGenerator
inputs = solid_ids
positions = '0 0 0'
avoid_merging_subdomains = true
[]
allow_renumbering = false
[]
[AuxVariables]
[cell_temperature]
family = MONOMIAL
order = CONSTANT
[]
[material_id]
family = MONOMIAL
order = CONSTANT
[]
[cell_density]
family = MONOMIAL
order = CONSTANT
[]
[]
[AuxKernels]
[material_id]
type = CellMaterialIDAux
variable = material_id
[]
[cell_temperature]
type = CellTemperatureAux
variable = cell_temperature
execute_on = 'timestep_end'
[]
[cell_density]
type = CellDensityAux
variable = cell_density
execute_on = 'timestep_end'
[]
[]
[Adaptivity]
steps = 1
marker = uniform
[Markers/uniform]
type = UniformMarker
mark = DO_NOTHING
[]
[]
[Problem]
type = OpenMCCellAverageProblem
power = 500.0
temperature_blocks = '100'
density_blocks = '100'
verbose = true
cell_level = 0
[Tallies]
[Cell]
type = CellTally
block = '100'
check_tally_sum = false
[]
[]
[]
[Executioner]
type = Steady
[]
[Postprocessors]
[kappa_fission]
type = ElementIntegralVariablePostprocessor
variable = kappa_fission
[]
[]
[Outputs]
exodus = true
[]
(test/tests/neutronics/indicators/rel_err/openmc_dup.i)
[Mesh]
[sphere]
type = FileMeshGenerator
file = ../../meshes/sphere.e
[]
[solid1]
type = SubdomainIDGenerator
input = sphere
subdomain_id = '100'
[]
allow_renumbering = false
parallel_type = replicated
[]
[Adaptivity]
[Indicators/stat_err]
type = StatRelErrorIndicator
score = 'kappa_fission'
[]
[]
[Problem]
type = OpenMCCellAverageProblem
verbose = true
cell_level = 0
power = 100.0
[Tallies]
[Mesh]
type = MeshTally
score = 'kappa_fission'
name = 'mesh_kf'
output = 'unrelaxed_tally_rel_error'
normalize_by_global_tally = false
[]
[Cell]
type = CellTally
score = 'kappa_fission'
name = 'cell_kf'
output = 'unrelaxed_tally_rel_error'
normalize_by_global_tally = false
[]
[Cell_2]
type = CellTally
score = 'heating'
name = 'cell_2_heating'
output = 'unrelaxed_tally_rel_error'
normalize_by_global_tally = false
[]
[]
[]
[Executioner]
type = Transient
num_steps = 2
[]
[Postprocessors]
[max_rel]
type = ElementExtremeValue
variable = stat_err
value_type = max
[]
[]
[Outputs]
execute_on = timestep_end
csv = true
[]
(test/tests/neutronics/gen_mgxs/all_mgxs_cell_l1.i)
[Mesh]
[sphere]
type = FileMeshGenerator
file = ../meshes/sphere.e
[]
[solid1]
type = SubdomainIDGenerator
input = sphere
subdomain_id = '100'
[]
allow_renumbering = false
[]
[Problem]
type = OpenMCCellAverageProblem
verbose = true
cell_level = 0
power = 1.0
source_rate_normalization = 'kappa_fission'
[Tallies/Cell]
type = CellTally
block = '100'
normalize_by_global_tally = false
[]
[MGXS]
tally_type = cell
particle = neutron
group_structure = CASMO_2
estimator = 'analog'
normalize_by_global_tally = false
hide_tally_vars = true
add_scattering = true
legendre_order = 1
transport_correction = false
add_fission = false
add_fission_heating = false
add_inverse_velocity = false
add_diffusion_coefficient = false
add_absorption = false
[]
[]
[Executioner]
type = Steady
[]
[Postprocessors]
[scatter_xs_g1_gp1_l0]
type = PointValue
point = '0 0 0'
variable = scatter_xs_g1_gp1_l0
[]
[scatter_xs_g1_gp2_l0]
type = PointValue
point = '0 0 0'
variable = scatter_xs_g1_gp2_l0
[]
[scatter_xs_g2_gp1_l0]
type = PointValue
point = '0 0 0'
variable = scatter_xs_g2_gp1_l0
[]
[scatter_xs_g2_gp2_l0]
type = PointValue
point = '0 0 0'
variable = scatter_xs_g2_gp2_l0
[]
[scatter_xs_g1_gp1_l1]
type = PointValue
point = '0 0 0'
variable = scatter_xs_g1_gp1_l1
[]
[scatter_xs_g1_gp2_l1]
type = PointValue
point = '0 0 0'
variable = scatter_xs_g1_gp2_l1
[]
[scatter_xs_g2_gp1_l1]
type = PointValue
point = '0 0 0'
variable = scatter_xs_g2_gp1_l1
[]
[scatter_xs_g2_gp2_l1]
type = PointValue
point = '0 0 0'
variable = scatter_xs_g2_gp2_l1
[]
[]
[Outputs]
execute_on = final
csv = true
[]
(test/tests/neutronics/dagmc/cell_tallies/csg_step_2/openmc.i)
[Mesh]
type = FileMesh
file = ../../mesh_tallies/slab.e
[]
x0 = 12.5
x1 = 37.5
x2 = 62.5
[AuxVariables]
[cell_temperature]
family = MONOMIAL
order = CONSTANT
[]
[]
[AuxKernels]
[cell_temperature]
type = CellTemperatureAux
variable = cell_temperature
[]
[]
T0 = 600.0
dT = 50.0
[Functions]
[temp]
type = ParsedFunction
expression = 'if (x <= ${x0}, ${fparse T0 - dT}, if (x <= ${x1}, ${T0}, if (x <= ${x2}, ${fparse T0 + dT}, ${fparse T0 + 2 * dT})))'
[]
[]
[AuxKernels]
[temp]
type = FunctionAux
variable = temp
function = temp
execute_on = timestep_begin
[]
[]
[Problem]
type = OpenMCCellAverageProblem
verbose = true
temperature_blocks = '1 2'
cell_level = 0
power = 100.0
[Tallies]
[Cell]
type = CellTally
block = '1 2'
[]
[]
[]
[Postprocessors]
[k]
type = KEigenvalue
[]
[]
[Executioner]
type = Transient
num_steps = 2
[]
[Outputs]
exodus = true
[]
(test/tests/neutronics/filters/legendre/cell.i)
[Mesh]
[sphere]
type = FileMeshGenerator
file = ../../meshes/sphere.e
[]
[solid]
type = CombinerGenerator
inputs = sphere
positions = '0 0 0
0 0 4
0 0 8'
[]
[solid_ids]
type = SubdomainIDGenerator
input = solid
subdomain_id = '100'
[]
[fluid]
type = FileMeshGenerator
file = ../../heat_source/stoplight.exo
[]
[fluid_ids]
type = SubdomainIDGenerator
input = fluid
subdomain_id = '200'
[]
[combine]
type = CombinerGenerator
inputs = 'solid_ids fluid_ids'
[]
allow_renumbering = false
[]
[Problem]
type = OpenMCCellAverageProblem
verbose = true
power = 1e4
temperature_blocks = '100'
cell_level = 0
initial_properties = xml
source_rate_normalization = 'kappa_fission'
[Tallies]
[Heating]
type = CellTally
score = 'kappa_fission'
block = '100 200'
[]
[Scattering]
type = CellTally
score = 'scatter'
block = '100 200'
filters = 'Legendre'
estimator = 'analog'
[]
[]
[Filters]
[Legendre]
type = AngularLegendreFilter
order = 1
[]
[]
[]
[Postprocessors]
[Pebble_1_scatter_l0]
type = PointValue
point = '0 0 0'
variable = scatter_l0
[]
[Pebble_2_scatter_l0]
type = PointValue
point = '0 0 4'
variable = scatter_l0
[]
[Pebble_3_scatter_l0]
type = PointValue
point = '0 0 8'
variable = scatter_l0
[]
[Pebble_1_scatter_l1]
type = PointValue
point = '0 0 0'
variable = scatter_l1
[]
[Pebble_2_scatter_l1]
type = PointValue
point = '0 0 4'
variable = scatter_l1
[]
[Pebble_3_scatter_l1]
type = PointValue
point = '0 0 8'
variable = scatter_l1
[]
[]
[Executioner]
type = Steady
[]
[Outputs]
csv = true
[]
(test/tests/neutronics/solid/openmc_missing_pebble.i)
# This is a vertical stack of three pebbles, with a 1 meter thick layer of flibe
# on the outer periphery and on the top and bottom, to get a k closer to 1.0.
#
# We check that we get an error if we forget one of the pebbles.
[Mesh]
[sphere]
# Mesh of a single pebble with outer radius of 1.5 (cm)
type = FileMeshGenerator
file = ../meshes/sphere.e
[]
[multiple]
type = CombinerGenerator
inputs = sphere
positions = '0 0 0
0 0 4'
[]
[]
[Problem]
type = OpenMCCellAverageProblem
power = 10.0
cell_level = 0
temperature_blocks = '1'
[Tallies]
[Cell]
type = CellTally
block = '1'
[]
[]
[]
[Executioner]
type = Transient
[]
(test/tests/openmc_errors/zero_tally/openmc.i)
[Mesh]
[sphere]
type = FileMeshGenerator
file = ../../neutronics/meshes/sphere.e
[]
[solid]
type = CombinerGenerator
inputs = sphere
positions = '0 0 0
0 0 4
0 0 8'
[]
[]
[Problem]
type = OpenMCCellAverageProblem
power = 100.0
cell_level = 0
source_strength = 1e6
[Tallies]
[Cell]
type = CellTally
block = '1'
[]
[]
[]
[Executioner]
type = Steady
[]
[Outputs]
csv = true
[]
[Postprocessors]
[power]
type = ElementIntegralVariablePostprocessor
variable = kappa_fission
[]
[]
(test/tests/neutronics/dagmc/with_csg/dag_lattice/openmc.i)
[Mesh]
[slab]
type = FileMeshGenerator
file = ../../mesh_tallies/slab.e
[]
allow_renumbering = false
parallel_type = replicated
[]
[AuxVariables]
[cell_temperature]
family = MONOMIAL
order = CONSTANT
[]
[]
[AuxKernels]
[cell_temperature]
type = CellTemperatureAux
variable = cell_temperature
[]
[]
[AuxKernels]
[temp]
type = ConstantAux
variable = temp
value = 500.0
execute_on = timestep_begin
[]
[]
[Problem]
type = OpenMCCellAverageProblem
verbose = true
temperature_blocks = '1 2'
cell_level = 1
power = 100.0
skinner = moab
[Tallies]
[Cell]
type = CellTally
block = '1 2'
[]
[]
[]
[UserObjects]
[moab]
type = MoabSkinner
temperature_min = 0.0
temperature_max = 1000.0
n_temperature_bins = 1
temperature = temp
build_graveyard = true
[]
[]
[Postprocessors]
[k]
type = KEigenvalue
[]
[]
[Executioner]
type = Transient
num_steps = 2
[]
[Outputs]
exodus = true
hide = 'temp'
[]
(test/tests/postprocessors/fission_tally_relative_error/openmc_dup.i)
[Mesh]
[sphere]
type = FileMeshGenerator
file = ../../neutronics/meshes/sphere.e
[]
[solid]
type = CombinerGenerator
inputs = sphere
positions = '0 0 0
0 0 4
0 0 8'
[]
[solid_ids]
type = SubdomainIDGenerator
input = solid
subdomain_id = '100'
[]
allow_renumbering = false
parallel_type = replicated
[]
[Problem]
type = OpenMCCellAverageProblem
power = 100.0
temperature_blocks = '100'
cell_level = 0
initial_properties = xml
[Tallies]
[Cell]
type = CellTally
block = '100'
check_tally_sum = false
[]
[Cell_2]
type = CellTally
block = '100'
score = 'heating'
check_tally_sum = false
[]
[Mesh]
type = MeshTally
name = 'mesh_kf'
mesh_template = '../../neutronics/meshes/sphere.e'
mesh_translations = '0 0 0
0 0 4
0 0 8'
check_tally_sum = false
[]
[]
[]
[Executioner]
type = Transient
num_steps = 1
[]
[Postprocessors]
[max_rel_err]
type = TallyRelativeError
tally_score = 'kappa_fission'
value_type = max
[]
[min_rel_err]
type = TallyRelativeError
tally_score = 'kappa_fission'
value_type = min
[]
[avg_rel_err]
type = TallyRelativeError
tally_score = 'kappa_fission'
value_type = average
[]
[]
[Outputs]
csv = true
[]
(test/tests/neutronics/tallies/reaction_rates/openmc_mgxs_rxn.i)
[Mesh]
[sphere]
type = FileMeshGenerator
file = ../../meshes/sphere.e
[]
[solid]
type = CombinerGenerator
inputs = sphere
positions = '0 0 0
0 0 4
0 0 8'
[]
[solid_ids]
type = SubdomainIDGenerator
input = solid
subdomain_id = '100'
[]
[fluid]
type = FileMeshGenerator
file = ../../heat_source/stoplight.exo
[]
[fluid_ids]
type = SubdomainIDGenerator
input = fluid
subdomain_id = '200'
[]
[combine]
type = CombinerGenerator
inputs = 'solid_ids fluid_ids'
[]
[]
[Problem]
type = OpenMCCellAverageProblem
verbose = true
source_strength = 1e6
temperature_blocks = '100 200'
density_blocks = '200'
cell_level = 0
initial_properties = xml
[Tallies]
[Cell]
type = CellTally
score = 'inverse_velocity nu_fission nu_scatter'
block = '100 200'
[]
[]
[]
[Executioner]
type = Steady
[]
[Postprocessors]
[total_nu_scatter]
type = ElementIntegralVariablePostprocessor
variable = nu_scatter
[]
[fluid_nu_scatter]
type = PointValue
variable = nu_scatter
point = '0.0 0.0 2.0'
[]
[pebble1_nu_scatter]
type = PointValue
variable = nu_scatter
point = '0.0 0.0 0.0'
[]
[pebble2_nu_scatter]
type = PointValue
variable = nu_scatter
point = '0.0 0.0 4.0'
[]
[pebble3_nu_scatter]
type = PointValue
variable = nu_scatter
point = '0.0 0.0 8.0'
[]
[max_err_nu_scatter]
type = TallyRelativeError
tally_score = 'nu_scatter'
[]
[total_nu_fission]
type = ElementIntegralVariablePostprocessor
variable = nu_fission
[]
[fluid_nu_fission]
type = PointValue
variable = nu_fission
point = '0.0 0.0 2.0'
[]
[pebble1_nu_fission]
type = PointValue
variable = nu_fission
point = '0.0 0.0 0.0'
[]
[pebble2_nu_fission]
type = PointValue
variable = nu_fission
point = '0.0 0.0 4.0'
[]
[pebble3_nu_fission]
type = PointValue
variable = nu_fission
point = '0.0 0.0 8.0'
[]
[max_err_nu_fission]
type = TallyRelativeError
tally_score = 'nu_fission'
[]
[total_inverse_velocity]
type = ElementIntegralVariablePostprocessor
variable = inverse_velocity
[]
[fluid_inverse_velocity]
type = PointValue
variable = inverse_velocity
point = '0.0 0.0 2.0'
[]
[pebble1_inverse_velocity]
type = PointValue
variable = inverse_velocity
point = '0.0 0.0 0.0'
[]
[pebble2_inverse_velocity]
type = PointValue
variable = inverse_velocity
point = '0.0 0.0 4.0'
[]
[pebble3_inverse_velocity]
type = PointValue
variable = inverse_velocity
point = '0.0 0.0 8.0'
[]
[max_err_inverse_velocity]
type = TallyRelativeError
tally_score = 'inverse_velocity'
[]
[]
[Outputs]
execute_on = final
csv = true
[]
(test/tests/neutronics/feedback/different_units/openmc_cm.i)
[Mesh]
type = FileMesh
file = sphere_in_cm.e
[]
[AuxVariables]
[cell_temperature]
family = MONOMIAL
order = CONSTANT
[]
[material_id]
family = MONOMIAL
order = CONSTANT
[]
[cell_density]
family = MONOMIAL
order = CONSTANT
[]
[]
[AuxKernels]
[material_id]
type = CellMaterialIDAux
variable = material_id
[]
[cell_temperature]
type = CellTemperatureAux
variable = cell_temperature
execute_on = 'timestep_end'
[]
[cell_density]
type = CellDensityAux
variable = cell_density
execute_on = 'timestep_end'
[]
[]
[Problem]
type = OpenMCCellAverageProblem
verbose = true
power = 1e6
temperature_blocks = '1'
density_blocks = '1'
cell_level = 0
[Tallies]
[Cell]
type = CellTally
block = '1'
name = 'heat_source'
[]
[]
[]
[Executioner]
type = Transient
[]
[Postprocessors]
[heat_source]
type = ElementIntegralVariablePostprocessor
variable = heat_source
[]
[]
[Outputs]
exodus = true
[]
(test/tests/postprocessors/eigenvalue/xml_directory/openmc.i)
[Mesh]
[sphere]
type = FileMeshGenerator
file = ../../../neutronics/meshes/sphere.e
[]
[solid]
type = CombinerGenerator
inputs = sphere
positions = '0 0 0
0 0 4
0 0 8'
[]
[solid_ids]
type = SubdomainIDGenerator
input = solid
subdomain_id = '100'
[]
[]
[Problem]
type = OpenMCCellAverageProblem
power = 100.0
temperature_blocks = '100'
cell_level = 0
xml_directory = './xml_settings/'
initial_properties = xml
[Tallies]
[Cell]
type = CellTally
block = '100'
check_tally_sum = false
[]
[]
[]
[Executioner]
type = Transient
num_steps = 1
[]
[Postprocessors]
[k_collision]
type = KEigenvalue
value_type = 'collision'
[]
[k_absorption]
type = KEigenvalue
value_type = 'absorption'
[]
[k_tracklength]
type = KEigenvalue
value_type = 'tracklength'
[]
[k_combined]
type = KEigenvalue
value_type = 'combined'
[]
[k_collision_std_dev]
type = KEigenvalue
output = 'std_dev'
value_type = 'collision'
[]
[k_absorption_std_dev]
type = KEigenvalue
output = 'std_dev'
value_type = 'absorption'
[]
[k_tracklength_std_dev]
type = KEigenvalue
output = 'std_dev'
value_type = 'tracklength'
[]
[k_combined_std_dev]
type = KEigenvalue
output = 'std_dev'
value_type = 'combined'
[]
[k_collision_rel]
type = KEigenvalue
output = 'rel_err'
value_type = 'collision'
[]
[k_absorption_rel]
type = KEigenvalue
output = 'rel_err'
value_type = 'absorption'
[]
[k_tracklength_rel]
type = KEigenvalue
output = 'rel_err'
value_type = 'tracklength'
[]
[k_combined_rel]
type = KEigenvalue
output = 'rel_err'
value_type = 'combined'
[]
[]
[Outputs]
csv = true
[]
(test/tests/neutronics/feedback/triso/cache/openmc.i)
l = 0.2
h = 1.0
[Mesh]
[solid]
type = GeneratedMeshGenerator
dim = 3
xmin = ${fparse -l / 2.0}
xmax = ${fparse l / 2.0}
ymin = ${fparse -l / 2.0}
ymax = ${fparse l / 2.0}
zmin = 0.0
zmax = ${h}
nx = 4
ny = 4
nz = 20
[]
[add_block]
type = ParsedSubdomainMeshGenerator
input = solid
combinatorial_geometry = 'z < ${fparse h / 2.0}'
block_id = 100
[]
[]
[ICs]
[temp]
type = FunctionIC
variable = temp
function = temp
[]
[]
[Functions]
[temp]
type = ParsedFunction
expression = 450.0
[]
[]
[Problem]
type = OpenMCCellAverageProblem
power = 100.0
scaling = 100.0
temperature_blocks = '0 100'
lowest_cell_level = 1
[Tallies]
[Cell]
type = CellTally
block = '0 100'
score = heating_local
[]
[]
[]
[Executioner]
type = Steady
[]
[Postprocessors]
[k]
type = KEigenvalue
[]
[]
[Outputs]
exodus = true
[]
(test/tests/neutronics/filters/filter_no_norm_score.i)
[Mesh]
[sphere]
type = FileMeshGenerator
file = ../meshes/sphere.e
[]
[solid]
type = CombinerGenerator
inputs = sphere
positions = '0 0 0
0 0 4
0 0 8'
[]
[solid_ids]
type = SubdomainIDGenerator
input = solid
subdomain_id = '100'
[]
[fluid]
type = FileMeshGenerator
file = ../heat_source/stoplight.exo
[]
[fluid_ids]
type = SubdomainIDGenerator
input = fluid
subdomain_id = '200'
[]
[combine]
type = CombinerGenerator
inputs = 'solid_ids fluid_ids'
[]
allow_renumbering = false
[]
[Problem]
type = OpenMCCellAverageProblem
verbose = true
power = 1e4
temperature_blocks = '100'
cell_level = 0
initial_properties = xml
source_rate_normalization = 'heating_local'
[Tallies]
[Flux]
type = CellTally
score = 'flux'
block = '100 200'
filters = 'Energy'
[]
[]
[Filters]
[Energy]
type = EnergyFilter
# CASMO 2 group structure for testing. May result in some missed particles
energy_boundaries = '0.0 6.25e-1 2.0e7'
[]
[]
[]
[Postprocessors]
[Pebble_1_Flux_g1]
type = PointValue
point = '0 0 0'
variable = flux_g1
[]
[Pebble_1_Flux_g2]
type = PointValue
point = '0 0 0'
variable = flux_g2
[]
[Pebble_1_Heat_g1]
type = PointValue
point = '0 0 0'
variable = heating_local_g1
[]
[Pebble_1_Heat_g2]
type = PointValue
point = '0 0 0'
variable = heating_local_g2
[]
[]
[Executioner]
type = Steady
[]
[Outputs]
csv = true
[]
(test/tests/userobjects/openmc_cell_transform/empty_cell_ids.i)
[Mesh]
[pin]
type = ConcentricCircleMeshGenerator
num_sectors = 6
radii = '1.0'
rings = '3 3'
has_outer_square = on
pitch = 4.0
preserve_volumes = yes
smoothing_max_it = 3
[]
[assembly]
type = CartesianIDPatternedMeshGenerator
inputs = 'pin'
pattern = '0 0;
0 0'
assign_type = 'cell'
id_name = 'pin_id'
[]
[delete]
# Only keeping block 1 (fuel pins) for this test
type = BlockDeletionGenerator
input = assembly
block = 2
[]
[extrude]
type = MeshExtruderGenerator
input = delete
extrusion_vector = '0 0 30'
[]
[translate]
type = TransformGenerator
input = extrude
transform = TRANSLATE_CENTER_ORIGIN
vector_value = '-12 12 0'
[]
[]
[GlobalParams]
displacements = 'disp_x disp_y disp_z'
use_displaced_mesh = true
[]
[Problem]
type = OpenMCCellAverageProblem
# Updating cell_level to 2 to account for the nested
# universes. Refer to OpenMCCellAverageProblem docs for more details.
cell_level = 2
verbose = true
power = 100
[Tallies]
[heat]
type = CellTally
score = 'kappa_fission'
block = '1'
[]
[]
[]
[AuxVariables]
[disp_x]
[AuxKernel]
type = FunctionAux
variable = disp_x
function = disp_x_fn
execute_on = 'timestep_begin'
[]
[]
[disp_y]
[AuxKernel]
type = FunctionAux
variable = disp_y
function = disp_y_fn
execute_on = 'timestep_begin'
[]
[]
[disp_z]
[]
[]
[Functions]
[disp_x_fn]
type = ParsedFunction
expression = '2*t'
[]
[disp_y_fn]
type = ParsedFunction
expression = '2*t'
[]
[]
[Postprocessors]
[shift_x]
type = FunctionValuePostprocessor
function = disp_x_fn
execute_on = 'timestep_begin'
[]
[shift_y]
type = FunctionValuePostprocessor
function = disp_y_fn
execute_on = 'timestep_begin'
[]
[k]
type = KEigenvalue
[]
[power]
type = ElementIntegralVariablePostprocessor
variable = kappa_fission
block = '1'
[]
[]
[UserObjects]
[translate_cells]
type = OpenMCCellTransform
transform_type = 'translation'
vector_value = 'shift_x shift_y 0'
cell_ids = ''
execute_on = 'timestep_begin'
[]
[]
[Executioner]
type = Transient
num_steps = 2
[]
[Outputs]
exodus = true
[]
(test/tests/neutronics/tally_system/multi_cell.i)
[Mesh]
[sphere]
type = FileMeshGenerator
file = ../meshes/sphere.e
[]
[solid]
type = CombinerGenerator
inputs = sphere
positions = '0 0 0
0 0 4
0 0 8'
[]
[solid_ids]
type = SubdomainIDGenerator
input = solid
subdomain_id = '100'
[]
[fluid]
type = FileMeshGenerator
file = ../heat_source/stoplight.exo
[]
[fluid_ids]
type = SubdomainIDGenerator
input = fluid
subdomain_id = '200'
[]
[combine]
type = CombinerGenerator
inputs = 'solid_ids fluid_ids'
[]
[]
[AuxVariables]
[cell_volume]
family = MONOMIAL
order = CONSTANT
[]
[]
[AuxKernels]
[cell_volume]
type = CellVolumeAux
variable = cell_volume
volume_type = mapped
[]
[]
[Problem]
type = OpenMCCellAverageProblem
verbose = true
power = 1e4
temperature_blocks = '100'
cell_level = 0
initial_properties = xml
source_rate_normalization = 'kappa_fission'
[Tallies]
[Cell_1]
type = CellTally
score = kappa_fission
block = '100 200'
[]
[Cell_2]
type = CellTally
score = flux
block = '100 200'
[]
[]
[]
[Postprocessors]
[Pebble_1_Vol]
type = PointValue
point = '0 0 0'
variable = cell_volume
[]
[Pebble_2_Vol]
type = PointValue
point = '0 0 4'
variable = cell_volume
[]
[Pebble_3_Vol]
type = PointValue
point = '0 0 8'
variable = cell_volume
[]
[Pebble_1_Heat]
type = PointValue
point = '0 0 0'
variable = kappa_fission
[]
[Pebble_2_Heat]
type = PointValue
point = '0 0 4'
variable = kappa_fission
[]
[Pebble_3_Heat]
type = PointValue
point = '0 0 8'
variable = kappa_fission
[]
[Pebble_1_Flux]
type = PointValue
point = '0 0 0'
variable = flux
[]
[Pebble_2_Flux]
type = PointValue
point = '0 0 4'
variable = flux
[]
[Pebble_3_Flux]
type = PointValue
point = '0 0 8'
variable = flux
[]
[]
[Executioner]
type = Steady
[]
[Outputs]
csv = true
[]
(test/tests/neutronics/dagmc/with_csg/multi_cell_dag/openmc.i)
[Mesh]
[slab]
type = FileMeshGenerator
file = ../../mesh_tallies/slab.e
[]
allow_renumbering = false
parallel_type = replicated
[]
[AuxVariables]
[cell_temperature]
family = MONOMIAL
order = CONSTANT
[]
[]
[AuxKernels]
[cell_temperature]
type = CellTemperatureAux
variable = cell_temperature
[]
[]
[AuxKernels]
[temp]
type = ConstantAux
variable = temp
value = 500.0
execute_on = timestep_begin
[]
[]
[Problem]
type = OpenMCCellAverageProblem
verbose = true
temperature_blocks = '1 2'
cell_level = 1
power = 100.0
skinner = moab
[Tallies]
[Cell]
type = CellTally
block = '1 2'
[]
[]
[]
[UserObjects]
[moab]
type = MoabSkinner
temperature_min = 0.0
temperature_max = 1000.0
n_temperature_bins = 1
temperature = temp
build_graveyard = true
[]
[]
[Postprocessors]
[k]
type = KEigenvalue
[]
[]
[Executioner]
type = Transient
num_steps = 2
[]
[Outputs]
exodus = true
hide = 'temp'
[]
(tutorials/gas_compact/openmc.i)
height = 1.60 # height of the unit cell (m)
fluid_Cp = 5189.0 # fluid isobaric specific heat (J/kg/K)
inlet_T = 598.0 # inlet fluid temperature (K)
power = 30e3 # unit cell power (W)
mdot = 0.011 # fluid mass flowrate (kg/s)
[Mesh]
[solid]
type = FileMeshGenerator
file = mesh_in.e
[]
[]
[AuxVariables]
[cell_temperature]
family = MONOMIAL
order = CONSTANT
[]
[]
[AuxKernels]
[cell_temperature]
type = CellTemperatureAux
variable = cell_temperature
[]
[]
[ICs]
[temp]
type = FunctionIC
variable = temp
function = temp_ic
[]
[]
[Functions]
[temp_ic]
type = ParsedFunction
expression = '${inlet_T} + z / ${height} * ${power} / ${mdot} / ${fluid_Cp}'
[]
[]
[Problem]
type = OpenMCCellAverageProblem
power = ${power}
scaling = 100.0
temperature_blocks = 'graphite compacts compacts_trimmer_tri'
cell_level = 1
[Tallies]
[heat_source]
type = CellTally
name = heat_source
block = 'compacts compacts_trimmer_tri'
check_equal_mapped_tally_volumes = true
output = 'unrelaxed_tally_std_dev'
[]
[]
[]
[MultiApps]
[solid]
type = TransientMultiApp
input_files = 'solid.i'
execute_on = timestep_end
[]
[]
[Transfers]
[heat_source_to_solid]
type = MultiAppGeneralFieldShapeEvaluationTransfer
to_multi_app = solid
variable = power
source_variable = heat_source
from_postprocessors_to_be_preserved = heat_source
to_postprocessors_to_be_preserved = power
[]
[temperature_to_openmc]
type = MultiAppGeneralFieldShapeEvaluationTransfer
from_multi_app = solid
variable = temp
source_variable = T
[]
[]
[Postprocessors]
[heat_source]
type = ElementIntegralVariablePostprocessor
variable = heat_source
execute_on = 'transfer initial timestep_end'
block = 'compacts compacts_trimmer_tri'
[]
[max_tally_rel_err]
type = TallyRelativeError
value_type = max
[]
[max_power]
type = ElementExtremeValue
variable = heat_source
value_type = max
block = 'compacts compacts_trimmer_tri'
[]
[min_power]
type = ElementExtremeValue
variable = heat_source
value_type = min
block = 'compacts compacts_trimmer_tri'
[]
[]
[UserObjects]
[avg_power]
type = NearestPointLayeredAverage
variable = heat_source
points = '0.0 0.0 0.0'
num_layers = 30
direction = z
block = 'compacts compacts_trimmer_tri'
[]
[avg_std_dev]
type = NearestPointLayeredAverage
variable = heat_source_std_dev
points = '0.0 0.0 0.0'
num_layers = 30
direction = z
block = 'compacts compacts_trimmer_tri'
[]
[]
[VectorPostprocessors]
[avg_q]
type = SpatialUserObjectVectorPostprocessor
userobject = avg_power
[]
[stdev]
type = SpatialUserObjectVectorPostprocessor
userobject = avg_std_dev
[]
[]
[Executioner]
type = Transient
num_steps = 4
[]
[Outputs]
exodus = true
csv = true
[]
(test/tests/openmc_errors/tallies/length.i)
[Mesh]
[sphere]
type = FileMeshGenerator
file = ../../neutronics/meshes/sphere.e
[]
[]
[Problem]
type = OpenMCCellAverageProblem
power = 100.0
cell_level = 0
[Tallies]
[Cell]
type = CellTally
block = '1'
[]
[]
[]
[Executioner]
type = Transient
[]
(test/tests/neutronics/gen_mgxs/mgxs_aux/mg_diffusion_coeff.i)
[Mesh]
[sphere]
type = FileMeshGenerator
file = ../../meshes/sphere.e
[]
[solid1]
type = SubdomainIDGenerator
input = sphere
subdomain_id = '100'
[]
allow_renumbering = false
[]
[AuxVariables]
[diff_g1]
type = MooseVariable
order = CONSTANT
family = MONOMIAL
[]
[zero_flux]
type = MooseVariable
order = CONSTANT
family = MONOMIAL
initial_condition = '0.0'
[]
[]
[AuxKernels]
[comp_diff_g1]
type = ComputeDiffusionCoeffMGAux
variable = diff_g1
total_rxn_rate = 'total_g1'
p1_scatter_rxn_rates = 'nu_scatter_g1_gp1_l1 nu_scatter_g2_gp1_l1'
scalar_flux = 'flux_g1'
[]
[]
[Problem]
type = OpenMCCellAverageProblem
initial_properties = xml
verbose = true
cell_level = 0
power = 1.0
source_rate_normalization = 'kappa_fission'
[Tallies]
[Cell_KF]
type = CellTally
score = 'kappa_fission'
block = '100'
normalize_by_global_tally = false
[]
[Cell_Total_Flux]
type = CellTally
score = 'total flux'
block = '100'
filters = 'Energy'
normalize_by_global_tally = false
[]
[Cell_Scatter]
type = CellTally
score = 'nu_scatter'
block = '100'
filters = 'Energy EnergyOut Legendre'
estimator = 'analog'
normalize_by_global_tally = false
[]
[]
[Filters]
[Energy]
type = EnergyFilter
energy_boundaries = '0.0 6.25e-1 2.0e7'
reverse_bins = true
[]
[EnergyOut]
type = EnergyOutFilter
energy_boundaries = '0.0 6.25e-1 2.0e7'
reverse_bins = true
[]
[Legendre]
type = AngularLegendreFilter
order = 1
[]
[]
[]
[Executioner]
type = Steady
[]
[Postprocessors]
[result]
type = PointValue
point = '0 0 0'
variable = diff_g1
[]
[]
[Outputs]
execute_on = final
csv = true
[]
(test/tests/userobjects/openmc_nuclide_densities/openmc.i)
[Mesh]
[g]
type = GeneratedMeshGenerator
dim = 3
nx = 8
ny = 8
nz = 8
xmin = -12.5
xmax = 87.5
ymin = -12.5
ymax = 37.5
zmin = -12.5
zmax = 12.5
[]
[]
[ICs]
[temp]
type = ConstantIC
variable = temp
value = 500.0
[]
[]
[Problem]
type = OpenMCCellAverageProblem
verbose = true
temperature_blocks = '0'
cell_level = 0
power = 100.0
initial_properties = xml
[Tallies]
[Cell]
type = CellTally
block = '0'
[]
[]
[]
[UserObjects]
[mat1]
type = OpenMCNuclideDensities
material_id = 1
names = 'U235 U238'
densities = '0.01 0.02'
[]
[]
[Postprocessors]
[k]
type = KEigenvalue
[]
[]
[Executioner]
type = Steady
[]
[Outputs]
csv = true
[]
(test/tests/openmc_errors/block_mappings/unequal_volumes.i)
[Mesh]
[sphere]
# Mesh of a single pebble with outer radius of 1.5 (cm)
type = FileMeshGenerator
file = ../../neutronics/meshes/sphere.e
[]
[sphere_shrunken]
# Mesh of a single pebble with outer radius of 1.4 (cm) - this approximates
# the effect of an OpenMC model have equal cell tally volumes but not mapping
# to identical volumes in the [Mesh]
type = TransformGenerator
input = sphere
transform = SCALE
vector_value = '0.93 0.93 0.93'
[]
[solid]
type = CombinerGenerator
inputs = 'sphere sphere_shrunken sphere'
positions = '0 0 0
0 0 4
0 0 8'
[]
[solid_ids]
type = SubdomainIDGenerator
input = solid
subdomain_id = '100'
[]
[]
[Problem]
type = OpenMCCellAverageProblem
power = 70.0
temperature_blocks = '100'
verbose = true
cell_level = 0
[Tallies]
[Cell]
type = CellTally
block = '100'
check_equal_mapped_tally_volumes = true
[]
[]
[]
[Executioner]
type = Transient
num_steps = 1
[]
[Outputs]
exodus = true
[]
(test/tests/neutronics/dagmc/density_skin/only_solid.i)
[Mesh]
type = FileMesh
file = ../mesh_tallies/slab.e
allow_renumbering = false
[]
[AuxVariables]
[density]
family = MONOMIAL
order = CONSTANT
[]
[]
[Problem]
type = OpenMCCellAverageProblem
verbose = true
initial_properties = xml
temperature_blocks = '1 2'
cell_level = 0
power = 100.0
skinner = moab
[Tallies]
[Mesh]
type = CellTally
block = '1 2'
[]
[]
[]
[UserObjects]
[moab]
type = MoabSkinner
# just one temperature bin
temperature_min = 0.0
temperature_max = 1000.0
n_temperature_bins = 1
temperature = temp
density_min = 0.0
density_max = 100.0
n_density_bins = 4
density = density
build_graveyard = true
[]
[]
[Executioner]
type = Steady
[]
(test/tests/neutronics/axisymmetric/openmc.i)
[Mesh]
[gen]
type = GeneratedMeshGenerator
dim = 2
xmin = 0.0
xmax = 0.39218
ymin = 0.0
ymax = 1.0
nx = 5
ny = 20
[]
coord_type = RZ
rz_coord_axis = Y
[]
[AuxVariables]
[cell_volume_moose]
family = MONOMIAL
order = CONSTANT
[]
[cell_volume_openmc]
family = MONOMIAL
order = CONSTANT
[]
[]
[AuxKernels]
[cell_volume_moose]
type = CellVolumeAux
variable = cell_volume_moose
volume_type = mapped
[]
[cell_volume_openmc]
type = CellVolumeAux
variable = cell_volume_openmc
volume_type = actual
[]
[]
[Problem]
type = OpenMCCellAverageProblem
cell_level = 0
power = 50
volume_calculation = vol
verbose = true
[Tallies]
[p]
type = CellTally
[]
[]
[]
[UserObjects]
[vol]
type = OpenMCVolumeCalculation
n_samples = 1000000
[]
[]
[Executioner]
type = Steady
[]
[Outputs]
exodus = true
[]
[Postprocessors]
[power]
type = ElementIntegralVariablePostprocessor
variable = kappa_fission
[]
[total_volume] # computes in cylindrical correctly (0.483193)
type = VolumePostprocessor
[]
[]
(test/tests/openmc_errors/block_mappings/nonexistent_block.i)
[Mesh]
[sphere]
type = FileMeshGenerator
file = ../../neutronics/meshes/sphere.e
[]
[solid]
type = CombinerGenerator
inputs = sphere
positions = '0 0 0
0 0 4
0 0 8'
[]
[solid_ids]
type = SubdomainIDGenerator
input = solid
subdomain_id = '100'
[]
[fluid]
type = FileMeshGenerator
file = stoplight.exo
[]
[fluid_ids]
type = SubdomainIDGenerator
input = fluid
subdomain_id = '200'
[]
[combine]
type = CombinerGenerator
inputs = 'solid_ids fluid_ids'
[]
[]
[Problem]
type = OpenMCCellAverageProblem
power = 70.0
cell_level = 0
[Tallies]
[Cell]
type = CellTally
block = '100 200 who'
[]
[]
[]
[Executioner]
type = Transient
[]
[Outputs]
exodus = true
[]
(test/tests/neutronics/moving_mesh/cell_tally.i)
[GlobalParams]
use_displaced_mesh = true
displacements = 'disp_x disp_y disp_z'
[]
[Mesh]
[f]
type = GeneratedMeshGenerator
dim = 3
xmin = -0.05
xmax = 0.15
ymin = -0.05
ymax = 0.05
zmin = -0.05
zmax = 0.05
nx = 20
ny = 1
nz = 1
[]
[subdomains]
type = ParsedSubdomainIDsGenerator
input = f
expression = 'if (x < 0.05, 1, 2)'
[]
[name]
type = RenameBlockGenerator
input = subdomains
old_block = '1 2'
new_block = 'left right'
[]
[rescale]
type = TransformGenerator
input = name
transform = scale
vector_value = '100.0 100.0 100.0'
[]
[]
[Problem]
type = OpenMCCellAverageProblem
cell_level = 0
verbose = true
power = 1
[Tallies]
[heat]
type = CellTally
score = 'kappa_fission'
block = 'left right'
[]
[]
[]
[AuxVariables]
[disp_x]
[]
[disp_y]
[]
[disp_z]
[]
[]
[AuxKernels]
[disp_x] # gets called for the first time after [Problem]
type = FunctionAux
variable = disp_x
function = disp_x
[]
[]
[Functions]
[disp_x]
type = ParsedFunction
expression = '2.0'
[]
[]
[Postprocessors]
[power]
type = ElementIntegralVariablePostprocessor
variable = kappa_fission
[]
[]
[Executioner]
type = Transient
num_steps = 2
[]
[Outputs]
exodus = true
[]
(test/tests/neutronics/dagmc/with_csg/mixed_feedback/openmc.i)
[Mesh]
[slab]
type = FileMeshGenerator
file = ../../mesh_tallies/slab.e
[]
[cube]
type = FileMeshGenerator
file = ../../../meshes/tet_cube.e
[]
[rename_cube]
type = RenameBlockGenerator
input = cube
old_block = '1'
new_block = '3'
[]
[combine]
type = CombinerGenerator
inputs = 'slab rename_cube'
positions = '0 0 0 0 50 0'
[]
allow_renumbering = false
parallel_type = replicated
[]
[AuxVariables]
[cell_temperature]
family = MONOMIAL
order = CONSTANT
[]
[]
[AuxKernels]
[cell_temperature]
type = CellTemperatureAux
variable = cell_temperature
[]
[]
[AuxKernels]
[temp]
type = ConstantAux
variable = temp
value = 500.0
execute_on = timestep_begin
[]
[]
[Problem]
type = OpenMCCellAverageProblem
verbose = true
temperature_blocks = '1 2 3'
cell_level = 0
power = 100.0
skinner = moab
[Tallies]
[Cell]
type = CellTally
block = '1 2 3'
[]
[]
[]
[UserObjects]
[moab]
type = MoabSkinner
temperature_min = 0.0
temperature_max = 1000.0
n_temperature_bins = 1
temperature = temp
build_graveyard = true
[]
[]
[Postprocessors]
[k]
type = KEigenvalue
[]
[]
[Executioner]
type = Transient
num_steps = 2
[]
[Outputs]
exodus = true
hide = 'temp'
[]
(test/tests/neutronics/heat_source/mapping_solid.i)
[Mesh]
[sphere]
type = FileMeshGenerator
file = ../meshes/sphere.e
[]
[solid]
type = CombinerGenerator
inputs = sphere
positions = '0 0 0
0 0 4
0 0 8'
[]
[solid_ids]
type = SubdomainIDGenerator
input = solid
subdomain_id = '100'
[]
[fluid]
type = FileMeshGenerator
file = stoplight.exo
[]
[fluid_ids]
type = SubdomainIDGenerator
input = fluid
subdomain_id = '200'
[]
[combine]
type = CombinerGenerator
inputs = 'solid_ids fluid_ids'
[]
[]
[Problem]
type = OpenMCCellAverageProblem
power = 100.0
temperature_blocks = '100 200'
density_blocks = '200'
initial_properties = xml
verbose = true
cell_level = 0
[Tallies]
[Cell]
type = CellTally
name = heat_source
# This input has fissile material in the fluid phase, so we will get a warning
# that we are neglecting some of the global kappa-fission distribution; so here
# the power is the total power of the OpenMC problem, and only a fraction of this
# will be computed in the solid pebbles
block = '100'
# We are skipping some feedback with fissile regions, so we need to turn off the check
check_tally_sum = false
[]
[]
[]
[Executioner]
type = Steady
[]
[Postprocessors]
[solid_heat_source]
type = ElementIntegralVariablePostprocessor
variable = heat_source
block = '100'
[]
[]
[Outputs]
exodus = true
csv = true
hide = 'density'
[]
(test/tests/neutronics/output/cell.i)
[Mesh]
[sphere]
type = FileMeshGenerator
file = ../meshes/sphere.e
[]
[solid]
type = CombinerGenerator
inputs = sphere
positions = '0 0 0
0 0 4
0 0 8'
[]
[solid_ids]
type = SubdomainIDGenerator
input = solid
subdomain_id = '100'
[]
[fluid]
type = FileMeshGenerator
file = ../heat_source/stoplight.exo
[]
[fluid_ids]
type = SubdomainIDGenerator
input = fluid
subdomain_id = '200'
[]
[combine]
type = CombinerGenerator
inputs = 'solid_ids fluid_ids'
[]
[]
[Problem]
type = OpenMCCellAverageProblem
verbose = true
source_strength = 1e6
temperature_blocks = '100 200'
density_blocks = '200'
cell_level = 0
initial_properties = xml
[Tallies]
[Cell]
type = CellTally
score = 'flux'
block = '100 200'
output = 'unrelaxed_tally'
[]
[]
[]
[Executioner]
type = Steady
[]
[Postprocessors]
[total_flux]
type = ElementIntegralVariablePostprocessor
variable = flux_raw
[]
[]
[Outputs]
execute_on = final
csv = true
[]
(test/tests/neutronics/tally_system/same_scores.i)
[Mesh]
[sphere]
type = FileMeshGenerator
file = ../meshes/sphere.e
[]
[solid]
type = CombinerGenerator
inputs = sphere
positions = '0 0 0
0 0 4
0 0 8'
[]
[solid_ids]
type = SubdomainIDGenerator
input = solid
subdomain_id = '100'
[]
[fluid]
type = FileMeshGenerator
file = ../heat_source/stoplight.exo
[]
[fluid_ids]
type = SubdomainIDGenerator
input = fluid
subdomain_id = '200'
[]
[combine]
type = CombinerGenerator
inputs = 'solid_ids fluid_ids'
[]
allow_renumbering = false
parallel_type = replicated
[]
[Problem]
type = OpenMCCellAverageProblem
verbose = true
power = 1e4
cell_level = 0
source_rate_normalization = 'kappa_fission'
[Tallies]
[Cell]
type = CellTally
score = 'kappa_fission'
name = 'cell_kappa_fission'
block = '100 200'
normalize_by_global_tally = true
[]
[Mesh]
type = MeshTally
score = 'kappa_fission flux'
name = 'mesh_kappa_fission mesh_flux'
# The global tally check is disabled because we have a loosely fitting unstructured mesh tally.
normalize_by_global_tally = false
[]
[]
[]
[Executioner]
type = Steady
[]
[Postprocessors]
[max_mesh_flux]
type = ElementExtremeValue
variable = mesh_flux
value_type = 'max'
[]
[max_mesh_kf]
type = ElementExtremeValue
variable = mesh_kappa_fission
value_type = 'max'
[]
[max_cell_kf]
type = ElementExtremeValue
variable = cell_kappa_fission
value_type = 'max'
[]
[]
[Outputs]
execute_on = 'TIMESTEP_END'
csv = true
[]
(test/tests/neutronics/dagmc/cell_tallies/one_bin.i)
[Mesh]
type = FileMesh
file = ../mesh_tallies/slab.e
allow_renumbering = false
[]
[AuxVariables]
[cell_temperature]
family = MONOMIAL
order = CONSTANT
[]
[]
[AuxKernels]
[cell_temperature]
type = CellTemperatureAux
variable = cell_temperature
[]
[]
[AuxKernels]
[temp]
type = ConstantAux
variable = temp
value = 500.0
execute_on = timestep_begin
[]
[]
[Problem]
type = OpenMCCellAverageProblem
verbose = true
temperature_blocks = '1 2'
cell_level = 0
power = 100.0
skinner = moab
[Tallies]
[Cell]
type = CellTally
block = '1 2'
[]
[]
[]
[UserObjects]
[moab]
type = MoabSkinner
temperature_min = 0.0
temperature_max = 1000.0
n_temperature_bins = 1
temperature = temp
build_graveyard = true
[]
[]
[Postprocessors]
[k]
type = KEigenvalue
[]
[]
[Executioner]
type = Transient
num_steps = 2
[]
[Outputs]
exodus = true
hide = 'temp cell_instance'
[]
(test/tests/neutronics/filters/sh/openmc_l1_mult.i)
[Mesh]
[sphere]
type = FileMeshGenerator
file = ../../meshes/sphere.e
[]
[solid]
type = CombinerGenerator
inputs = sphere
positions = '0 0 0
0 0 4
0 0 8'
[]
[solid_ids]
type = SubdomainIDGenerator
input = solid
subdomain_id = '100'
[]
[fluid]
type = FileMeshGenerator
file = ../../heat_source/stoplight.exo
[]
[fluid_ids]
type = SubdomainIDGenerator
input = fluid
subdomain_id = '200'
[]
[combine]
type = CombinerGenerator
inputs = 'solid_ids fluid_ids'
[]
allow_renumbering = false
[]
[Problem]
type = OpenMCCellAverageProblem
verbose = true
power = 1e4
temperature_blocks = '100'
cell_level = 0
initial_properties = xml
source_rate_normalization = 'kappa_fission'
[Tallies]
[Heating]
type = CellTally
score = 'kappa_fission'
block = '100 200'
[]
[Flux]
type = CellTally
score = 'flux'
block = '100 200'
filters = 'Energy SH'
[]
[]
[Filters]
[Energy]
type = EnergyFilter
# CASMO 2 group structure for testing. May result in some missed particles
energy_boundaries = '0.0 6.25e-1 2.0e7'
[]
[SH]
type = SphericalHarmonicsFilter
order = 1
[]
[]
[]
[Postprocessors]
[Pebble_1_Flux_g1_l0_m0]
type = PointValue
point = '0 0 0'
variable = flux_g1_l0_mpos0
[]
[Pebble_1_Flux_g2_l0_m0]
type = PointValue
point = '0 0 0'
variable = flux_g2_l0_mpos0
[]
[Pebble_1_Flux_g1_l1_m1]
type = PointValue
point = '0 0 0'
variable = flux_g1_l1_mpos1
[]
[Pebble_1_Flux_g2_l1_m1]
type = PointValue
point = '0 0 0'
variable = flux_g2_l1_mpos1
[]
[Pebble_1_Flux_g1_l1_mn1]
type = PointValue
point = '0 0 0'
variable = flux_g1_l1_mneg1
[]
[Pebble_1_Flux_g2_l1_mn1]
type = PointValue
point = '0 0 0'
variable = flux_g2_l1_mneg1
[]
[]
[Executioner]
type = Steady
[]
[Outputs]
csv = true
[]
(test/tests/neutronics/feedback/multiple_levels/openmc.i)
[Mesh]
[pincell]
type = FileMeshGenerator
file = ../../meshes/pincell.e
[]
[delete_block]
type = BlockDeletionGenerator
input = pincell
block = 2
[]
[add_surrounding]
type = FileMeshGenerator
file = surrounding.e
[]
[translate_surrounding]
type = TransformGenerator
input = add_surrounding
transform = translate
vector_value = '0.0 0.0 5.0'
[]
[combine]
type = CombinerGenerator
inputs = 'delete_block translate_surrounding'
[]
[]
[AuxVariables]
[cell_temperature]
family = MONOMIAL
order = CONSTANT
[]
[]
[AuxKernels]
[cell_temperature]
type = CellTemperatureAux
variable = cell_temperature
execute_on = 'timestep_end'
[]
[]
[Problem]
type = OpenMCCellAverageProblem
power = 500.0
# In the OpenMC model script, we set the fuel temperature to 500, the clad temperature
# to 450, and the exterior temperature to 300. Checking that the temperatures obtained with
# CellTemperatureAux match these values will confirm that the correct cell level is
# fetched in the exterior region, which is at a level of 0 (greater than the lowest_cell_level).
initial_properties = xml
# block 5 should map to an OpenMC region on level 0 in the geometry; by setting
# the lowest cell level, we will just map to level 0 in this region instead of 1.
temperature_blocks = '1 3 5'
lowest_cell_level = 1
verbose = true
[Tallies]
[Cell]
type = CellTally
block = '1'
[]
[]
[]
[Executioner]
type = Transient
num_steps = 1
[]
[Outputs]
exodus = true
# makes the gold files smaller, since these are not of concern for the test
hide = 'temp kappa_fission'
[]
(test/tests/neutronics/dagmc/density_skin/csg_step_2/openmc.i)
[Mesh]
type = FileMesh
file = ../../mesh_tallies/slab.e
[]
x0 = 12.5
x1 = 37.5
x2 = 62.5
[AuxVariables]
[cell_temperature]
family = MONOMIAL
order = CONSTANT
[]
[material_id]
family = MONOMIAL
order = CONSTANT
[]
[cell_density]
family = MONOMIAL
order = CONSTANT
[]
[]
[AuxKernels]
[cell_temperature]
type = CellTemperatureAux
variable = cell_temperature
[]
[material_id]
type = CellMaterialIDAux
variable = material_id
[]
[cell_density]
type = CellDensityAux
variable = cell_density
[]
[]
T0 = 600.0
dT = 50.0
[Functions]
[density]
type = ParsedFunction
expression = 'if (x <= ${x0}, ${fparse T0 - dT}, if (x <= ${x1}, ${T0}, if (x <= ${x2}, ${fparse T0 + dT}, ${fparse T0 + 2 * dT})))'
[]
[]
[ICs]
[temp]
type = ConstantIC
variable = temp
value = 500.0
[]
[]
[AuxKernels]
[density]
type = FunctionAux
variable = density
function = density
execute_on = timestep_begin
[]
[]
[Problem]
type = OpenMCCellAverageProblem
verbose = true
temperature_blocks = '1 2'
density_blocks = '1 2'
cell_level = 0
power = 100.0
[Tallies]
[Mesh]
type = CellTally
block = '1 2'
[]
[]
[]
[Postprocessors]
[k]
type = KEigenvalue
[]
[]
[Executioner]
type = Transient
num_steps = 2
[]
[Outputs]
exodus = true
[]
(test/tests/neutronics/tallies/reaction_rates/openmc_delayed_rxn.i)
[Mesh]
[sphere]
type = FileMeshGenerator
file = ../../meshes/sphere.e
[]
[solid]
type = CombinerGenerator
inputs = sphere
positions = '0 0 0
0 0 4
0 0 8'
[]
[solid_ids]
type = SubdomainIDGenerator
input = solid
subdomain_id = '100'
[]
[fluid]
type = FileMeshGenerator
file = ../../heat_source/stoplight.exo
[]
[fluid_ids]
type = SubdomainIDGenerator
input = fluid
subdomain_id = '200'
[]
[combine]
type = CombinerGenerator
inputs = 'solid_ids fluid_ids'
[]
[]
[Problem]
type = OpenMCCellAverageProblem
verbose = true
source_strength = 1e6
temperature_blocks = '100 200'
density_blocks = '200'
cell_level = 0
initial_properties = xml
[Tallies]
[Cell]
type = CellTally
score = 'prompt_nu_fission delayed_nu_fission decay_rate'
block = '100 200'
[]
[]
[]
[Executioner]
type = Steady
[]
[Postprocessors]
[total_prompt_nu_fission]
type = ElementIntegralVariablePostprocessor
variable = prompt_nu_fission
[]
[fluid_prompt_nu_fission]
type = PointValue
variable = prompt_nu_fission
point = '0.0 0.0 2.0'
[]
[pebble1_prompt_nu_fission]
type = PointValue
variable = prompt_nu_fission
point = '0.0 0.0 0.0'
[]
[pebble2_prompt_nu_fission]
type = PointValue
variable = prompt_nu_fission
point = '0.0 0.0 4.0'
[]
[pebble3_prompt_nu_fission]
type = PointValue
variable = prompt_nu_fission
point = '0.0 0.0 8.0'
[]
[max_err_prompt_nu_fission]
type = TallyRelativeError
tally_score = 'prompt_nu_fission'
[]
[total_delayed_nu_fission]
type = ElementIntegralVariablePostprocessor
variable = delayed_nu_fission
[]
[fluid_delayed_nu_fission]
type = PointValue
variable = delayed_nu_fission
point = '0.0 0.0 2.0'
[]
[pebble1_delayed_nu_fission]
type = PointValue
variable = delayed_nu_fission
point = '0.0 0.0 0.0'
[]
[pebble2_delayed_nu_fission]
type = PointValue
variable = delayed_nu_fission
point = '0.0 0.0 4.0'
[]
[pebble3_delayed_nu_fission]
type = PointValue
variable = delayed_nu_fission
point = '0.0 0.0 8.0'
[]
[max_err_delayed_nu_fission]
type = TallyRelativeError
tally_score = 'delayed_nu_fission'
[]
[total_decay_rate]
type = ElementIntegralVariablePostprocessor
variable = decay_rate
[]
[fluid_decay_rate]
type = PointValue
variable = decay_rate
point = '0.0 0.0 2.0'
[]
[pebble1_decay_rate]
type = PointValue
variable = decay_rate
point = '0.0 0.0 0.0'
[]
[pebble2_decay_rate]
type = PointValue
variable = decay_rate
point = '0.0 0.0 4.0'
[]
[pebble3_decay_rate]
type = PointValue
variable = decay_rate
point = '0.0 0.0 8.0'
[]
[max_err_decay_rate]
type = TallyRelativeError
tally_score = 'decay_rate'
[]
[]
[Outputs]
execute_on = final
csv = true
[]
(test/tests/neutronics/source/openmc.i)
[Mesh]
[file]
type = FileMeshGenerator
file = mesh_in.e
[]
[]
[ICs]
[temp]
type = ConstantIC
variable = temp
value = 600.0
[]
[]
[Problem]
type = OpenMCCellAverageProblem
power = ${fparse 3000e6 / 273 / (17 * 17)}
temperature_blocks = '1 2 3'
cell_level = 0
reuse_source = true
[Tallies]
[Cell]
type = CellTally
block = '2 3'
[]
[]
[]
[Executioner]
type = Transient
num_steps = 3
[]
[Outputs]
exodus = true
[]
(test/tests/neutronics/relaxation/cell_tallies/openmc.i)
[Mesh]
[pebble]
type = FileMeshGenerator
file = ../../meshes/sphere_in_m.e
[]
[repeat]
type = CombinerGenerator
inputs = pebble
positions = '0 0 0.02
0 0 0.06
0 0 0.10'
[]
[set_block_ids]
type = SubdomainIDGenerator
input = repeat
subdomain_id = 0
[]
[]
[AuxKernels]
[temp]
type = FunctionAux
variable = temp
function = axial
execute_on = initial
[]
[]
[Functions]
[axial]
type = ParsedFunction
expression = '500 + z / 0.10 * 100'
[]
[]
[Problem]
type = OpenMCCellAverageProblem
verbose = true
power = 100.0
temperature_blocks = '0'
cell_level = 1
scaling = 100.0
volume_calculation = vol
[Tallies]
[Cell]
type = CellTally
block = '0'
[]
[]
[]
[UserObjects]
[vol]
type = OpenMCVolumeCalculation
n_samples = 1000
[]
[]
[Executioner]
type = Transient
num_steps = 3
[]
[Outputs]
csv = true
exodus = true
[]
[Postprocessors]
[heat_source]
type = ElementIntegralVariablePostprocessor
variable = kappa_fission
[]
[p1]
type = PointValue
variable = kappa_fission
point = '0.0 0.0 0.02'
[]
[p2]
type = PointValue
variable = kappa_fission
point = '0.0 0.0 0.06'
[]
[p3]
type = PointValue
variable = kappa_fission
point = '0.0 0.0 0.10'
[]
[]
(test/tests/neutronics/feedback/lattice/openmc.i)
[Mesh]
type = FileMesh
file = ../../meshes/pincell.e
[]
[AuxVariables]
[cell_temperature]
family = MONOMIAL
order = CONSTANT
[]
[material_id]
family = MONOMIAL
order = CONSTANT
[]
[cell_density]
family = MONOMIAL
order = CONSTANT
[]
[]
[AuxKernels]
[material_id]
type = CellMaterialIDAux
variable = material_id
[]
[cell_temperature]
type = CellTemperatureAux
variable = cell_temperature
execute_on = 'timestep_end'
[]
[cell_density]
type = CellDensityAux
variable = cell_density
execute_on = 'timestep_end'
[]
[]
[Problem]
type = OpenMCCellAverageProblem
verbose = true
power = 500.0
temperature_blocks = '1 2 3'
density_blocks = '2'
cell_level = 1
[Tallies]
[Cell]
type = CellTally
block = '1 2 3'
name = heat_source
[]
[]
[]
[Executioner]
type = Transient
[]
[Postprocessors]
[heat_source]
type = ElementIntegralVariablePostprocessor
variable = heat_source
block = '1 2 3'
[]
[fluid_heat_source]
type = ElementIntegralVariablePostprocessor
variable = heat_source
block = '2'
[]
[solid_heat_source]
type = ElementIntegralVariablePostprocessor
variable = heat_source
block = '1 3'
[]
[]
[Outputs]
exodus = true
[]
(test/tests/controls/openmc_nuclide_densities/openmc.i)
[Mesh]
[g]
type = GeneratedMeshGenerator
dim = 3
nx = 8
ny = 8
nz = 8
xmin = -12.5
xmax = 87.5
ymin = -12.5
ymax = 37.5
zmin = -12.5
zmax = 12.5
[]
[]
[Problem]
type = OpenMCCellAverageProblem
verbose = true
cell_level = 0
power = 100.0
[Tallies]
[Cell]
type = CellTally
block = 0
[]
[]
[]
[UserObjects]
[mat1]
type = OpenMCNuclideDensities
material_id = 2
names = 'U235 U238'
# dummy values which do not get set, because the control will override these
densities = '0.0 0.0'
[]
[]
[Controls]
[c]
type = OpenMCNuclideDensitiesControl
user_object = mat1
names = 'U235 U238'
densities = '0.03 0.09'
[]
[]
[Postprocessors]
[k]
type = KEigenvalue
[]
[]
[Executioner]
type = Transient
num_steps = 1
[]
[Outputs]
csv = true
[]
(test/tests/openmc_errors/densities/zero_density.i)
[Mesh]
type = GeneratedMesh
dim = 3
xmin = -2
xmax = 2
ymin = -2
ymax = 2
zmin = -2
zmax = 10
nx = 5
ny = 5
nz = 5
[]
[AuxVariables]
[dummy]
[]
[]
[AuxKernels]
[dummy]
type = ConstantAux
variable = dummy
value = 0.0
[]
[]
[ICs]
[temp]
type = ConstantIC
variable = temp
value = 500.0
[]
[]
[Problem]
type = OpenMCCellAverageProblem
power = 100.0
temperature_blocks = '0'
density_blocks = '0'
verbose = true
cell_level = 0
[Tallies]
[Cell]
type = CellTally
block = '0'
[]
[]
[]
[Executioner]
type = Transient
num_steps = 1
[]
[Outputs]
exodus = true
[]
(test/tests/neutronics/filters/legendre/cell_l0_from_l1.i)
[Mesh]
[sphere]
type = FileMeshGenerator
file = ../../meshes/sphere.e
[]
[solid]
type = CombinerGenerator
inputs = sphere
positions = '0 0 0
0 0 4
0 0 8'
[]
[solid_ids]
type = SubdomainIDGenerator
input = solid
subdomain_id = '100'
[]
[fluid]
type = FileMeshGenerator
file = ../../heat_source/stoplight.exo
[]
[fluid_ids]
type = SubdomainIDGenerator
input = fluid
subdomain_id = '200'
[]
[combine]
type = CombinerGenerator
inputs = 'solid_ids fluid_ids'
[]
allow_renumbering = false
[]
[Problem]
type = OpenMCCellAverageProblem
verbose = true
power = 1e4
temperature_blocks = '100'
cell_level = 0
initial_properties = xml
source_rate_normalization = 'kappa_fission'
[Tallies]
[Heating]
type = CellTally
score = 'kappa_fission'
block = '100 200'
[]
[Scattering]
type = CellTally
score = 'scatter'
block = '100 200'
filters = 'Legendre'
estimator = 'analog'
[]
[]
[Filters]
[Legendre]
type = AngularLegendreFilter
order = 1
[]
[]
[]
[Postprocessors]
[Pebble_1_scatter_l0]
type = PointValue
point = '0 0 0'
variable = scatter_l0
[]
[Pebble_2_scatter_l0]
type = PointValue
point = '0 0 4'
variable = scatter_l0
[]
[Pebble_3_scatter_l0]
type = PointValue
point = '0 0 8'
variable = scatter_l0
[]
[]
[Executioner]
type = Steady
[]
[Outputs]
csv = true
[]
(test/tests/neutronics/filters/no_filter.i)
[Mesh]
[sphere]
type = FileMeshGenerator
file = ../meshes/sphere.e
[]
[solid]
type = CombinerGenerator
inputs = sphere
positions = '0 0 0
0 0 4
0 0 8'
[]
[solid_ids]
type = SubdomainIDGenerator
input = solid
subdomain_id = '100'
[]
[fluid]
type = FileMeshGenerator
file = ../heat_source/stoplight.exo
[]
[fluid_ids]
type = SubdomainIDGenerator
input = fluid
subdomain_id = '200'
[]
[combine]
type = CombinerGenerator
inputs = 'solid_ids fluid_ids'
[]
allow_renumbering = false
[]
[Problem]
type = OpenMCCellAverageProblem
verbose = true
power = 1e4
temperature_blocks = '100'
cell_level = 0
initial_properties = xml
source_rate_normalization = 'kappa_fission'
[Tallies]
[Heating]
type = CellTally
score = 'kappa_fission'
block = '100 200'
[]
[Flux]
type = CellTally
score = 'flux'
block = '100 200'
filters = 'blank'
[]
[]
[Filters]
[Energy]
type = EnergyFilter
# CASMO 2 group structure for testing. May result in some missed particles
energy_boundaries = '0.0 6.25e-1 2.0e7'
[]
[]
[]
[Executioner]
type = Steady
[]
[Outputs]
csv = true
[]
(test/tests/neutronics/flux/flux.i)
[Mesh]
[sphere]
type = FileMeshGenerator
file = ../meshes/sphere.e
[]
[solid]
type = CombinerGenerator
inputs = sphere
positions = '0 0 0
0 0 4
0 0 8'
[]
[solid_ids]
type = SubdomainIDGenerator
input = solid
subdomain_id = '100'
[]
[fluid]
type = FileMeshGenerator
file = ../heat_source/stoplight.exo
[]
[fluid_ids]
type = SubdomainIDGenerator
input = fluid
subdomain_id = '200'
[]
[combine]
type = CombinerGenerator
inputs = 'solid_ids fluid_ids'
[]
[]
[Problem]
type = OpenMCCellAverageProblem
verbose = true
power = 1e4
temperature_blocks = '100 200'
density_blocks = '200'
cell_level = 0
initial_properties = xml
source_rate_normalization = 'heating'
[Tallies]
[Cell]
type = CellTally
score = 'heating flux'
block = '100 200'
[]
[]
[]
[Executioner]
type = Steady
[]
[Postprocessors]
[flux_pebble1]
type = PointValue
variable = flux
point = '0 0 0'
[]
[flux_pebble2]
type = PointValue
variable = flux
point = '0 0 4'
[]
[flux_pebble3]
type = PointValue
variable = flux
point = '0 0 8'
[]
[flux_fluid]
type = PointValue
variable = flux
point = '0 0 2'
[]
[]
[Outputs]
csv = true
[]
(tutorials/gas_compact_multiphysics/openmc_thm.i)
!include common_input.i
# This input file runs coupled OpenMC Monte Carlo transport, MOOSE heat
# conduction, and THM fluid flow and heat transfer.
# This input should be run with:
#
# cardinal-opt -i openmc_thm.i
num_layers_for_THM = 150
num_layers = 50
density_blocks = 'coolant'
temperature_blocks = 'graphite compacts compacts_trimmer_tri'
fuel_blocks = 'compacts compacts_trimmer_tri'
unit_cell_power = ${fparse power / (n_bundles * n_coolant_channels_per_block) * unit_cell_height / height}
[Mesh]
[solid]
type = FileMeshGenerator
file = solid_mesh_in.e
[]
[]
[AuxVariables]
[cell_temperature]
family = MONOMIAL
order = CONSTANT
[]
[cell_density]
family = MONOMIAL
order = CONSTANT
[]
[thm_temp_wall]
family = MONOMIAL
order = CONSTANT
block = ${density_blocks}
[]
[flux]
[]
[]
[AuxKernels]
[cell_temperature]
type = CellTemperatureAux
variable = cell_temperature
[]
[cell_density]
type = CellDensityAux
variable = cell_density
[]
[density]
type = FluidDensityAux
variable = density
p = ${outlet_P}
T = thm_temp
fp = helium
execute_on = 'timestep_begin linear'
[]
[]
[FluidProperties]
[helium]
type = IdealGasFluidProperties
molar_mass = 4e-3
gamma = 1.668282 # should correspond to Cp = 5189 J/kg/K
k = 0.2556
mu = 3.22639e-5
[]
[]
[ICs]
[fluid_temp_wall]
type = FunctionIC
variable = thm_temp_wall
function = temp_ic
[]
[fluid_temp]
type = FunctionIC
variable = thm_temp
function = temp_ic
[]
[heat_source]
type = ConstantIC
variable = heat_source
block = ${fuel_blocks}
value = ${fparse unit_cell_power / (2.0 * pi * compact_diameter * compact_diameter / 4.0 * unit_cell_height)}
[]
[]
[Functions]
[temp_ic]
type = ParsedFunction
expression = '${inlet_T} + z / ${unit_cell_height} * ${unit_cell_power} / (${mdot} / ${n_bundles} / ${n_coolant_channels_per_block}) / ${fluid_Cp}'
[]
[]
[Problem]
type = OpenMCCellAverageProblem
power = ${unit_cell_power}
scaling = 100.0
density_blocks = ${density_blocks}
cell_level = 1
relaxation = robbins_monro
temperature_variables = 'solid_temp; thm_temp'
temperature_blocks = '${temperature_blocks}; ${density_blocks}'
k_trigger = std_dev
k_trigger_threshold = 7.5e-4
batches = 40
max_batches = 100
batch_interval = 5
[Tallies]
[heat_source]
type = CellTally
block = ${fuel_blocks}
name = heat_source
check_equal_mapped_tally_volumes = true
trigger = rel_err
trigger_threshold = 1e-2
output = 'unrelaxed_tally_std_dev'
[]
[]
[]
[Executioner]
type = Transient
# We use a fairly loose tolerance here for a tutorial; you may consider increasing this
# for production runs
steady_state_detection = true
check_aux = true
steady_state_tolerance = 5e-3
[]
[MultiApps]
[bison]
type = TransientMultiApp
input_files = 'solid_thm.i'
execute_on = timestep_begin
[]
[thm]
type = FullSolveMultiApp
input_files = 'thm.i'
execute_on = timestep_end
max_procs_per_app = 1
bounding_box_padding = '0.1 0.1 0'
[]
[]
[Transfers]
[solid_temp_to_openmc]
type = MultiAppGeometricInterpolationTransfer
source_variable = T
variable = solid_temp
from_multi_app = bison
[]
[heat_flux_to_openmc]
type = MultiAppGeneralFieldNearestLocationTransfer
source_variable = flux
variable = flux
from_multi_app = bison
from_boundaries = 'fluid_solid_interface'
to_boundaries = 'fluid_solid_interface'
from_postprocessors_to_be_preserved = flux_integral
to_postprocessors_to_be_preserved = flux_integral
[]
[source_to_bison]
type = MultiAppGeneralFieldShapeEvaluationTransfer
source_variable = heat_source
variable = power
to_multi_app = bison
from_postprocessors_to_be_preserved = heat_source
to_postprocessors_to_be_preserved = power
[]
[thm_temp_to_bison]
type = MultiAppGeometricInterpolationTransfer
source_variable = thm_temp_wall
variable = fluid_temp
to_multi_app = bison
[]
[q_wall_to_thm]
type = MultiAppGeneralFieldUserObjectTransfer
variable = q_wall
to_multi_app = thm
source_user_object = q_wall_avg
[]
[T_wall_from_thm]
type = MultiAppGeneralFieldNearestLocationTransfer
source_variable = T_wall
from_multi_app = thm
variable = thm_temp_wall
[]
[T_bulk_from_thm]
type = MultiAppGeneralFieldNearestLocationTransfer
source_variable = T
from_multi_app = thm
variable = thm_temp
[]
[]
[Postprocessors]
[flux_integral]
type = SideIntegralVariablePostprocessor
variable = flux
boundary = 'fluid_solid_interface'
execute_on = 'transfer'
[]
[heat_source]
type = ElementIntegralVariablePostprocessor
variable = heat_source
execute_on = 'transfer initial timestep_end'
block = ${fuel_blocks}
[]
[max_tally_err]
type = TallyRelativeError
value_type = max
[]
[k]
type = KEigenvalue
[]
[k_std_dev]
type = KEigenvalue
output = 'std_dev'
[]
[min_power]
type = ElementExtremeValue
variable = heat_source
value_type = min
block = ${fuel_blocks}
[]
[max_power]
type = ElementExtremeValue
variable = heat_source
value_type = max
block = ${fuel_blocks}
[]
[]
[AuxVariables]
[q_wall]
[]
[]
[AuxKernels]
[q_wall]
type = SpatialUserObjectAux
variable = q_wall
user_object = q_wall_avg
[]
[]
[UserObjects]
[q_wall_avg]
type = LayeredSideAverage
boundary = fluid_solid_interface
variable = flux
# Note: make this to match the num_elems in the channel
direction = z
num_layers = ${num_layers_for_THM}
direction_min = 0.0
direction_max = ${unit_cell_height}
[]
[average_power_axial]
type = LayeredAverage
variable = heat_source
direction = z
num_layers = ${num_layers}
block = ${fuel_blocks}
[]
[]
[VectorPostprocessors]
[power_avg]
type = SpatialUserObjectVectorPostprocessor
userobject = average_power_axial
[]
[]
[Outputs]
exodus = true
[csv]
type = CSV
file_base = 'csv_thm/openmc_thm'
[]
[]
(tutorials/openmc_subchannel/all_coupled/openmc.i)
!include ../common.i
[Mesh]
[file]
type = FileMeshGenerator
file = ../meshes/mesh_in.e
[]
[]
[Problem]
type = OpenMCCellAverageProblem
power = ${power}
lowest_cell_level = 2
scaling = 100
temperature_blocks = 'helium fuel clad sodium'
density_blocks = 'sodium'
xml_directory = '../openmc'
[Tallies]
[power]
type = CellTally
score = 'kappa_fission'
[]
[]
[]
[ICs]
[temp]
type = ConstantIC
variable = temp
value = ${inlet_temperature}
[]
[density]
type = ConstantIC
variable = density
value = ${fparse 1.00423e3 + -0.21390*inlet_temperature+-1.1046e-5*inlet_temperature^2}
[]
[]
[AuxVariables]
[cell_temperature]
family = MONOMIAL
order = CONSTANT
[]
[cell_density]
family = MONOMIAL
order = CONSTANT
[]
[]
[AuxKernels]
[cell_temperature]
type = CellTemperatureAux
variable = cell_temperature
[]
[cell_density]
type = CellDensityAux
variable = cell_density
[]
[]
[Executioner]
type = Transient
num_steps = 5
[]
[Outputs]
exodus = true
[]
[MultiApps]
[conduction]
type = TransientMultiApp
input_files = 'conduction.i'
sub_cycling = true
execute_on = timestep_end
[]
[subchannel]
type = FullSolveMultiApp
input_files = 'subchannel.i'
max_procs_per_app = 1
execute_on = timestep_begin
[]
[]
[Transfers]
[power_to_conduction]
type = MultiAppGeneralFieldNearestLocationTransfer
to_multi_app = conduction
source_variable = kappa_fission
variable = heat_source
from_postprocessors_to_be_preserved = openmc_power_integral
to_postprocessors_to_be_preserved = conduction_power_integral
[]
[solid_temperature_from_conduction]
type = MultiAppGeneralFieldNearestLocationTransfer
from_multi_app = conduction
source_variable = T
variable = temp
to_blocks = 'fuel clad helium'
[]
[linear_heat_rate_to_subchannel]
type = MultiAppGeneralFieldNearestLocationTransfer
variable = q_prime
source_variable = q_prime
from_multi_app = conduction
to_multi_app = subchannel
greedy_search = true
use_bounding_boxes = false
to_blocks = 'fuel_pins'
[]
[fluid_temperature_from_subchannel]
type = MultiAppGeneralFieldNearestLocationTransfer
source_variable = T
variable = temp
from_multi_app = subchannel
greedy_search = true
use_bounding_boxes = false
to_blocks = 'sodium'
from_blocks = 'subchannel'
[]
[fluid_density_from_subchannel]
type = MultiAppGeneralFieldNearestLocationTransfer
source_variable = rho
variable = density
from_multi_app = subchannel
greedy_search = true
use_bounding_boxes = false
to_blocks = 'sodium'
from_blocks = 'subchannel'
[]
[clad_surface_temperature_to_conduction]
type = MultiAppGeneralFieldNearestLocationTransfer
from_multi_app = subchannel
to_multi_app = conduction
source_variable = Tpin
variable = T_wall
[]
[]
[Postprocessors]
[openmc_power_integral]
type = ElementIntegralVariablePostprocessor
variable = kappa_fission
execute_on = 'transfer timestep_end'
[]
[]
(test/tests/neutronics/dagmc/density_skin/disjoint_bins.i)
[Mesh]
type = FileMesh
file = ../mesh_tallies/slab.e
[]
x0 = 12.5
x1 = 37.5
x2 = 62.5
T0 = 600.0
dT = 50.0
[Functions]
[density]
type = ParsedFunction
expression = 'if (x <= ${x0}, ${fparse T0 - dT}, if (x <= ${x1}, ${T0}, if (x <= ${x2}, ${fparse T0 - dT}, ${fparse T0 + 2 * dT})))'
[]
[]
[AuxKernels]
[temp]
type = FunctionAux
variable = density
function = density
execute_on = timestep_begin
[]
[]
[ICs]
[temp]
type = ConstantIC
variable = temp
value = 500.0
[]
[]
[Problem]
type = OpenMCCellAverageProblem
verbose = true
temperature_blocks = '1 2'
density_blocks = '1 2'
cell_level = 0
power = 100.0
skinner = moab
[Tallies]
[Mesh]
type = CellTally
block = '1 2'
[]
[]
[]
[UserObjects]
[moab]
type = MoabSkinner
density_min = ${fparse T0 - dT}
density_max = ${fparse T0 + 2 * dT}
n_density_bins = 4
density = density
temperature = temp
n_temperature_bins = 1
temperature_min = 0.0
temperature_max = 1000.0
build_graveyard = true
output_skins = true
[]
[]
[Postprocessors]
[k]
type = KEigenvalue
[]
[]
[Executioner]
type = Transient
num_steps = 2
[]
[Outputs]
exodus = true
hide = 'temp density cell_instance cell_id'
[]
(test/tests/neutronics/heat_source/cell_volumes.i)
# In this input, MOOSEs domain contains the entire OpenMC domain, but some
# MOOSE elements arent mapped anywhere (this is facilitated by adding an
# extra pebble to the MOOSE mesh).
[Mesh]
[sphere]
type = FileMeshGenerator
file = ../meshes/sphere.e
[]
[solid]
type = CombinerGenerator
inputs = sphere
positions = '0 0 0
0 0 4
0 0 8
9 9 9'
[]
[solid_ids]
type = SubdomainIDGenerator
input = solid
subdomain_id = '100'
[]
[fluid]
type = FileMeshGenerator
file = stoplight.exo
[]
[fluid_ids]
type = SubdomainIDGenerator
input = fluid
subdomain_id = '200'
[]
[combine]
type = CombinerGenerator
inputs = 'solid_ids fluid_ids'
[]
[]
[AuxVariables]
[cell_volume]
family = MONOMIAL
order = CONSTANT
[]
[]
[AuxKernels]
[cell_volume]
type = CellVolumeAux
variable = cell_volume
volume_type = mapped
[]
[]
[Problem]
type = OpenMCCellAverageProblem
power = 100.0
temperature_blocks = '100 200'
density_blocks = '200'
initial_properties = xml
verbose = true
cell_level = 0
[Tallies]
[Cell]
type = CellTally
block = '100 200'
[]
[]
[]
[Executioner]
type = Steady
[]
[Outputs]
execute_on = final
exodus = true
hide = 'density kappa_fission temp'
[]
(test/tests/neutronics/tally_system/multi_cell_triggers.i)
[Mesh]
[sphere]
type = FileMeshGenerator
file = ../meshes/sphere.e
[]
[solid]
type = CombinerGenerator
inputs = sphere
positions = '0 0 0
0 0 4
0 0 8'
[]
[solid_ids]
type = SubdomainIDGenerator
input = solid
subdomain_id = '100'
[]
[fluid]
type = FileMeshGenerator
file = ../heat_source/stoplight.exo
[]
[fluid_ids]
type = SubdomainIDGenerator
input = fluid
subdomain_id = '200'
[]
[combine]
type = CombinerGenerator
inputs = 'solid_ids fluid_ids'
[]
[]
[Problem]
type = OpenMCCellAverageProblem
verbose = true
power = 1e4
temperature_blocks = '100'
cell_level = 0
initial_properties = xml
source_rate_normalization = 'kappa_fission'
max_batches = 200
[Tallies]
[Cell_1]
type = CellTally
score = kappa_fission
block = '100 200'
trigger = rel_err
trigger_threshold = 1e-2
[]
[Cell_2]
type = CellTally
score = flux
block = '100 200'
trigger = rel_err
trigger_threshold = 1e-2
[]
[]
[]
[Postprocessors]
[Pebble_1_Heat]
type = PointValue
point = '0 0 0'
variable = kappa_fission
[]
[Pebble_2_Heat]
type = PointValue
point = '0 0 4'
variable = kappa_fission
[]
[Pebble_3_Heat]
type = PointValue
point = '0 0 8'
variable = kappa_fission
[]
[Pebble_1_Flux]
type = PointValue
point = '0 0 0'
variable = flux
[]
[Pebble_2_Flux]
type = PointValue
point = '0 0 4'
variable = flux
[]
[Pebble_3_Flux]
type = PointValue
point = '0 0 8'
variable = flux
[]
[]
[Executioner]
type = Steady
[]
[Outputs]
csv = true
[]
(test/tests/neutronics/heat_source/mapping_fluid.i)
[Mesh]
[sphere]
type = FileMeshGenerator
file = ../meshes/sphere.e
[]
[solid]
type = CombinerGenerator
inputs = sphere
positions = '0 0 0
0 0 4
0 0 8'
[]
[solid_ids]
type = SubdomainIDGenerator
input = solid
subdomain_id = '100'
[]
[fluid]
type = FileMeshGenerator
file = stoplight.exo
[]
[fluid_ids]
type = SubdomainIDGenerator
input = fluid
subdomain_id = '200'
[]
[combine]
type = CombinerGenerator
inputs = 'solid_ids fluid_ids'
[]
[]
[Problem]
type = OpenMCCellAverageProblem
power = 100.0
temperature_blocks = '100 200'
density_blocks = '200'
initial_properties = xml
verbose = true
cell_level = 0
[Tallies]
[Cell]
type = CellTally
name = heat_source
# This input has fissile material in the solid phase, so we will get a warning
# that we are neglecting some of the global kappa-fission distribution; so here
# the power is the total power of the OpenMC problem, and only a fraction of this
# will be computed in the fluid
block = '200'
# We are skipping some feedback with fissile regions, so we need to turn off the check
check_tally_sum = false
[]
[]
[]
[Executioner]
type = Steady
[]
[Postprocessors]
[fluid_heat_source]
type = ElementIntegralVariablePostprocessor
variable = heat_source
block = '200'
[]
[]
[Outputs]
exodus = true
csv = true
hide = 'density'
[]
(test/tests/neutronics/heat_source/multi_tally.i)
[Mesh]
[sphere]
type = FileMeshGenerator
file = ../meshes/sphere.e
[]
[solid]
type = CombinerGenerator
inputs = sphere
positions = '0 0 0
0 0 4
0 0 8'
[]
[solid_ids]
type = SubdomainIDGenerator
input = solid
subdomain_id = '100'
[]
[fluid]
type = FileMeshGenerator
file = stoplight.exo
[]
[fluid_ids]
type = SubdomainIDGenerator
input = fluid
subdomain_id = '200'
[]
[combine]
type = CombinerGenerator
inputs = 'solid_ids fluid_ids'
[]
[]
[Problem]
type = OpenMCCellAverageProblem
power = 100.0
temperature_blocks = '100 200'
density_blocks = '200'
verbose = true
cell_level = 0
initial_properties = xml
[Tallies]
[Cell]
type = CellTally
score = 'kappa_fission heating'
block = '100 200'
[]
[]
[]
[Executioner]
type = Transient
num_steps = 1
[]
[Postprocessors]
[kappa_fission]
type = ElementIntegralVariablePostprocessor
variable = kappa_fission
block = '100 200'
[]
[fluid_kappa_fission]
type = ElementIntegralVariablePostprocessor
variable = kappa_fission
block = '200'
[]
[solid_kappa_fission]
type = ElementIntegralVariablePostprocessor
variable = kappa_fission
block = '100'
[]
[heating]
type = ElementIntegralVariablePostprocessor
variable = heating
[]
[fluid_heating]
type = ElementIntegralVariablePostprocessor
variable = heating
block = '200'
[]
[solid_heating]
type = ElementIntegralVariablePostprocessor
variable = heating
block = '100'
[]
[]
[Outputs]
csv = true
[]
(test/tests/openmc_errors/block_mappings/no_overlap.i)
[Mesh]
[sphere]
type = FileMeshGenerator
file = ../../neutronics/meshes/sphere.e
[]
[solid]
type = CombinerGenerator
inputs = sphere
positions = '100 100 100'
[]
[]
[Problem]
type = OpenMCCellAverageProblem
power = 70.0
cell_level = 0
[Tallies]
[Cell]
type = CellTally
block = '1'
[]
[]
[]
[Executioner]
type = Transient
[]
(tutorials/gas_compact_multiphysics/openmc_nek.i)
!include common_input.i
# This input file runs coupled OpenMC Monte Carlo transport, MOOSE heat
# conduction, and NekRS fluid flow and heat transfer.
# This input should be run with:
#
# cardinal-opt -i openmc_nek.i
num_layers_for_THM = 150
density_blocks = 'coolant'
temperature_blocks = 'graphite compacts compacts_trimmer_tri'
fuel_blocks = 'compacts compacts_trimmer_tri'
unit_cell_power = ${fparse power / (n_bundles * n_coolant_channels_per_block) * unit_cell_height / height}
U_ref = ${fparse mdot / (n_bundles * n_coolant_channels_per_block) / fluid_density / (pi * channel_diameter * channel_diameter / 4.0)}
t0 = ${fparse channel_diameter / U_ref}
nek_dt = 6e-3
N = 1000
[Mesh]
[solid]
type = FileMeshGenerator
file = solid_mesh_in.e
[]
[]
[AuxVariables]
[cell_temperature]
family = MONOMIAL
order = CONSTANT
[]
[cell_density]
family = MONOMIAL
order = CONSTANT
[]
[]
[AuxKernels]
[cell_temperature]
type = CellTemperatureAux
variable = cell_temperature
[]
[cell_density]
type = CellDensityAux
variable = cell_density
[]
[density]
type = FluidDensityAux
variable = density
p = ${outlet_P}
T = nek_temp
fp = helium
execute_on = 'timestep_begin'
[]
[]
[FluidProperties]
[helium]
type = IdealGasFluidProperties
molar_mass = 4e-3
gamma = 1.668282 # should correspond to Cp = 5189 J/kg/K
k = 0.2556
mu = 3.22639e-5
[]
[]
[ICs]
[temp]
type = FunctionIC
variable = nek_temp
function = temp_ic
[]
[solid_temp]
type = FunctionIC
variable = solid_temp
function = temp_ic
[]
[]
[Functions]
[temp_ic]
type = ParsedFunction
expression = '${inlet_T} + z / ${unit_cell_height} * ${unit_cell_power} / (${mdot} / ${n_bundles} / ${n_coolant_channels_per_block}) / ${fluid_Cp}'
[]
[]
[Problem]
type = OpenMCCellAverageProblem
power = ${unit_cell_power}
scaling = 100.0
density_blocks = ${density_blocks}
cell_level = 1
relaxation = robbins_monro
temperature_variables = 'solid_temp; nek_temp'
temperature_blocks = '${temperature_blocks}; ${density_blocks}'
k_trigger = std_dev
k_trigger_threshold = 7.5e-4
batches = 40
max_batches = 100
batch_interval = 5
[Tallies]
[heat_source]
type = CellTally
block = ${fuel_blocks}
name = heat_source
check_equal_mapped_tally_volumes = true
trigger = rel_err
trigger_threshold = 1e-2
output = 'unrelaxed_tally_std_dev'
[]
[]
[]
[Executioner]
type = Transient
dt = ${fparse N * nek_dt * t0}
# This is somewhat loose, and you should use a tighter tolerance for production runs;
# we use 1e-2 to obtain a faster tutorial
steady_state_detection = true
check_aux = true
steady_state_tolerance = 1e-2
[]
[MultiApps]
[bison]
type = TransientMultiApp
input_files = 'solid_nek.i'
execute_on = timestep_end
sub_cycling = true
[]
[]
[Transfers]
[solid_temp_to_openmc]
type = MultiAppGeometricInterpolationTransfer
source_variable = T
variable = solid_temp
from_multi_app = bison
[]
[source_to_bison]
type = MultiAppGeneralFieldShapeEvaluationTransfer
source_variable = heat_source
variable = power
to_multi_app = bison
from_postprocessors_to_be_preserved = heat_source
to_postprocessors_to_be_preserved = power
[]
[temp_from_nek]
type = MultiAppGeneralFieldShapeEvaluationTransfer
source_variable = nek_bulk_temp
from_multi_app = bison
variable = nek_temp
[]
[]
[Postprocessors]
[heat_source]
type = ElementIntegralVariablePostprocessor
variable = heat_source
execute_on = 'transfer initial timestep_end'
block = ${fuel_blocks}
[]
[max_tally_err]
type = TallyRelativeError
value_type = max
[]
[k]
type = KEigenvalue
[]
[k_std_dev]
type = KEigenvalue
output = 'std_dev'
[]
[min_power]
type = ElementExtremeValue
variable = heat_source
value_type = min
block = ${fuel_blocks}
[]
[max_power]
type = ElementExtremeValue
variable = heat_source
value_type = max
block = ${fuel_blocks}
[]
[]
[UserObjects]
[average_power_axial]
type = LayeredAverage
variable = heat_source
direction = z
num_layers = ${num_layers_for_plots}
block = ${fuel_blocks}
[]
[]
[VectorPostprocessors]
[power_avg]
type = SpatialUserObjectVectorPostprocessor
userobject = average_power_axial
[]
[]
[Outputs]
[out]
type = Exodus
hide = 'solid_temp nek_temp'
[]
[csv]
type = CSV
file_base = 'csv_nek/openmc_nek'
[]
[]
(test/tests/neutronics/filters/azimuthal/cell.i)
[Mesh]
[sphere]
type = FileMeshGenerator
file = ../../meshes/sphere.e
[]
[solid]
type = CombinerGenerator
inputs = sphere
positions = '0 0 0
0 0 4
0 0 8'
[]
[solid_ids]
type = SubdomainIDGenerator
input = solid
subdomain_id = '100'
[]
[fluid]
type = FileMeshGenerator
file = ../../heat_source/stoplight.exo
[]
[fluid_ids]
type = SubdomainIDGenerator
input = fluid
subdomain_id = '200'
[]
[combine]
type = CombinerGenerator
inputs = 'solid_ids fluid_ids'
[]
allow_renumbering = false
[]
[Problem]
type = OpenMCCellAverageProblem
verbose = true
power = 1e4
temperature_blocks = '100'
cell_level = 0
initial_properties = xml
source_rate_normalization = 'kappa_fission'
[Tallies]
[Heating]
type = CellTally
score = 'kappa_fission'
block = '100 200'
[]
[Flux]
type = CellTally
score = 'flux'
block = '100 200'
filters = 'Azimuthal'
[]
[]
[Filters]
[Azimuthal]
type = AzimuthalAngleFilter
[]
[]
[]
[Postprocessors]
[Pebble_1_Flux_Omega1]
type = PointValue
point = '0 0 0'
variable = flux_omega1
[]
[Pebble_2_Flux_Omega2]
type = PointValue
point = '0 0 4'
variable = flux_omega2
[]
[Pebble_3_Flux_Omega1]
type = PointValue
point = '0 0 8'
variable = flux_omega1
[]
[Pebble_1_Flux_Omega2]
type = PointValue
point = '0 0 0'
variable = flux_omega2
[]
[Pebble_2_Flux_Omega1]
type = PointValue
point = '0 0 4'
variable = flux_omega1
[]
[Pebble_3_Flux_Omega2]
type = PointValue
point = '0 0 8'
variable = flux_omega2
[]
[]
[Executioner]
type = Steady
[]
[Outputs]
csv = true
[]
(test/tests/neutronics/filters/mesh_sum_gold.i)
[Mesh]
[sphere]
type = FileMeshGenerator
file = ../meshes/sphere.e
[]
[solid]
type = CombinerGenerator
inputs = sphere
positions = '0 0 0
0 0 4
0 0 8'
[]
[solid_ids]
type = SubdomainIDGenerator
input = solid
subdomain_id = '100'
[]
allow_renumbering = false
[]
[Problem]
type = OpenMCCellAverageProblem
verbose = true
power = 1e4
temperature_blocks = '100'
cell_level = 0
initial_properties = xml
source_rate_normalization = 'kappa_fission'
[Tallies]
[Heating]
type = CellTally
score = 'kappa_fission'
block = '100'
# Disable global normalization since we have a loosely fitting mesh tally.
normalize_by_global_tally = false
[]
[Flux]
type = MeshTally
score = 'flux'
mesh_template = ../meshes/sphere.e
mesh_translations = '0 0 0
0 0 4
0 0 8'
# Disable global normalization since we have a loosely fitting mesh tally.
normalize_by_global_tally = false
[]
[]
[]
[Executioner]
type = Steady
[]
[Outputs]
exodus = true
[]
(test/tests/neutronics/feedback/interchangeable/openmc.i)
[Mesh]
[3d]
type = GeneratedMeshGenerator
dim = 3
nx = 4
ny = 4
nz = 2
xmin = -12.5
xmax = 87.5
ymin = -12.5
ymax = 37.5
zmin = -12.5
zmax = 12.5
[]
[upper_block]
type = ParsedSubdomainMeshGenerator
input = 3d
combinatorial_geometry = 'y > 12.5'
block_id = 1
[]
[]
[AuxVariables]
[cell_temperature]
family = MONOMIAL
order = CONSTANT
[]
[material_id]
family = MONOMIAL
order = CONSTANT
[]
[cell_density]
family = MONOMIAL
order = CONSTANT
[]
[]
[AuxKernels]
[cell_temperature]
type = CellTemperatureAux
variable = cell_temperature
[]
[material_id]
type = CellMaterialIDAux
variable = material_id
[]
[cell_density]
type = CellDensityAux
variable = cell_density
[]
[]
[ICs]
active = ''
[temp]
type = ConstantIC
variable = temp
value = 300.0
[]
[density]
type = ConstantIC
variable = density
value = 15.0e3
[]
[]
[Problem]
type = OpenMCCellAverageProblem
verbose = true
cell_level = 0
power = 1.0
[Tallies]
[Cell]
type = CellTally
block = '0 1'
[]
[]
[]
[Postprocessors]
[k]
type = KEigenvalue
[]
[power_0]
type = ElementIntegralVariablePostprocessor
variable = kappa_fission
block = '0'
[]
[power_1]
type = ElementIntegralVariablePostprocessor
variable = kappa_fission
block = '1'
[]
[id_0]
type = ElementAverageValue
variable = cell_id
block = '0'
[]
[id_1]
type = ElementAverageValue
variable = cell_id
block = '1'
[]
[instance_0]
type = ElementAverageValue
variable = cell_instance
block = '0'
[]
[instance_1]
type = ElementAverageValue
variable = cell_instance
block = '1'
[]
[temp_0]
type = ElementAverageValue
variable = cell_temperature
block = '0'
[]
[temp_1]
type = ElementAverageValue
variable = cell_temperature
block = '1'
[]
[rho_0]
type = ElementAverageValue
variable = cell_density
block = '0'
[]
[rho_1]
type = ElementAverageValue
variable = cell_density
block = '1'
[]
[mat_0]
type = ElementAverageValue
variable = material_id
block = '0'
[]
[mat_1]
type = ElementAverageValue
variable = material_id
block = '1'
[]
[]
[Executioner]
type = Transient
num_steps = 1
[]
[Outputs]
csv = true
[]
(test/tests/neutronics/heat_source/custom_name.i)
[Mesh]
[sphere]
type = FileMeshGenerator
file = ../meshes/sphere.e
[]
[solid]
type = CombinerGenerator
inputs = sphere
positions = '0 0 0
0 0 4
0 0 8'
[]
[solid_ids]
type = SubdomainIDGenerator
input = solid
subdomain_id = '100'
[]
[fluid]
type = FileMeshGenerator
file = stoplight.exo
[]
[fluid_ids]
type = SubdomainIDGenerator
input = fluid
subdomain_id = '200'
[]
[combine]
type = CombinerGenerator
inputs = 'solid_ids fluid_ids'
[]
[]
[Problem]
type = OpenMCCellAverageProblem
power = 100.0
temperature_blocks = '100 200'
density_blocks = '200'
initial_properties = xml
verbose = true
cell_level = 0
[Tallies]
[Cell]
type = CellTally
# Use a custom tally name
name = "volumetric_power"
# This input has fissile material in the fluid phase, so we will get a warning
# that we are neglecting some of the global kappa-fission distribution; so here
# the power is the total power of the OpenMC problem, and only a fraction of this
# will be computed in the solid pebbles
block = '100'
# We are skipping some feedback with fissile regions, so we need to turn off the check
check_tally_sum = false
[]
[]
[]
[Executioner]
type = Steady
[]
[Postprocessors]
[heat_source]
type = ElementIntegralVariablePostprocessor
variable = volumetric_power
block = '100'
[]
[]
[Outputs]
exodus = true
csv = true
hide = 'density'
[]
(test/tests/neutronics/filters/azimuthal/mesh.i)
[Mesh]
[sphere]
type = FileMeshGenerator
file = ../../meshes/sphere.e
[]
[solid]
type = CombinerGenerator
inputs = sphere
positions = '0 0 0
0 0 4
0 0 8'
[]
[solid_ids]
type = SubdomainIDGenerator
input = solid
subdomain_id = '100'
[]
allow_renumbering = false
[]
[Problem]
type = OpenMCCellAverageProblem
verbose = true
power = 1e4
temperature_blocks = '100'
cell_level = 0
initial_properties = xml
source_rate_normalization = 'kappa_fission'
[Tallies]
[Heating]
type = CellTally
score = 'kappa_fission'
block = '100'
# Disable global normalization since we have a loosely fitting mesh tally.
normalize_by_global_tally = false
[]
[Flux]
type = MeshTally
score = 'flux'
mesh_template = ../../meshes/sphere.e
mesh_translations = '0 0 0
0 0 4
0 0 8'
filters = 'Azimuthal'
# Disable global normalization since we have a loosely fitting mesh tally.
normalize_by_global_tally = false
[]
[]
[Filters]
[Azimuthal]
type = AzimuthalAngleFilter
num_equal_divisions = 2
[]
[]
[]
[Postprocessors]
[Total_Flux_Omega1]
type = ElementIntegralVariablePostprocessor
variable = flux_omega1
[]
[Total_Flux_Omega2]
type = ElementIntegralVariablePostprocessor
variable = flux_omega2
[]
[]
[Executioner]
type = Steady
[]
[Outputs]
csv = true
[]
(test/tests/userobjects/openmc_cell_transform/cells_shadow.i)
[Mesh]
[block]
type = GeneratedMeshGenerator
dim = 3
nx = 20
ny = 20
nz = 1
xmin = -12
xmax = 12
ymin = -12
ymax = 4
zmin = 0
zmax = 30
[]
[]
[Problem]
type = OpenMCCellAverageProblem
verbose = true
power = 100.0
cell_level = 1
reset_seed = true
xml_directory=./cells_shadow
[Tallies]
[heat]
type = CellTally
score = 'kappa_fission'
[]
[]
[]
[Functions]
[shift_y_fn]
type = ParsedFunction
expression = '-t'
[]
[]
[Postprocessors]
[shift_y]
type = FunctionValuePostprocessor
function = shift_y_fn
execute_on = 'timestep_begin'
[]
[k]
type = KEigenvalue
[]
[power]
type = ElementIntegralVariablePostprocessor
variable = kappa_fission
[]
[]
[UserObjects]
[move_bundle]
type = OpenMCCellTransform
transform_type = 'translation'
vector_value = '0 shift_y 0'
cell_ids = '2011'
execute_on = 'timestep_begin'
[]
[]
[Executioner]
type = Transient
num_steps = 4
[]
[Outputs]
exodus = true
[]
(test/tests/neutronics/tally_system/cell_with_unmapped.i)
[Mesh]
[sphere]
type = FileMeshGenerator
file = ../meshes/sphere.e
[]
[solid]
type = CombinerGenerator
inputs = sphere
positions = '0 0 0
0 0 4
0 0 8'
[]
[solid_ids]
type = SubdomainIDGenerator
input = solid
subdomain_id = '100'
[]
[fluid]
type = FileMeshGenerator
file = ../heat_source/stoplight.exo
[]
[fluid_ids]
type = SubdomainIDGenerator
input = fluid
subdomain_id = '200'
[]
[combine]
type = CombinerGenerator
inputs = 'solid_ids fluid_ids'
[]
[]
[Problem]
type = OpenMCCellAverageProblem
verbose = true
power = 1e4
temperature_blocks = '100'
cell_level = 0
initial_properties = xml
source_rate_normalization = 'kappa_fission'
[Tallies]
[Cell_1]
type = CellTally
score = kappa_fission
block = '100'
# We are intentionally excluding some blocks, so we need to disable global normalization.
normalize_by_global_tally = false
[]
[]
[]
[Postprocessors]
[Pebble_1_ID]
type = PointValue
point = '0 0 0'
variable = cell_id
[]
[Pebble_2_ID]
type = PointValue
point = '0 0 4'
variable = cell_id
[]
[Pebble_3_ID]
type = PointValue
point = '0 0 8'
variable = cell_id
[]
[Light_ID]
type = PointValue
point = '0 0 10'
variable = cell_id
[]
[Pebble_1_Heat]
type = PointValue
point = '0 0 0'
variable = kappa_fission
[]
[Pebble_2_Heat]
type = PointValue
point = '0 0 4'
variable = kappa_fission
[]
[Pebble_3_Heat]
type = PointValue
point = '0 0 8'
variable = kappa_fission
[]
[]
[Executioner]
type = Steady
[]
[Outputs]
csv = true
[]
(test/tests/neutronics/relaxation/cell_tallies/output_fission_tally.i)
[Mesh]
[pebble]
type = FileMeshGenerator
file = ../../meshes/sphere_in_m.e
[]
[repeat]
type = CombinerGenerator
inputs = pebble
positions = '0 0 0.02
0 0 0.06
0 0 0.10'
[]
[set_block_ids]
type = SubdomainIDGenerator
input = repeat
subdomain_id = 0
[]
[]
[AuxKernels]
[temp]
type = FunctionAux
variable = temp
function = axial
execute_on = initial
[]
[]
[Functions]
[axial]
type = ParsedFunction
expression = '500 + z / 0.10 * 100'
[]
[]
[Problem]
type = OpenMCCellAverageProblem
verbose = true
power = 1500.0
temperature_blocks = '0'
cell_level = 1
scaling = 100.0
relaxation = constant
[Tallies]
[Cell]
type = CellTally
block = '0'
output = 'unrelaxed_tally'
[]
[]
[]
[Executioner]
type = Transient
num_steps = 3
[]
[Outputs]
exodus = true
[]
(test/tests/neutronics/filters/energy/mesh_sum.i)
[Mesh]
[sphere]
type = FileMeshGenerator
file = ../../meshes/sphere.e
[]
[solid]
type = CombinerGenerator
inputs = sphere
positions = '0 0 0
0 0 4
0 0 8'
[]
[solid_ids]
type = SubdomainIDGenerator
input = solid
subdomain_id = '100'
[]
allow_renumbering = false
[]
[Problem]
type = OpenMCCellAverageProblem
verbose = true
power = 1e4
temperature_blocks = '100'
cell_level = 0
initial_properties = xml
source_rate_normalization = 'kappa_fission'
[Tallies]
[Heating]
type = CellTally
score = 'kappa_fission'
block = '100'
# Disable global normalization since we have a loosely fitting mesh tally.
normalize_by_global_tally = false
[]
[Flux]
type = MeshTally
score = 'flux'
mesh_template = ../../meshes/sphere.e
mesh_translations = '0 0 0
0 0 4
0 0 8'
filters = 'Energy'
# Disable global normalization since we have a loosely fitting mesh tally.
normalize_by_global_tally = false
[]
[]
[Filters]
[Energy]
type = EnergyFilter
# CASMO 2 group structure for testing. May result in some missed particles
energy_boundaries = '0.0 6.25e-1 2.0e7'
[]
[]
[]
[AuxVariables]
[flux]
family = MONOMIAL
order = CONSTANT
[]
[]
[AuxKernels]
[total_flux]
type = SumAux
variable = flux
values = 'flux_g1 flux_g2'
[]
[]
[Executioner]
type = Steady
[]
[Outputs]
exodus = true
hide = 'flux_g1 flux_g2'
[]
(test/tests/neutronics/filters/polar/mesh_sum.i)
[Mesh]
[sphere]
type = FileMeshGenerator
file = ../../meshes/sphere.e
[]
[solid]
type = CombinerGenerator
inputs = sphere
positions = '0 0 0
0 0 4
0 0 8'
[]
[solid_ids]
type = SubdomainIDGenerator
input = solid
subdomain_id = '100'
[]
allow_renumbering = false
[]
[Problem]
type = OpenMCCellAverageProblem
verbose = true
power = 1e4
temperature_blocks = '100'
cell_level = 0
initial_properties = xml
source_rate_normalization = 'kappa_fission'
[Tallies]
[Heating]
type = CellTally
score = 'kappa_fission'
block = '100'
# Disable global normalization since we have a loosely fitting mesh tally.
normalize_by_global_tally = false
[]
[Flux]
type = MeshTally
score = 'flux'
mesh_template = ../../meshes/sphere.e
mesh_translations = '0 0 0
0 0 4
0 0 8'
filters = 'Polar'
# Disable global normalization since we have a loosely fitting mesh tally.
normalize_by_global_tally = false
[]
[]
[Filters]
[Polar]
type = PolarAngleFilter
num_equal_divisions = 2
[]
[]
[]
[AuxVariables]
[flux]
family = MONOMIAL
order = CONSTANT
[]
[]
[AuxKernels]
[total_flux]
type = SumAux
variable = flux
values = 'flux_theta1 flux_theta2'
[]
[]
[Executioner]
type = Steady
[]
[Outputs]
exodus = true
hide = 'flux_theta1 flux_theta2'
[]
(test/tests/neutronics/feedback/triso/missing_triso_fill/openmc.i)
[Mesh]
[solid]
type = FileMeshGenerator
file = ../solid.e
[]
[change_block_ids_for_middle]
type = SubdomainBoundingBoxGenerator
input = solid
bottom_left = '-1.0 -1.0 0.05'
top_right = '1.0 1.0 0.07'
block_id = '5'
[]
[]
[Problem]
type = OpenMCCellAverageProblem
power = 2000.0
scaling = 100.0
temperature_blocks = '2 5'
cell_level = 1
# This input should error because the offset we compute for shifting cell instances
# in a TRISO universe cant account for the fact that we are skipping some of the
# TRISO universes from the tally setup
identical_cell_fills = '2'
check_identical_cell_fills = true
[Tallies]
[Cell]
type = CellTally
block = '2'
[]
[]
[]
[Executioner]
type = Transient
[]
(test/tests/openmc_errors/tallies/separate_tallies.i)
[Mesh]
[sphere]
type = FileMeshGenerator
file = ../../neutronics/meshes/sphere.e
[]
[solid]
type = CombinerGenerator
inputs = sphere
positions = '0 0 0
0 0 4
0 0 8'
[]
[]
[Problem]
type = OpenMCCellAverageProblem
power = 100.0
cell_level = 0
assume_separate_tallies = true
[Tallies]
[Cell]
type = CellTally
block = '1'
[]
[]
[]
[Executioner]
type = Transient
num_steps = 1
[]
(test/tests/userobjects/openmc_cell_transform/rotate_cells.i)
[Mesh]
[pin]
type = ConcentricCircleMeshGenerator
num_sectors = 6
radii = '1.0'
rings = '3 3'
has_outer_square = on
pitch = 4.0
preserve_volumes = yes
smoothing_max_it = 3
[]
[assembly]
type = CartesianIDPatternedMeshGenerator
inputs = 'pin'
pattern = '0 0;
0 0'
assign_type = 'cell'
id_name = 'pin_id'
[]
[delete]
# Only keeping block 1 (fuel pins) for this test
type = BlockDeletionGenerator
input = assembly
block = 2
[]
[extrude]
type = AdvancedExtruderGenerator
input = delete
direction = '0 0 1'
heights = '30'
num_layers = 1
[]
[translate]
type = TransformGenerator
input = extrude
transform = TRANSLATE_CENTER_ORIGIN
vector_value = '-12 12 0'
[]
[]
[GlobalParams]
displacements = 'disp_x disp_y disp_z'
use_displaced_mesh = true
[]
[Problem]
type = OpenMCCellAverageProblem
cell_level = 2
verbose = true
power = 100
[Tallies]
[heat]
type = CellTally
score = 'kappa_fission'
block = '1'
[]
[]
[]
[AuxVariables]
[disp_x]
[AuxKernel]
type = FunctionAux
variable = disp_x
function = disp_x_fn
execute_on = 'timestep_begin'
use_displaced_mesh = false
[]
[]
[disp_y]
[AuxKernel]
type = FunctionAux
variable = disp_y
function = disp_y_fn
execute_on = 'timestep_begin'
use_displaced_mesh = false
[]
[]
[disp_z]
[]
[]
[Functions]
[psi_fn]
type = ParsedFunction
expression = '5*t'
[]
[disp_x_fn]
type = ParsedFunction
expression = (cos(5*t*3.14159265359/180)-1)*x-sin(5*t*3.14159265359/180)*y
[]
[disp_y_fn]
type = ParsedFunction
expression = sin(5*t*3.14159265359/180)*x+(cos(5*t*3.14159265359/180)-1)*y
[]
[]
[Postprocessors]
[psi]
type = FunctionValuePostprocessor
function = psi_fn
execute_on = 'timestep_begin'
[]
[k]
type = KEigenvalue
[]
[power]
type = ElementIntegralVariablePostprocessor
variable = kappa_fission
block = '1'
[]
[]
[UserObjects]
[rotate_cells]
type = OpenMCCellTransform
transform_type = 'rotation'
vector_value = '0 0 psi'
cell_ids = '2011'
execute_on = 'timestep_begin'
[]
[]
[Executioner]
type = Transient
num_steps = 2
[]
[Outputs]
exodus = true
[]
(test/tests/neutronics/feedback/multi_component_temp/openmc.i)
[Mesh]
type = FileMesh
file = ../../meshes/pincell.e
[]
[AuxVariables]
[cell_temp]
family = MONOMIAL
order = CONSTANT
[]
[]
[AuxKernels]
[cell_temp]
type = CellTemperatureAux
variable = cell_temp
[]
[]
[ICs]
[solid_temp]
type = ConstantIC
variable = solid_temp
value = 800
[]
[fluid_temp]
type = ConstantIC
variable = fluid_temp
value = 600
[]
[]
[Problem]
type = OpenMCCellAverageProblem
power = 500.0
cell_level = 1
verbose = true
temperature_variables = 'solid_temp; fluid_temp'
temperature_blocks = '1 3; 2'
[Tallies]
[Cell]
type = CellTally
block = '1'
[]
[]
[]
[Executioner]
type = Steady
[]
[Postprocessors]
[max_temp_1]
type = ElementExtremeValue
variable = cell_temp
value_type = max
block = '1'
[]
[min_temp_1]
type = ElementExtremeValue
variable = cell_temp
value_type = min
block = '1'
[]
[max_temp_2]
type = ElementExtremeValue
variable = cell_temp
value_type = max
block = '2'
[]
[min_temp_2]
type = ElementExtremeValue
variable = cell_temp
value_type = min
block = '2'
[]
[max_temp_3]
type = ElementExtremeValue
variable = cell_temp
value_type = max
block = '3'
[]
[min_temp_3]
type = ElementExtremeValue
variable = cell_temp
value_type = min
block = '3'
[]
[]
[Outputs]
exodus = true
csv = true
[]
(test/tests/neutronics/filters/energy_out/cell.i)
[Mesh]
[sphere]
type = FileMeshGenerator
file = ../../meshes/sphere.e
[]
[solid]
type = CombinerGenerator
inputs = sphere
positions = '0 0 0
0 0 4
0 0 8'
[]
[solid_ids]
type = SubdomainIDGenerator
input = solid
subdomain_id = '100'
[]
[fluid]
type = FileMeshGenerator
file = ../../heat_source/stoplight.exo
[]
[fluid_ids]
type = SubdomainIDGenerator
input = fluid
subdomain_id = '200'
[]
[combine]
type = CombinerGenerator
inputs = 'solid_ids fluid_ids'
[]
allow_renumbering = false
[]
[Problem]
type = OpenMCCellAverageProblem
verbose = true
power = 1e4
temperature_blocks = '100'
cell_level = 0
initial_properties = xml
source_rate_normalization = 'kappa_fission'
[Tallies]
[Heating]
type = CellTally
score = 'kappa_fission'
block = '100 200'
[]
[Scattering]
type = CellTally
score = 'scatter'
block = '100 200'
filters = 'EnergyOut'
estimator = 'analog'
[]
[]
[Filters]
[EnergyOut]
type = EnergyOutFilter
# CASMO 2 group structure for testing. May result in some missed particles
[]
[]
[]
[Postprocessors]
[Pebble_1_scatter_1]
type = PointValue
point = '0 0 0'
variable = scatter_gp1
[]
[Pebble_2_scatter_1]
type = PointValue
point = '0 0 4'
variable = scatter_gp1
[]
[Pebble_3_scatter_1]
type = PointValue
point = '0 0 8'
variable = scatter_gp1
[]
[Pebble_1_scatter_2]
type = PointValue
point = '0 0 0'
variable = scatter_gp2
[]
[Pebble_2_scatter_2]
type = PointValue
point = '0 0 4'
variable = scatter_gp2
[]
[Pebble_3_scatter_2]
type = PointValue
point = '0 0 8'
variable = scatter_gp2
[]
[]
[Executioner]
type = Steady
[]
[Outputs]
csv = true
[]
(test/tests/neutronics/dagmc/with_csg/openmc.i)
[Mesh]
[slab]
type = FileMeshGenerator
file = ../mesh_tallies/slab.e
[]
allow_renumbering = false
parallel_type = replicated
[]
[AuxVariables]
[cell_temperature]
family = MONOMIAL
order = CONSTANT
[]
[]
[AuxKernels]
[cell_temperature]
type = CellTemperatureAux
variable = cell_temperature
[]
[]
[AuxKernels]
[temp]
type = ConstantAux
variable = temp
value = 500.0
execute_on = timestep_begin
[]
[]
[Problem]
type = OpenMCCellAverageProblem
verbose = true
temperature_blocks = '1 2'
cell_level = 1
power = 100.0
skinner = moab
[Tallies]
[Cell]
type = CellTally
block = '1 2'
# Since we're ignoring the CSG geometry when mapping tallies, we need to
# disable the tally sum check.
check_tally_sum = false
[]
[]
[]
[UserObjects]
[moab]
type = MoabSkinner
temperature_min = 0.0
temperature_max = 1000.0
n_temperature_bins = 1
temperature = temp
build_graveyard = false
[]
[]
[Postprocessors]
[k]
type = KEigenvalue
[]
[]
[Executioner]
type = Transient
num_steps = 2
[]
[Outputs]
csv = true
[]
(test/tests/neutronics/dagmc/density_skin/openmc.i)
[Mesh]
type = FileMesh
file = ../mesh_tallies/slab.e
allow_renumbering = false
[]
x0 = 12.5
x1 = 37.5
x2 = 62.5
[AuxVariables]
[material_id]
family = MONOMIAL
order = CONSTANT
[]
[cell_density]
family = MONOMIAL
order = CONSTANT
[]
[]
[AuxKernels]
[material_id]
type = CellMaterialIDAux
variable = material_id
[]
[cell_density]
type = CellDensityAux
variable = cell_density
[]
[]
rho0 = 600.0
drho = 50.0
[Functions]
[density]
type = ParsedFunction
expression = 'if (x <= ${x0}, ${fparse rho0 - drho}, if (x <= ${x1}, ${rho0}, if (x <= ${x2}, ${fparse rho0 + drho}, ${fparse rho0 + 2 * drho})))'
[]
[]
[ICs]
[temp]
type = ConstantIC
variable = temp
value = 500.0
[]
[]
[AuxKernels]
[density]
type = FunctionAux
variable = density
function = density
execute_on = timestep_begin
[]
[]
[Problem]
type = OpenMCCellAverageProblem
verbose = true
temperature_blocks = '1 2'
density_blocks = '1 2'
power = 100.0
skinner = moab
cell_level = 0
[Tallies]
[Mesh]
type = CellTally
block = '1 2'
[]
[]
[]
[UserObjects]
[moab]
type = MoabSkinner
# just one temperature bin
temperature_min = 0.0
temperature_max = 1000.0
n_temperature_bins = 1
temperature = temp
density_min = ${fparse rho0 - drho}
density_max = ${fparse rho0 + 2 * drho}
n_density_bins = 4
density = density
build_graveyard = true
[]
[]
[Postprocessors]
[k]
type = KEigenvalue
[]
[]
[Executioner]
type = Transient
num_steps = 2
[]
[Outputs]
exodus = true
hide = 'temp density cell_instance cell_id'
[]
(test/tests/openmc_errors/block_mappings/multiple_phases.i)
# This input tests what happens if an OpenMC cell maps to more than one phase;
# we do this by slightly moving one of the pebbles so that some of its elements
# will overlap with the fluid region
[Mesh]
[sphere]
# Mesh of a single pebble with outer radius of 1.5 (cm)
type = FileMeshGenerator
file = ../../neutronics/meshes/sphere.e
[]
[solid]
type = CombinerGenerator
inputs = sphere
positions = '0 0 0
0 0 4
0 0 8.5'
[]
[solid_ids]
type = SubdomainIDGenerator
input = solid
subdomain_id = '100'
[]
[fluid]
# Mesh of the fluid phase; this mesh would be the same as whatever is used to
# solve for the fluid phase
type = FileMeshGenerator
file = stoplight.exo
[]
[fluid_ids]
type = SubdomainIDGenerator
input = fluid
subdomain_id = '200'
[]
[combine]
type = CombinerGenerator
inputs = 'solid_ids fluid_ids'
[]
[]
[Problem]
type = OpenMCCellAverageProblem
power = 70.0
temperature_blocks = '100 200'
density_blocks = '200'
cell_level = 0
initial_properties = xml
[Tallies]
[Cell]
type = CellTally
block = '100'
[]
[]
[]
[Executioner]
type = Transient
num_steps = 1
[]
[Outputs]
exodus = true
[]
(test/tests/neutronics/feedback/lattice/openmc_scores.i)
[Mesh]
type = FileMesh
file = ../../meshes/pincell.e
[]
[Problem]
type = OpenMCCellAverageProblem
power = 500.0
temperature_blocks = '1 2 3'
density_blocks = '2'
cell_level = 1
initial_properties = xml
[Tallies]
[Cell]
type = CellTally
block = '1 2 3'
score = heating
name = heat_source
check_tally_sum = false
[]
[]
[]
[Executioner]
type = Transient
num_steps = 1
[]
[Postprocessors]
[heat_source]
type = ElementIntegralVariablePostprocessor
variable = heat_source
block = '1 2 3'
[]
[fluid_heat_source]
type = ElementIntegralVariablePostprocessor
variable = heat_source
block = '2'
[]
[fuel_heat_source]
type = ElementIntegralVariablePostprocessor
variable = heat_source
block = '1'
[]
[clad_heat_source]
type = ElementIntegralVariablePostprocessor
variable = heat_source
block = '3'
[]
[]
[Outputs]
exodus = true
csv = true
[]
(test/tests/neutronics/filters/azimuthal/mesh_sum.i)
[Mesh]
[sphere]
type = FileMeshGenerator
file = ../../meshes/sphere.e
[]
[solid]
type = CombinerGenerator
inputs = sphere
positions = '0 0 0
0 0 4
0 0 8'
[]
[solid_ids]
type = SubdomainIDGenerator
input = solid
subdomain_id = '100'
[]
allow_renumbering = false
[]
[Problem]
type = OpenMCCellAverageProblem
verbose = true
power = 1e4
temperature_blocks = '100'
cell_level = 0
initial_properties = xml
source_rate_normalization = 'kappa_fission'
[Tallies]
[Heating]
type = CellTally
score = 'kappa_fission'
block = '100'
# Disable global normalization since we have a loosely fitting mesh tally.
normalize_by_global_tally = false
[]
[Flux]
type = MeshTally
score = 'flux'
mesh_template = ../../meshes/sphere.e
mesh_translations = '0 0 0
0 0 4
0 0 8'
filters = 'Azimuthal'
# Disable global normalization since we have a loosely fitting mesh tally.
normalize_by_global_tally = false
[]
[]
[Filters]
[Azimuthal]
type = AzimuthalAngleFilter
num_equal_divisions = 2
[]
[]
[]
[AuxVariables]
[flux]
family = MONOMIAL
order = CONSTANT
[]
[]
[AuxKernels]
[total_flux]
type = SumAux
variable = flux
values = 'flux_omega1 flux_omega2'
[]
[]
[Executioner]
type = Steady
[]
[Outputs]
exodus = true
hide = 'flux_omega1 flux_omega2'
[]
(tutorials/pebbles/openmc.i)
[Mesh]
[pebble]
type = SphereMeshGenerator
nr = 2
radius = 0.015
[]
[repeat]
type = CombinerGenerator
inputs = pebble
positions = '0 0 0.02
0 0 0.06
0 0 0.10'
[]
[]
[AuxVariables]
[cell_temperature]
family = MONOMIAL
order = CONSTANT
[]
[]
[AuxKernels]
[cell_temperature]
type = CellTemperatureAux
variable = cell_temperature
[]
[]
[Problem]
type = OpenMCCellAverageProblem
verbose = true
power = 1500.0
temperature_blocks = '0'
cell_level = 1
scaling = 100.0
[Tallies]
[heat_source]
type = CellTally
block = '0'
name = heat_source
[]
[]
[]
[Executioner]
type = Transient
[]
[Outputs]
exodus = true
csv = true
[]
[Postprocessors]
[heat_source]
type = ElementIntegralVariablePostprocessor
variable = heat_source
[]
[max_tally_rel_err]
type = TallyRelativeError
[]
[k]
type = KEigenvalue
[]
[]
(test/tests/neutronics/filters/delayed/cell.i)
[Mesh]
[sphere]
type = FileMeshGenerator
file = ../../meshes/sphere.e
[]
[solid]
type = CombinerGenerator
inputs = sphere
positions = '0 0 0
0 0 4
0 0 8'
[]
[solid_ids]
type = SubdomainIDGenerator
input = solid
subdomain_id = '100'
[]
[fluid]
type = FileMeshGenerator
file = ../../heat_source/stoplight.exo
[]
[fluid_ids]
type = SubdomainIDGenerator
input = fluid
subdomain_id = '200'
[]
[combine]
type = CombinerGenerator
inputs = 'solid_ids fluid_ids'
[]
allow_renumbering = false
[]
[Problem]
type = OpenMCCellAverageProblem
verbose = true
power = 1e4
temperature_blocks = '100'
cell_level = 0
initial_properties = xml
source_rate_normalization = 'kappa_fission'
[Tallies]
[Heating]
type = CellTally
score = 'kappa_fission'
block = '100 200'
[]
[DNP]
type = CellTally
score = 'delayed_nu_fission decay_rate'
block = '100 200'
filters = 'Delayed'
[]
[]
[Filters]
[Delayed]
type = DelayedGroupFilter
dnp_groups = '1 2 3 4 5 6'
[]
[]
[]
[Postprocessors]
[Pebble_1_DFiss_1]
type = PointValue
point = '0 0 0'
variable = delayed_nu_fission_d1
[]
[Pebble_1_DFiss_2]
type = PointValue
point = '0 0 0'
variable = delayed_nu_fission_d2
[]
[Pebble_1_DFiss_3]
type = PointValue
point = '0 0 0'
variable = delayed_nu_fission_d3
[]
[Pebble_1_DFiss_4]
type = PointValue
point = '0 0 0'
variable = delayed_nu_fission_d4
[]
[Pebble_1_DFiss_5]
type = PointValue
point = '0 0 0'
variable = delayed_nu_fission_d5
[]
[Pebble_1_DFiss_6]
type = PointValue
point = '0 0 0'
variable = delayed_nu_fission_d6
[]
[Pebble_1_DRate_1]
type = PointValue
point = '0 0 0'
variable = decay_rate_d1
[]
[Pebble_1_DRate_2]
type = PointValue
point = '0 0 0'
variable = decay_rate_d2
[]
[Pebble_1_DRate_3]
type = PointValue
point = '0 0 0'
variable = decay_rate_d3
[]
[Pebble_1_DRate_4]
type = PointValue
point = '0 0 0'
variable = decay_rate_d4
[]
[Pebble_1_DRate_5]
type = PointValue
point = '0 0 0'
variable = decay_rate_d5
[]
[Pebble_1_DRate_6]
type = PointValue
point = '0 0 0'
variable = decay_rate_d6
[]
[]
[Executioner]
type = Steady
[]
[Outputs]
execute_on = 'TIMESTEP_END'
csv = true
[]
(test/tests/neutronics/feedback/multi_component_density/openmc.i)
[Mesh]
[file]
type = FileMeshGenerator
file = ../../meshes/pincell.e
[]
[]
[Problem]
type = OpenMCCellAverageProblem
power = 500.0
cell_level = 1
verbose = true
density_variables = 'density1'
density_blocks = '1; 2 3'
temperature_blocks = '1 2 3'
[Tallies]
[Cell]
type = CellTally
block = '1'
[]
[]
[]
[Executioner]
type = Steady
[]
[Outputs]
csv = true
[]
(test/tests/neutronics/filters/polar/cell.i)
[Mesh]
[sphere]
type = FileMeshGenerator
file = ../../meshes/sphere.e
[]
[solid]
type = CombinerGenerator
inputs = sphere
positions = '0 0 0
0 0 4
0 0 8'
[]
[solid_ids]
type = SubdomainIDGenerator
input = solid
subdomain_id = '100'
[]
[fluid]
type = FileMeshGenerator
file = ../../heat_source/stoplight.exo
[]
[fluid_ids]
type = SubdomainIDGenerator
input = fluid
subdomain_id = '200'
[]
[combine]
type = CombinerGenerator
inputs = 'solid_ids fluid_ids'
[]
allow_renumbering = false
[]
[Problem]
type = OpenMCCellAverageProblem
verbose = true
power = 1e4
temperature_blocks = '100'
cell_level = 0
initial_properties = xml
source_rate_normalization = 'kappa_fission'
[Tallies]
[Heating]
type = CellTally
score = 'kappa_fission'
block = '100 200'
[]
[Flux]
type = CellTally
score = 'flux'
block = '100 200'
filters = 'Polar'
[]
[]
[Filters]
[Polar]
type = PolarAngleFilter
[]
[]
[]
[Postprocessors]
[Pebble_1_Flux_Theta1]
type = PointValue
point = '0 0 0'
variable = flux_theta1
[]
[Pebble_2_Flux_Theta1]
type = PointValue
point = '0 0 4'
variable = flux_theta2
[]
[Pebble_3_Flux_Theta1]
type = PointValue
point = '0 0 8'
variable = flux_theta1
[]
[Pebble_1_Flux_Theta2]
type = PointValue
point = '0 0 0'
variable = flux_theta2
[]
[Pebble_2_Flux_Theta2]
type = PointValue
point = '0 0 4'
variable = flux_theta1
[]
[Pebble_3_Flux_Theta2]
type = PointValue
point = '0 0 8'
variable = flux_theta2
[]
[]
[Executioner]
type = Steady
[]
[Outputs]
csv = true
[]
(test/tests/neutronics/indicators/od/openmc_dup.i)
[Mesh]
[sphere]
type = FileMeshGenerator
file = ../../meshes/sphere.e
[]
[solid1]
type = SubdomainIDGenerator
input = sphere
subdomain_id = '100'
[]
allow_renumbering = false
parallel_type = replicated
[]
[Adaptivity/Indicators/optical_depth_cuberoot]
type = ElementOpticalDepthIndicator
rxn_rate = 'total'
h_type = 'cube_root'
[]
[Problem]
type = OpenMCCellAverageProblem
temperature_blocks = '100'
initial_properties = xml
verbose = true
cell_level = 0
power = 100.0
source_rate_normalization = 'kappa_fission'
normalization_tally = 'Cell'
[Tallies]
[Mesh]
type = MeshTally
score = 'kappa_fission flux total'
name = 'mesh_kf mesh_flux mesh_total'
normalize_by_global_tally = false
[]
[Cell]
type = CellTally
score = 'kappa_fission flux total'
name = 'cell_kf cell_flux cell_total'
normalize_by_global_tally = false
[]
[Cell_2]
type = CellTally
score = 'heating'
name = 'cell_2_heating'
normalize_by_global_tally = false
[]
[]
[]
[Executioner]
type = Transient
num_steps = 2
[]
[Postprocessors]
[max_od]
type = ElementExtremeValue
variable = optical_depth_cuberoot
value_type = max
[]
[]
[Outputs]
execute_on = timestep_end
csv = true
[]
(test/tests/userobjects/volume_calculation/no_vol.i)
[Mesh]
[sphere]
type = FileMeshGenerator
file = ../../neutronics/meshes/sphere.e
[]
[solid]
type = CombinerGenerator
inputs = sphere
positions = '0 0 0
0 0 4
0 0 8'
[]
[solid_ids]
type = SubdomainIDGenerator
input = solid
subdomain_id = '100'
[]
[]
[AuxVariables]
[cell_vol]
family = MONOMIAL
order = CONSTANT
[]
[]
[AuxKernels]
[cell_vol]
type = CellVolumeAux
variable = cell_vol
volume_type = actual
[]
[]
[Problem]
type = OpenMCCellAverageProblem
power = 100.0
temperature_blocks = '100'
cell_level = 0
initial_properties = xml
[Tallies]
[Cell]
type = CellTally
block = '100'
name = heat_source
check_tally_sum = false
[]
[]
[]
[Executioner]
type = Steady
[]
[UserObjects]
[vol]
type = OpenMCVolumeCalculation
n_samples = 10000
[]
[]
(test/tests/neutronics/feedback/triso/openmc.i)
[Mesh]
[solid]
type = FileMeshGenerator
file = solid.e
[]
[]
[AuxVariables]
[cell_temperature]
family = MONOMIAL
order = CONSTANT
[]
[]
[AuxKernels]
[cell_temperature]
type = CellTemperatureAux
variable = cell_temperature
[]
[]
[ICs]
[temp]
type = FunctionIC
variable = temp
function = temp_ic
[]
[]
[Functions]
[temp_ic]
type = ParsedFunction
expression = '500.0'
[]
[]
[Problem]
type = OpenMCCellAverageProblem
verbose = true
identical_cell_fills = '2'
check_identical_cell_fills = true
power = 100.0
scaling = 100.0
temperature_blocks = '1 2'
cell_level = 1
[Tallies]
[Cell]
type = CellTally
block = '2'
check_equal_mapped_tally_volumes = true
[]
[]
[]
[Postprocessors]
[k]
type = KEigenvalue
[]
[max_tally_rel_err]
type = TallyRelativeError
value_type = max
[]
[]
[Executioner]
type = Transient
num_steps = 1
[]
[Outputs]
exodus = true
# get a smaller gold file
hide = 'temp'
[]
(test/tests/userobjects/openmc_nuclide_densities/only_density.i)
[Mesh]
[g]
type = GeneratedMeshGenerator
dim = 3
nx = 8
ny = 8
nz = 8
xmin = -12.5
xmax = 87.5
ymin = -12.5
ymax = 37.5
zmin = -12.5
zmax = 12.5
[]
[]
[ICs]
[temp]
type = ConstantIC
variable = temp
value = 500.0
[]
[]
[Problem]
type = OpenMCCellAverageProblem
verbose = true
temperature_blocks = '0'
cell_level = 0
power = 100.0
[Tallies]
[Cell]
type = CellTally
block = '0'
[]
[]
[]
[UserObjects]
[mat1]
type = OpenMCNuclideDensities
material_id = 1
names = 'U235'
densities = '0.04'
[]
[]
[Postprocessors]
[k]
type = KEigenvalue
[]
[]
[Executioner]
type = Steady
[]
[Outputs]
csv = true
[]
(test/tests/userobjects/volume_calculation/openmc.i)
[Mesh]
[sphere]
type = FileMeshGenerator
file = ../../neutronics/meshes/sphere.e
[]
[solid]
type = CombinerGenerator
inputs = sphere
positions = '0 0 0
0 0 4
0 0 8'
[]
[solid_ids]
type = SubdomainIDGenerator
input = solid
subdomain_id = '100'
[]
[fluid]
type = FileMeshGenerator
file = ../../neutronics/heat_source/stoplight.exo
[]
[fluid_ids]
type = SubdomainIDGenerator
input = fluid
subdomain_id = '200'
[]
[combine]
type = CombinerGenerator
inputs = 'solid_ids fluid_ids'
[]
[]
[AuxVariables]
[cell_vol]
family = MONOMIAL
order = CONSTANT
[]
[]
[AuxKernels]
[cell_vol]
type = CellVolumeAux
variable = cell_vol
volume_type = actual
[]
[]
[Problem]
type = OpenMCCellAverageProblem
power = 100.0
temperature_blocks = '100 200'
density_blocks = '200'
verbose = true
cell_level = 0
initial_properties = xml
volume_calculation = vol
[Tallies]
[Cell]
type = CellTally
block = '100 200'
name = heat_source
[]
[]
[]
[UserObjects]
[vol]
type = OpenMCVolumeCalculation
n_samples = 10000
[]
[]
[Executioner]
type = Steady
[]
[Postprocessors]
[vol_1]
type = PointValue
variable = cell_vol
point = '0.0 0.0 0.0'
[]
[vol_2]
type = PointValue
variable = cell_vol
point = '0.0 0.0 4.0'
[]
[vol_3]
type = PointValue
variable = cell_vol
point = '0.0 0.0 8.0'
[]
[vol_4]
type = PointValue
variable = cell_vol
point = '0.0 0.0 2.0'
[]
[]
[Outputs]
csv = true
[]
(doc/content/source/actions/multi_tally_example.i)
[Mesh]
[sphere]
type = FileMeshGenerator
file = mesh_in.e
[]
[]
[Problem]
type = OpenMCCellAverageProblem
particles = 10000
inactive_batches = 100
batches = 1000
initial_properties = xml
verbose = true
cell_level = 0
power = 100.0
source_rate_normalization = 'heating_local'
[Tallies]
[Mesh_Tally]
type = MeshTally
score = 'flux'
[]
[Cell_Tally]
type = CellTally
score = 'heating_local'
[]
[]
[]
[Executioner]
type = Steady
[]
[Outputs]
execute_on = final
exodus = true
[]
(test/tests/neutronics/kinetics/geom_reset/one_bin.i)
[Mesh]
type = FileMesh
file = ../../dagmc/mesh_tallies/slab.e
allow_renumbering = false
[]
[AuxVariables]
[cell_temperature]
family = MONOMIAL
order = CONSTANT
[]
[]
[AuxKernels]
[cell_temperature]
type = CellTemperatureAux
variable = cell_temperature
[]
[]
[AuxKernels]
[temp]
type = ConstantAux
variable = temp
value = 500.0
execute_on = timestep_begin
[]
[]
[Problem]
type = OpenMCCellAverageProblem
verbose = true
temperature_blocks = '1 2'
cell_level = 0
power = 100.0
skinner = moab
calc_kinetics_params = true
ifp_generations = 5
[Tallies]
[Cell]
type = CellTally
block = '1 2'
[]
[]
[]
[UserObjects]
[moab]
type = MoabSkinner
temperature_min = 0.0
temperature_max = 1000.0
n_temperature_bins = 1
temperature = temp
build_graveyard = true
[]
[]
[Postprocessors]
[lambda]
type = LambdaEffective
[]
[lambda_rel]
type = LambdaEffective
output = rel_err
[]
[lambda_std]
type = LambdaEffective
output = std_dev
[]
[beta]
type = BetaEffective
[]
[beta_rel]
type = BetaEffective
output = rel_err
[]
[beta_std]
type = BetaEffective
output = std_dev
[]
[]
[Executioner]
type = Transient
num_steps = 2
[]
[Outputs]
csv = true
execute_on = 'TIMESTEP_END'
[]
(test/tests/neutronics/filters/multi_filter.i)
[Mesh]
[sphere]
type = FileMeshGenerator
file = ../meshes/sphere.e
[]
[solid]
type = CombinerGenerator
inputs = sphere
positions = '0 0 0
0 0 4
0 0 8'
[]
[solid_ids]
type = SubdomainIDGenerator
input = solid
subdomain_id = '100'
[]
[fluid]
type = FileMeshGenerator
file = ../heat_source/stoplight.exo
[]
[fluid_ids]
type = SubdomainIDGenerator
input = fluid
subdomain_id = '200'
[]
[combine]
type = CombinerGenerator
inputs = 'solid_ids fluid_ids'
[]
allow_renumbering = false
[]
[Problem]
type = OpenMCCellAverageProblem
verbose = true
power = 1e4
temperature_blocks = '100'
cell_level = 0
initial_properties = xml
source_rate_normalization = 'kappa_fission'
[Tallies]
[Heating]
type = CellTally
score = 'kappa_fission'
block = '100 200'
[]
[Flux]
type = CellTally
score = 'flux'
block = '100 200'
filters = 'Energy Polar'
[]
[]
[Filters]
[Energy]
type = EnergyFilter
# CASMO 2 group structure for testing. May result in some missed particles
energy_boundaries = '0.0 6.25e-1 2.0e7'
[]
[Polar]
type = PolarAngleFilter
num_equal_divisions = 2
[]
[]
[]
[Postprocessors]
[Pebble_1_Flux_g1_t1]
type = PointValue
point = '0 0 0'
variable = flux_g1_theta1
[]
[Pebble_1_Flux_g2_t1]
type = PointValue
point = '0 0 0'
variable = flux_g2_theta1
[]
[Pebble_1_Flux_g1_t2]
type = PointValue
point = '0 0 0'
variable = flux_g1_theta2
[]
[Pebble_1_Flux_g2_t2]
type = PointValue
point = '0 0 0'
variable = flux_g2_theta2
[]
[]
[Executioner]
type = Steady
[]
[Outputs]
csv = true
[]
(test/tests/openmc_errors/block_mappings/multiple_tally_settings.i)
# This input tests what happens if an OpenMC cell maps to multiple subdomains for
# which the tally settings are different.
[Mesh]
[sphere]
# Mesh of a single pebble with outer radius of 1.5 (cm)
type = FileMeshGenerator
file = ../../neutronics/meshes/sphere.e
[]
[solid]
type = CombinerGenerator
inputs = sphere
positions = '0 0 0
0 0 4
0 0 8.5'
[]
[solid_ids]
type = SubdomainIDGenerator
input = solid
subdomain_id = '100'
[]
[fluid]
# Mesh of the fluid phase; this mesh would be the same as whatever is used to
# solve for the fluid phase
type = FileMeshGenerator
file = stoplight.exo
[]
[fluid_ids]
type = SubdomainIDGenerator
input = fluid
subdomain_id = '200'
[]
[combine]
type = CombinerGenerator
inputs = 'solid_ids fluid_ids'
[]
[]
[Problem]
type = OpenMCCellAverageProblem
power = 70.0
temperature_blocks = '100 200'
cell_level = 0
initial_properties = xml
[Tallies]
[Cell]
type = CellTally
block = '100'
[]
[]
[]
[Executioner]
type = Transient
num_steps = 1
[]
[Outputs]
exodus = true
[]
(test/tests/neutronics/feedback/multi_component_density/openmc_incorrect_length.i)
[Mesh]
type = FileMesh
file = ../../meshes/pincell.e
[]
[ICs]
[density1]
type = ConstantIC
variable = density1
value = 800
blocks = '1 3'
[]
[density2]
type = ConstantIC
variable = density2
value = 600
blocks = '2'
[]
[]
[Problem]
type = OpenMCCellAverageProblem
power = 500.0
density_variables = 'density1; density2'
density_blocks = '1'
temperature_blocks = '1'
[Tallies]
[Cell]
type = CellTally
block = '1'
[]
[]
[]
[Executioner]
type = Transient
[]
(test/tests/neutronics/dagmc/implicit_comp_material/csg_equivalent/openmc.i)
[Mesh]
type = FileMesh
file = ../../mesh_tallies/slab.e
[]
x0 = 12.5
x1 = 37.5
x2 = 62.5
[AuxVariables]
[cell_temperature]
family = MONOMIAL
order = CONSTANT
[]
[]
[AuxKernels]
[cell_temperature]
type = CellTemperatureAux
variable = cell_temperature
[]
[]
T0 = 600.0
dT = 50.0
[Functions]
[temp]
type = ParsedFunction
expression = 'if (x <= ${x0}, ${fparse T0 - dT}, if (x <= ${x1}, ${T0}, if (x <= ${x2}, ${fparse T0 + dT}, ${fparse T0 + 2 * dT})))'
[]
[]
[AuxKernels]
[temp]
type = FunctionAux
variable = temp
function = temp
execute_on = timestep_begin
[]
[]
[Problem]
type = OpenMCCellAverageProblem
verbose = true
temperature_blocks = '1 2'
cell_level = 0
power = 100.0
[Tallies]
[Cell]
type = CellTally
block = '1 2'
[]
[]
[]
[Postprocessors]
[k]
type = KEigenvalue
[]
[]
[Executioner]
type = Transient
num_steps = 2
[]
[Outputs]
exodus = true
[]
(test/tests/neutronics/dagmc/implicit_comp_material/without_graveyard/openmc.i)
[Mesh]
type = FileMesh
file = ../../mesh_tallies/slab.e
allow_renumbering = false
[]
x0 = 12.5
x1 = 37.5
x2 = 62.5
T0 = 600.0
dT = 50.0
[Functions]
[temp]
type = ParsedFunction
expression = 'if (x <= ${x0}, ${fparse T0 - dT}, if (x <= ${x1}, ${T0}, if (x <= ${x2}, ${fparse T0 + dT}, ${fparse T0 + 2 * dT})))'
[]
[]
[AuxKernels]
[temp]
type = FunctionAux
variable = temp
function = temp
execute_on = timestep_begin
[]
[]
[Problem]
type = OpenMCCellAverageProblem
verbose = true
temperature_blocks = '1 2'
cell_level = 1
power = 100.0
skinner = moab
[Tallies]
[Cell]
type = CellTally
block = '1 2'
[]
[]
[]
[UserObjects]
[moab]
type = MoabSkinner
temperature_min = ${fparse T0 - dT}
temperature_max = ${fparse T0 + 2 * dT}
n_temperature_bins = 4
temperature = temp
build_graveyard = false
implicit_complement_material="h2o"
[]
[]
[Postprocessors]
[k]
type = KEigenvalue
[]
[k_std_dev]
type = KEigenvalue
output = 'std_dev'
[]
[]
[Executioner]
type = Steady
[]
[Outputs]
csv = true
[]
(test/tests/neutronics/triggers/multi_rel_err.i)
[Mesh]
[sphere]
type = FileMeshGenerator
file = ../meshes/sphere.e
[]
[solid]
type = CombinerGenerator
inputs = sphere
positions = '0 0 0
0 0 4
0 0 8'
[]
[solid_ids]
type = SubdomainIDGenerator
input = solid
subdomain_id = '100'
[]
[]
[Problem]
type = OpenMCCellAverageProblem
power = 100.0
batches = 20
cell_level = 0
source_rate_normalization = 'kappa_fission'
max_batches = 200
[Tallies]
[Cell]
type = CellTally
block = '100'
score = 'damage_energy kappa_fission'
trigger = 'rel_err rel_err'
trigger_threshold = '2e-2 2e-2'
normalize_by_global_tally = false
[]
[]
[]
[Executioner]
type = Transient
num_steps = 1
[]
[Postprocessors]
[max_err_kf]
type = TallyRelativeError
tally_score = 'kappa_fission'
[]
[max_err_de]
type = TallyRelativeError
tally_score = 'damage_energy'
[]
[]
[Outputs]
csv = true
[]
(test/tests/userobjects/openmc_cell_transform/scaled.i)
[Mesh]
[pin]
type = ConcentricCircleMeshGenerator
num_sectors = 6
radii = '1.0'
rings = '3 3'
has_outer_square = on
pitch = 4.0
preserve_volumes = yes
smoothing_max_it = 3
[]
[assembly]
type = CartesianIDPatternedMeshGenerator
inputs = 'pin'
pattern = '0 0;
0 0'
assign_type = 'cell'
id_name = 'pin_id'
[]
[delete]
# Only keeping block 1 (fuel pins) for this test
type = BlockDeletionGenerator
input = assembly
block = 2
[]
[extrude]
type = AdvancedExtruderGenerator
input = delete
direction = '0 0 1'
heights = '30'
num_layers = 1
[]
[translate]
type = TransformGenerator
input = extrude
transform = TRANSLATE_CENTER_ORIGIN
vector_value = '-12 12 0'
[]
[scale_to_m]
type = TransformGenerator
input = translate
transform = SCALE
vector_value = '0.01 0.01 0.01'
[]
[]
[GlobalParams]
displacements = 'disp_x disp_y disp_z'
use_displaced_mesh = true
[]
[Problem]
type = OpenMCCellAverageProblem
cell_level = 2
verbose = true
power = 100
scaling = 100.0
[Tallies]
[heat]
type = CellTally
score = 'kappa_fission'
block = '1'
[]
[]
[]
[AuxVariables]
[disp_x]
[AuxKernel]
type = FunctionAux
variable = disp_x
function = disp_x_fn
execute_on = 'timestep_begin'
[]
[]
[disp_y]
[AuxKernel]
type = FunctionAux
variable = disp_y
function = disp_y_fn
execute_on = 'timestep_begin'
[]
[]
[disp_z]
[]
[]
[Functions]
[disp_x_fn]
type = ParsedFunction
expression = '1e-2*2*t'
[]
[disp_y_fn]
type = ParsedFunction
expression = '1e-2*2*t'
[]
[]
[Postprocessors]
[shift_x]
type = FunctionValuePostprocessor
function = disp_x_fn
execute_on = 'timestep_begin'
[]
[shift_y]
type = FunctionValuePostprocessor
function = disp_y_fn
execute_on = 'timestep_begin'
[]
[k]
type = KEigenvalue
[]
[power]
type = ElementIntegralVariablePostprocessor
variable = kappa_fission
block = '1'
[]
[]
[UserObjects]
[translate_cells]
type = OpenMCCellTransform
transform_type = 'translation'
vector_value = 'shift_x shift_y 0'
cell_ids = '2011'
execute_on = 'timestep_begin'
[]
[]
[Executioner]
type = Transient
num_steps = 2
[]
[Outputs]
exodus = true
[]
(test/tests/neutronics/filters/xml/cell.i)
[Mesh]
[sphere]
type = FileMeshGenerator
file = ../../meshes/sphere.e
[]
[solid]
type = CombinerGenerator
inputs = sphere
positions = '0 0 0
0 0 4
0 0 8'
[]
[solid_ids]
type = SubdomainIDGenerator
input = solid
subdomain_id = '100'
[]
[fluid]
type = FileMeshGenerator
file = ../../heat_source/stoplight.exo
[]
[fluid_ids]
type = SubdomainIDGenerator
input = fluid
subdomain_id = '200'
[]
[combine]
type = CombinerGenerator
inputs = 'solid_ids fluid_ids'
[]
allow_renumbering = false
[]
[Problem]
type = OpenMCCellAverageProblem
verbose = true
power = 1e4
temperature_blocks = '100'
cell_level = 0
initial_properties = xml
source_rate_normalization = 'kappa_fission'
[Tallies]
[Heating]
type = CellTally
score = 'kappa_fission'
block = '100 200'
check_tally_sum = false
normalize_by_global_tally = true
[]
[Flux]
type = CellTally
score = 'flux'
block = '100 200'
filters = 'SPH_XML'
check_tally_sum = false
normalize_by_global_tally = true
[]
[]
[Filters]
[SPH_XML]
type = FromXMLFilter
filter_id = 1
bin_label = 'sph'
allow_expansion_filters = true
[]
[]
[]
[Postprocessors]
[Pebble_1_Flux_l0_m0]
type = PointValue
point = '0 0 0'
variable = flux_sph1
[]
[Pebble_1_Flux_l1_mn1]
type = PointValue
point = '0 0 0'
variable = flux_sph2
[]
[Pebble_1_Flux_l1_m0]
type = PointValue
point = '0 0 0'
variable = flux_sph3
[]
[Pebble_1_Flux_l1_m1]
type = PointValue
point = '0 0 0'
variable = flux_sph4
[]
[]
[Executioner]
type = Steady
[]
[Outputs]
csv = true
[]
(test/tests/neutronics/relaxation/cell_tallies/dufek_gudowski.i)
[Mesh]
[pebble]
type = FileMeshGenerator
file = ../../meshes/sphere_in_m.e
[]
[repeat]
type = CombinerGenerator
inputs = pebble
positions = '0 0 0.02
0 0 0.06
0 0 0.10'
[]
[set_block_ids]
type = SubdomainIDGenerator
input = repeat
subdomain_id = 0
[]
[]
[AuxKernels]
[temp]
type = FunctionAux
variable = temp
function = axial
execute_on = initial
[]
[]
[Functions]
[axial]
type = ParsedFunction
expression = '500 + z / 0.10 * 100'
[]
[]
[Problem]
type = OpenMCCellAverageProblem
verbose = true
power = 100.0
temperature_blocks = '0'
cell_level = 1
scaling = 100.0
relaxation = dufek_gudowski
first_iteration_particles = 1000
[Tallies]
[Cell]
type = CellTally
block = '0'
[]
[]
[]
[Executioner]
type = Transient
num_steps = 3
[]
[Outputs]
csv = true
exodus = true
[]
[Postprocessors]
[heat_source]
type = ElementIntegralVariablePostprocessor
variable = kappa_fission
[]
[p1]
type = PointValue
variable = kappa_fission
point = '0.0 0.0 0.02'
[]
[p2]
type = PointValue
variable = kappa_fission
point = '0.0 0.0 0.06'
[]
[p3]
type = PointValue
variable = kappa_fission
point = '0.0 0.0 0.10'
[]
[]
(doc/content/source/problems/smallest_openmc_input.i)
[Mesh]
type = FileMesh
file = pincell.e
[]
[Problem]
type = OpenMCCellAverageProblem
power = 1000.0
temperature_blocks = '1 2 3'
density_blocks = '3'
cell_level = 0
[Tallies]
[Cell]
type = CellTally
blocks = '1'
[]
[]
[]
[Executioner]
type = Transient
[]
[Outputs]
exodus = true
[]
(test/tests/neutronics/fixed_source/flux.i)
[Mesh]
[sphere]
type = FileMeshGenerator
file = ../meshes/sphere.e
[]
[solid]
type = CombinerGenerator
inputs = sphere
positions = '0 0 0
0 0 4
0 0 8'
[]
[solid_ids]
type = SubdomainIDGenerator
input = solid
subdomain_id = '100'
[]
[fluid]
type = FileMeshGenerator
file = ../heat_source/stoplight.exo
[]
[fluid_ids]
type = SubdomainIDGenerator
input = fluid
subdomain_id = '200'
[]
[combine]
type = CombinerGenerator
inputs = 'solid_ids fluid_ids'
[]
[]
[Problem]
type = OpenMCCellAverageProblem
verbose = true
source_strength = 1e12
temperature_blocks = '100 200'
density_blocks = '200'
cell_level = 0
initial_properties = xml
[Tallies]
[Cell]
type = CellTally
score = flux
block = '100 200'
[]
[]
[]
[Executioner]
type = Transient
num_steps = 1
[]
[Postprocessors]
[vol_solid]
type = VolumePostprocessor
block = '100'
[]
[vol_fluid]
type = VolumePostprocessor
block = '200'
[]
[flux_pebble1]
type = PointValue
variable = flux
point = '0 0 0'
[]
[flux_pebble2]
type = PointValue
variable = flux
point = '0 0 4'
[]
[flux_pebble3]
type = PointValue
variable = flux
point = '0 0 8'
[]
[flux_fluid]
type = PointValue
variable = flux
point = '0 0 2'
[]
[]
[Outputs]
csv = true
[]
(test/tests/neutronics/flux/missing_norm.i)
[Mesh]
[sphere]
type = FileMeshGenerator
file = ../meshes/sphere.e
[]
[solid]
type = CombinerGenerator
inputs = sphere
positions = '0 0 0
0 0 4
0 0 8'
[]
[solid_ids]
type = SubdomainIDGenerator
input = solid
subdomain_id = '100'
[]
[]
[Problem]
type = OpenMCCellAverageProblem
verbose = true
power = 1e4
temperature_blocks = '100'
cell_level = 0
initial_properties = xml
[Tallies]
[Cell]
type = CellTally
score = 'heating flux H3_production'
block = '100'
[]
[]
[]
[Executioner]
type = Steady
[]
(test/tests/neutronics/dagmc/with_csg/dag_cell_not_root/openmc.i)
[Mesh]
[slab]
type = FileMeshGenerator
file = ../../mesh_tallies/slab.e
[]
allow_renumbering = false
parallel_type = replicated
[]
[AuxVariables]
[cell_temperature]
family = MONOMIAL
order = CONSTANT
[]
[]
[AuxKernels]
[cell_temperature]
type = CellTemperatureAux
variable = cell_temperature
[]
[]
[AuxKernels]
[temp]
type = ConstantAux
variable = temp
value = 500.0
execute_on = timestep_begin
[]
[]
[Problem]
type = OpenMCCellAverageProblem
verbose = true
temperature_blocks = '1 2'
cell_level = 1
power = 100.0
skinner = moab
[Tallies]
[Cell]
type = CellTally
block = '1 2'
[]
[]
[]
[UserObjects]
[moab]
type = MoabSkinner
temperature_min = 0.0
temperature_max = 1000.0
n_temperature_bins = 1
temperature = temp
build_graveyard = true
[]
[]
[Postprocessors]
[k]
type = KEigenvalue
[]
[]
[Executioner]
type = Transient
num_steps = 2
[]
[Outputs]
exodus = true
hide = 'temp'
[]
(test/tests/neutronics/feedback/different_units/openmc.i)
[Mesh]
type = FileMesh
file = sphere_in_m.e
[]
[AuxVariables]
[cell_temperature]
family = MONOMIAL
order = CONSTANT
[]
[material_id]
family = MONOMIAL
order = CONSTANT
[]
[cell_density]
family = MONOMIAL
order = CONSTANT
[]
[]
[AuxKernels]
[material_id]
type = CellMaterialIDAux
variable = material_id
[]
[cell_temperature]
type = CellTemperatureAux
variable = cell_temperature
execute_on = 'timestep_end'
[]
[cell_density]
type = CellDensityAux
variable = cell_density
execute_on = 'timestep_end'
[]
[]
[Problem]
type = OpenMCCellAverageProblem
verbose = true
power = 1e6
temperature_blocks = '1'
density_blocks = '1'
cell_level = 0
scaling = 100.0
[Tallies]
[Cell]
type = CellTally
block = '1'
[]
[]
[]
[Executioner]
type = Transient
[]
[Postprocessors]
[heat_source]
type = ElementIntegralVariablePostprocessor
variable = kappa_fission
[]
[]
[Outputs]
exodus = true
[]
(test/tests/neutronics/tally_system/multi_diff.i)
[Mesh]
[sphere]
type = FileMeshGenerator
file = ../meshes/sphere.e
[]
[solid]
type = CombinerGenerator
inputs = sphere
positions = '0 0 0'
[]
[solid_ids]
type = SubdomainIDGenerator
input = solid
subdomain_id = '100'
[]
allow_renumbering = false
[]
[Problem]
type = OpenMCCellAverageProblem
verbose = true
power = 1e4
temperature_blocks = '100'
cell_level = 0
initial_properties = xml
source_rate_normalization = 'kappa_fission'
[Tallies]
[Cell]
type = CellTally
score = 'kappa_fission'
block = '100'
# The global tally check is disabled because we have a loosely fitting unstructured mesh tally.
normalize_by_global_tally = false
[]
[Mesh]
type = MeshTally
score = 'flux'
mesh_translations = '0 0 0'
mesh_template = ../meshes/sphere.e
# The global tally check is disabled because we have a loosely fitting unstructured mesh tally.
normalize_by_global_tally = false
[]
[]
[]
[Executioner]
type = Steady
[]
[Outputs]
exodus = true
[]
(test/tests/postprocessors/openmc_particles/openmc.i)
[Mesh]
[pebble]
type = FileMeshGenerator
file = ../../neutronics/meshes/sphere_in_m.e
[]
[repeat]
type = CombinerGenerator
inputs = pebble
positions = '0 0 0.02
0 0 0.06
0 0 0.10'
[]
[]
[Problem]
type = OpenMCCellAverageProblem
verbose = true
power = 100.0
temperature_blocks = '100'
cell_level = 1
scaling = 100.0
relaxation = dufek_gudowski
first_iteration_particles = 500
initial_properties = xml
[Tallies]
[Cell]
type = CellTally
block = '100'
[]
[]
[]
[Executioner]
type = Transient
num_steps = 3
[]
[Outputs]
csv = true
[]
[Postprocessors]
[particles]
type = OpenMCParticles
value_type = instantaneous
[]
[particles_total]
type = OpenMCParticles
value_type = total
[]
[]
(tutorials/openmc_subchannel/openmc/openmc.i)
!include ../common.i
[Mesh]
[file]
type = FileMeshGenerator
file = ../meshes/mesh_in.e
[]
[]
[Problem]
type = OpenMCCellAverageProblem
power = ${power}
lowest_cell_level = 2
scaling = 100
temperature_blocks = 'helium fuel clad sodium'
density_blocks = 'sodium'
[Tallies]
[power]
type = CellTally
score = 'kappa_fission'
[]
[]
[]
[ICs]
[temp]
type = ConstantIC
variable = temp
value = ${inlet_temperature}
[]
[density]
type = ConstantIC
variable = density
value = ${fparse 1.00423e3 + -0.21390*inlet_temperature+-1.1046e-5*inlet_temperature^2}
[]
[]
[AuxVariables]
[cell_temperature]
family = MONOMIAL
order = CONSTANT
[]
[cell_density]
family = MONOMIAL
order = CONSTANT
[]
[]
[AuxKernels]
[cell_temperature]
type = CellTemperatureAux
variable = cell_temperature
[]
[cell_density]
type = CellDensityAux
variable = cell_density
[]
[]
[Executioner]
type = Steady
[]
[Outputs]
exodus = true
[]
(test/tests/userobjects/openmc_cell_transform/translate_cells.i)
[Mesh]
[pin]
type = ConcentricCircleMeshGenerator
num_sectors = 6
radii = '1.0'
rings = '3 3'
has_outer_square = on
pitch = 4.0
preserve_volumes = yes
smoothing_max_it = 3
[]
[assembly]
type = CartesianIDPatternedMeshGenerator
inputs = 'pin'
pattern = '0 0;
0 0'
assign_type = 'cell'
id_name = 'pin_id'
[]
[delete]
# Only keeping block 1 (fuel pins) for this test
type = BlockDeletionGenerator
input = assembly
block = 2
[]
[extrude]
type = AdvancedExtruderGenerator
input = delete
direction = '0 0 1'
heights = '30'
num_layers = 1
[]
[translate]
type = TransformGenerator
input = extrude
transform = TRANSLATE_CENTER_ORIGIN
vector_value = '-12 12 0'
[]
[]
[GlobalParams]
displacements = 'disp_x disp_y disp_z'
use_displaced_mesh = true
[]
[Problem]
type = OpenMCCellAverageProblem
cell_level = 2
verbose = true
power = 100
[Tallies]
[heat]
type = CellTally
score = 'kappa_fission'
block = '1'
[]
[]
[]
[AuxVariables]
[disp_x]
[AuxKernel]
type = FunctionAux
variable = disp_x
function = disp_x_fn
execute_on = 'timestep_begin'
[]
[]
[disp_y]
[AuxKernel]
type = FunctionAux
variable = disp_y
function = disp_y_fn
execute_on = 'timestep_begin'
[]
[]
[disp_z]
[]
[]
[Functions]
[disp_x_fn]
type = ParsedFunction
expression = '2*t'
[]
[disp_y_fn]
type = ParsedFunction
expression = '2*t'
[]
[]
[Postprocessors]
[shift_x]
type = FunctionValuePostprocessor
function = disp_x_fn
execute_on = 'timestep_begin'
[]
[shift_y]
type = FunctionValuePostprocessor
function = disp_y_fn
execute_on = 'timestep_begin'
[]
[k]
type = KEigenvalue
[]
[power]
type = ElementIntegralVariablePostprocessor
variable = kappa_fission
block = '1'
[]
[]
[UserObjects]
[translate_cells]
type = OpenMCCellTransform
transform_type = 'translation'
vector_value = 'shift_x shift_y 0'
cell_ids = '2011'
execute_on = 'timestep_begin'
[]
[]
[Executioner]
type = Transient
num_steps = 2
[]
[Outputs]
exodus = true
[]
(test/tests/neutronics/dagmc/cell_tallies/csg_step_1/openmc.i)
[Mesh]
type = FileMesh
file = ../../mesh_tallies/slab.e
[]
[AuxVariables]
[cell_temperature]
family = MONOMIAL
order = CONSTANT
[]
[material_id]
family = MONOMIAL
order = CONSTANT
[]
[]
[AuxKernels]
[cell_temperature]
type = CellTemperatureAux
variable = cell_temperature
[]
[material_id]
type = CellMaterialIDAux
variable = material_id
[]
[]
[AuxKernels]
[temp]
type = ConstantAux
variable = temp
value = 500.0
execute_on = timestep_begin
[]
[]
[Problem]
type = OpenMCCellAverageProblem
verbose = true
temperature_blocks = '1 2'
cell_level = 0
power = 100.0
[Tallies]
[Cell]
type = CellTally
block = '1 2'
[]
[]
[]
[Postprocessors]
[k]
type = KEigenvalue
[]
[]
[Executioner]
type = Transient
num_steps = 2
[]
[Outputs]
exodus = true
[]
(test/tests/neutronics/adaptivity/cell.i)
[Mesh]
[sphere]
type = FileMeshGenerator
file = ../meshes/sphere.e
[]
[solid]
type = CombinerGenerator
inputs = sphere
positions = '0 0 0'
[]
[solid_ids]
type = SubdomainIDGenerator
input = solid
subdomain_id = '100'
[]
[]
[Adaptivity]
steps = 1
marker = uniform
[Markers/uniform]
type = UniformMarker
mark = refine
[]
[]
[Problem]
type = OpenMCCellAverageProblem
verbose = true
power = 1e4
temperature_blocks = '100'
cell_level = 0
initial_properties = xml
[Tallies]
[Cell]
type = CellTally
score = kappa_fission
block = '100'
normalize_by_global_tally = false
[]
[]
[]
[Executioner]
type = Steady
[]
[Outputs]
exodus = true
execute_on = timestep_end
hide = 'temp cell_instance'
[]
(test/tests/postprocessors/reactivity/openmc.i)
[Mesh]
[sphere]
type = FileMeshGenerator
file = ../../neutronics/meshes/sphere.e
[]
[solid]
type = CombinerGenerator
inputs = sphere
positions = '0 0 0
0 0 4
0 0 8'
[]
[solid_ids]
type = SubdomainIDGenerator
input = solid
subdomain_id = '100'
[]
[]
[Problem]
type = OpenMCCellAverageProblem
power = 100.0
temperature_blocks = '100'
cell_level = 0
initial_properties = xml
[Tallies]
[Cell]
type = CellTally
block = '100'
check_tally_sum = false
[]
[]
[]
[Executioner]
type = Transient
num_steps = 1
[]
[Postprocessors]
[k_collision]
type = KEigenvalue
value_type = 'collision'
[]
[k_absorption]
type = KEigenvalue
value_type = 'absorption'
[]
[k_tracklength]
type = KEigenvalue
value_type = 'tracklength'
[]
[k_combined]
type = KEigenvalue
value_type = 'combined'
[]
[reactivity_collision]
type = Reactivity
value_type = 'collision'
[]
[reactivity_absorption]
type = Reactivity
value_type = 'absorption'
[]
[reactivity_tracklength]
type = Reactivity
value_type = 'tracklength'
[]
[reactivity_combined]
type = Reactivity
value_type = 'combined'
[]
[]
[Outputs]
csv = true
[]