- assume_separate_talliesFalseWhether to assume that all tallies added in the XML files or by Cardinal are spatially separate. This is a performance optimization
Default:False
C++ Type:bool
Controllable:No
Description:Whether to assume that all tallies added in the XML files or by Cardinal are spatially separate. This is a performance optimization
- batch_interval1Trigger batch interval
Default:1
C++ Type:unsigned int
Range:batch_interval > 0
Controllable:No
Description:Trigger batch interval
- batchesNumber of batches to run in OpenMC; this overrides the setting in the XML files.
C++ Type:unsigned int
Range:batches > 0
Controllable:No
Description:Number of batches to run in OpenMC; this overrides the setting in the XML files.
- blockANY_BLOCK_ID List of subdomains for kernel coverage and material coverage checks. Setting this parameter is equivalent to setting 'kernel_coverage_block_list' and 'material_coverage_block_list' as well as using 'ONLY_LIST' as the coverage check mode.
Default:ANY_BLOCK_ID
C++ Type:std::vector<SubdomainName>
Controllable:No
Description:List of subdomains for kernel coverage and material coverage checks. Setting this parameter is equivalent to setting 'kernel_coverage_block_list' and 'material_coverage_block_list' as well as using 'ONLY_LIST' as the coverage check mode.
- calc_kinetics_paramsFalseWhether or not Cardinal should enable the calculation of kinetics parameters (Lambda effective and beta effective).
Default:False
C++ Type:bool
Controllable:No
Description:Whether or not Cardinal should enable the calculation of kinetics parameters (Lambda effective and beta effective).
- cell_levelCoordinate level in OpenMC (across the entire geometry) to use for identifying cells
C++ Type:unsigned int
Controllable:No
Description:Coordinate level in OpenMC (across the entire geometry) to use for identifying cells
- check_identical_cell_fillsFalseWhether to check that your model does indeed have identical cell fills, allowing you to set 'identical_cell_fills' to speed up initialization
Default:False
C++ Type:bool
Controllable:No
Description:Whether to check that your model does indeed have identical cell fills, allowing you to set 'identical_cell_fills' to speed up initialization
- density_blocksBlocks corresponding to each of the 'density_variables'. If not specified, there will be no density feedback to OpenMC.
C++ Type:std::vector<std::vector<SubdomainName>>
Controllable:No
Description:Blocks corresponding to each of the 'density_variables'. If not specified, there will be no density feedback to OpenMC.
- density_variablesVector of variable names corresponding to the densities sent into OpenMC. Each entry maps to the corresponding entry in 'density_blocks.' If not specified, each entry defaults to 'density'
C++ Type:std::vector<std::vector<std::string>>
Controllable:No
Description:Vector of variable names corresponding to the densities sent into OpenMC. Each entry maps to the corresponding entry in 'density_blocks.' If not specified, each entry defaults to 'density'
- export_propertiesFalseWhether to export OpenMC's temperature and density properties to an HDF5 file after updating them from MOOSE.
Default:False
C++ Type:bool
Controllable:No
Description:Whether to export OpenMC's temperature and density properties to an HDF5 file after updating them from MOOSE.
- first_iteration_particlesNumber of particles to use for first iteration when using Dufek-Gudowski relaxation
C++ Type:int
Controllable:No
Description:Number of particles to use for first iteration when using Dufek-Gudowski relaxation
- identical_cell_fillsBlocks on which the OpenMC cells have identical fill universes; this is an optimization to speed up initialization for TRISO problems while also reducing memory usage. It is assumed that any cell which maps to one of these subdomains has exactly the same universe filling it as all other cells which map to these subdomains. We HIGHLY recommend that the first time you try using this, that you also set 'check_identical_cell_fills = true' to catch any possible user errors which would exclude you from using this option safely.
C++ Type:std::vector<SubdomainName>
Controllable:No
Description:Blocks on which the OpenMC cells have identical fill universes; this is an optimization to speed up initialization for TRISO problems while also reducing memory usage. It is assumed that any cell which maps to one of these subdomains has exactly the same universe filling it as all other cells which map to these subdomains. We HIGHLY recommend that the first time you try using this, that you also set 'check_identical_cell_fills = true' to catch any possible user errors which would exclude you from using this option safely.
- ifp_generations10The number of generations to use with the method of iterated fission probabilities.
Default:10
C++ Type:unsigned int
Controllable:No
Description:The number of generations to use with the method of iterated fission probabilities.
- inactive_batchesNumber of inactive batches to run in OpenMC; this overrides the setting in the XML files.
C++ Type:unsigned int
Range:inactive_batches >= 0
Controllable:No
Description:Number of inactive batches to run in OpenMC; this overrides the setting in the XML files.
- initial_propertiesmooseWhere to read the temperature and density initial conditions for OpenMC
Default:moose
C++ Type:MooseEnum
Controllable:No
Description:Where to read the temperature and density initial conditions for OpenMC
- k_triggernoneTrigger criterion to determine when OpenMC simulation is complete based on k
Default:none
C++ Type:MooseEnum
Controllable:No
Description:Trigger criterion to determine when OpenMC simulation is complete based on k
- k_trigger_thresholdThreshold for the k trigger
C++ Type:double
Unit:(no unit assumed)
Range:k_trigger_threshold > 0
Controllable:No
Description:Threshold for the k trigger
- lowest_cell_levelLowest coordinate level in OpenMC to use for identifying cells. The cell level for coupling will use the value set with this parameter unless the geometry does not have that many layers of geometry nesting, in which case the locally lowest depth is used
C++ Type:unsigned int
Controllable:No
Description:Lowest coordinate level in OpenMC to use for identifying cells. The cell level for coupling will use the value set with this parameter unless the geometry does not have that many layers of geometry nesting, in which case the locally lowest depth is used
- max_batchesMaximum number of batches, when using triggers
C++ Type:unsigned int
Range:max_batches > 0
Controllable:No
Description:Maximum number of batches, when using triggers
- normalization_tallyThe name of a tally added in [Talliies] to be used when normalizing results in eigenvalue calculations. This tally object must contain the score specified in 'source_rate_normalization'.
C++ Type:std::string
Controllable:No
Description:The name of a tally added in [Talliies] to be used when normalizing results in eigenvalue calculations. This tally object must contain the score specified in 'source_rate_normalization'.
- 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)
- openmc_verbosityOpenMC verbosity level; this overrides the setting in the XML files. Note that we cannot influence the verbosity of OpenMC's initialization routines, since these are run before Cardinal is initialized.
C++ Type:unsigned int
Range:openmc_verbosity >= 1 & openmc_verbosity <= 10
Controllable:No
Description:OpenMC verbosity level; this overrides the setting in the XML files. Note that we cannot influence the verbosity of OpenMC's initialization routines, since these are run before Cardinal is initialized.
- output_cell_mappingTrueWhether to automatically output the mapping from OpenMC cells to the [Mesh], usually for diagnostic purposes
Default:True
C++ Type:bool
Controllable:No
Description:Whether to automatically output the mapping from OpenMC cells to the [Mesh], usually for diagnostic purposes
- particlesNumber of particles to run in each OpenMC batch; this overrides the setting in the XML files.
C++ Type:PostprocessorName
Unit:(no unit assumed)
Controllable:No
Description:Number of particles to run in each OpenMC batch; this overrides the setting in the XML files.
- powerPower (Watts) to normalize the OpenMC tallies; only used for k-eigenvalue mode
C++ Type:PostprocessorName
Unit:(no unit assumed)
Controllable:No
Description:Power (Watts) to normalize the OpenMC tallies; only used for k-eigenvalue mode
- regard_general_exceptions_as_errorsFalseIf we catch an exception during residual/Jacobian evaluaton for which we don't have specific handling, immediately error instead of allowing the time step to be cut
Default:False
C++ Type:bool
Controllable:No
Description:If we catch an exception during residual/Jacobian evaluaton for which we don't have specific handling, immediately error instead of allowing the time step to be cut
- relaxationnoneType of relaxation to apply to the OpenMC solution
Default:none
C++ Type:MooseEnum
Controllable:No
Description:Type of relaxation to apply to the OpenMC solution
- relaxation_factor0.5Relaxation factor for use with constant relaxation
Default:0.5
C++ Type:double
Unit:(no unit assumed)
Range:relaxation_factor > 0.0 & relaxation_factor < 2.0
Controllable:No
Description:Relaxation factor for use with constant relaxation
- reset_seedFalseWhether to reset OpenMC's seed to the initial starting seed before each OpenMC solve
Default:False
C++ Type:bool
Controllable:No
Description:Whether to reset OpenMC's seed to the initial starting seed before each OpenMC solve
- reuse_sourceFalseWhether to take the initial fission source for interation n to be the converged source bank from iteration n-1
Default:False
C++ Type:bool
Controllable:No
Description:Whether to take the initial fission source for interation n to be the converged source bank from iteration n-1
- scaling1Scaling factor to apply to [Mesh] to get to units of centimeters that OpenMC expects; setting 'scaling = 100.0', for instance, indicates that the [Mesh] is in units of meters
Default:1
C++ Type:double
Unit:(no unit assumed)
Range:scaling > 0.0
Controllable:No
Description:Scaling factor to apply to [Mesh] to get to units of centimeters that OpenMC expects; setting 'scaling = 100.0', for instance, indicates that the [Mesh] is in units of meters
- skinnerWhen using DAGMC geometries, an optional skinner that will regenerate the OpenMC geometry on-the-fly according to iso-contours of temperature and density
C++ Type:UserObjectName
Controllable:No
Description:When using DAGMC geometries, an optional skinner that will regenerate the OpenMC geometry on-the-fly according to iso-contours of temperature and density
- skip_statepointFalseWhether to skip writing any statepoint files from OpenMC; this is a performance optimization for scenarios where you may not want the statepoint files anyways
Default:False
C++ Type:bool
Controllable:No
Description:Whether to skip writing any statepoint files from OpenMC; this is a performance optimization for scenarios where you may not want the statepoint files anyways
- solveTrueWhether or not to actually solve the Nonlinear system. This is handy in the case that all you want to do is execute AuxKernels, Transfers, etc. without actually solving anything
Default:True
C++ Type:bool
Controllable:Yes
Description:Whether or not to actually solve the Nonlinear system. This is handy in the case that all you want to do is execute AuxKernels, Transfers, etc. without actually solving anything
- source_rate_normalizationScore to use for computing the particle source rate (source/sec) for a certain tallies in eigenvalue mode. In other words, the source/sec is computed as (power divided by the global value of this tally)
C++ Type:MooseEnum
Controllable:No
Description:Score to use for computing the particle source rate (source/sec) for a certain tallies in eigenvalue mode. In other words, the source/sec is computed as (power divided by the global value of this tally)
- source_strengthNeutrons/second to normalize the OpenMC tallies; only used for fixed source mode
C++ Type:PostprocessorName
Unit:(no unit assumed)
Controllable:No
Description:Neutrons/second to normalize the OpenMC tallies; only used for fixed source mode
- symmetry_mapperUser object (of type SymmetryPointGenerator) to map from a symmetric OpenMC model to a full-domain [Mesh]. For example, you can use this to map from a quarter-symmetric OpenMC model to a whole-domain [Mesh].
C++ Type:UserObjectName
Controllable:No
Description:User object (of type SymmetryPointGenerator) to map from a symmetric OpenMC model to a full-domain [Mesh]. For example, you can use this to map from a quarter-symmetric OpenMC model to a whole-domain [Mesh].
- tally_typeType of tally to use in OpenMC
C++ Type:MooseEnum
Controllable:No
Description:Type of tally to use in OpenMC
- temperature_blocksBlocks corresponding to each of the 'temperature_variables'. If not specified, there will be no temperature feedback to OpenMC.
C++ Type:std::vector<std::vector<SubdomainName>>
Controllable:No
Description:Blocks corresponding to each of the 'temperature_variables'. If not specified, there will be no temperature feedback to OpenMC.
- temperature_variablesVector of variable names corresponding to the temperatures sent into OpenMC. Each entry maps to the corresponding entry in 'temperature_blocks.' If not specified, each entry defaults to 'temp'
C++ Type:std::vector<std::vector<std::string>>
Controllable:No
Description:Vector of variable names corresponding to the temperatures sent into OpenMC. Each entry maps to the corresponding entry in 'temperature_blocks.' If not specified, each entry defaults to 'temp'
- verboseFalseWhether to print diagnostic information
Default:False
C++ Type:bool
Controllable:No
Description:Whether to print diagnostic information
- volume_calculationUser object that will perform a stochastic volume calculation to get the OpenMC cell volumes. This can be used to check that the MOOSE regions to which the cells map are of approximately the same volume as the true cells.
C++ Type:UserObjectName
Controllable:No
Description:User object that will perform a stochastic volume calculation to get the OpenMC cell volumes. This can be used to check that the MOOSE regions to which the cells map are of approximately the same volume as the true cells.
- xml_directory./The directory in which to look for OpenMC XML files.
Default:./
C++ Type:FileName
Controllable:No
Description:The directory in which to look for OpenMC XML files.
OpenMCCellAverageProblem
This class couples OpenMC cell-based models (e.g. CSG or DAGMC) to MOOSE. The crux is to identify a mapping between OpenMC cells and a MooseMesh. The data flow contains two major steps:
Temperature and/or density field data on the MooseMesh are volume-averaged and applied to the corresponding OpenMC cells.
Tallies are mapped from OpenMC into
CONSTANT MONOMIALfields on the MooseMesh through the tally system.
The smallest possible input file to run OpenMC is shown below. This page describes this syntax, plus more advanced settings.
Listing 1: Smallest possible OpenMC wrapped input file.
[Mesh<<<{"href": "../../syntax/Mesh/index.html"}>>>]
type = FileMesh
file = pincell.e
[]
[Problem<<<{"href": "../../syntax/Problem/index.html"}>>>]
type = OpenMCCellAverageProblem
power = 1000.0
temperature_blocks = '1 2 3'
density_blocks = '3'
cell_level = 0
[Tallies<<<{"href": "../../syntax/Problem/Tallies/index.html"}>>>]
[Cell]
type = CellTally<<<{"description": "A class which implements distributed cell tallies.", "href": "../tallies/CellTally.html"}>>>
blocks<<<{"description": "This parameter is deprecated, use 'block' instead!"}>>> = '1'
[]
[]
[]
[Executioner<<<{"href": "../../syntax/Executioner/index.html"}>>>]
type = Transient
[]
[Outputs<<<{"href": "../../syntax/Outputs/index.html"}>>>]
exodus<<<{"description": "Output the results using the default settings for Exodus output."}>>> = true
[](doc/content/source/problems/smallest_openmc_input.i)Initializing Variables
We first initialize (MooseVariables) to communicate OpenMC's solution with MOOSE. These variables will be viewable in the MOOSE output files (e.g., via Paraview). Depending on the user settings, the following CONSTANT MONOMIAL variables will be added:
Variable(s) representing the OpenMC tally(s) added by the
[Tallies]blockVariable(s) representing the temperature to read into OpenMC. Temperature will be read from the mesh subdomains indicated by
temperature_blocks.Variable(s) representing the density to read into OpenMC. Density will be read from the mesh subdomains indicated by
density_blocks.A variable (
cell_id) storing the mapping of OpenMC cell IDs onto the meshA variable (
cell_instance) storing the mapping of OpenMC cell instances onto the mesh
These variables have default names, but you can also control their names using the temperature_variables, and density_variables parameters. The names of the tally variables can be customized with the tally_name parameter in each tally object. If you want to see the names, run with verbose = true and tables will print out on initialization with this information.
You do not need to add/initialize ANY of these variables manually - it all happens behind the scenes!
As an example, let's start with a complicated case first. Suppose our [Problem] block looks like the following. We want to apply temperature feedback from four blocks (fuel, cladding, water, helium). We also want to apply density feedback, but only from two blocks (water and fluid). Suppose we also want to keep separate track of different variables representing each of these physical fields, so we will want to read temperature from a variable named temp0 in the fuel and cladding blocks, but from a variable named nek_temp in the helium block (and so on for density).
[Problem]
type = OpenMCCellAverageProblem
temperature_variables = 'temp0; t_water; nek_temp'
temperature_blocks = 'fuel cladding; water; helium'
density_variables = 'rho_water; rho_helium'
density_blocks = 'water; helium'
[Tallies]
[cell_tally]
type = CellTally
score = 'heating flux'
name = 'power openmc_flux'
[]
[]
[]
Then Cardinal is building the following automatically for you:
[AuxVariables]
[temp0] # added for all corresponding 'temperature_blocks'
family = MONOMIAL
order = CONSTANT
block = 'fuel cladding'
[]
[t_water] # added for all corresponding 'temperature_blocks'
family = MONOMIAL
order = CONSTANT
block = 'water'
[]
[nek_temp] # added for all corresponding 'temperature_blocks'
family = MONOMIAL
order = CONSTANT
block = 'helium'
[]
[rho_water] # added for all corresponding 'density_blocks'
family = MONOMIAL
order = CONSTANT
blocks = 'water'
[]
[rho_helium] # added for all corresponding 'density_blocks'
family = MONOMIAL
order = CONSTANT
blocks = 'helium'
[]
[power] # the first tally we added (score is 'heating', but we set a custom name)
family = MONOMIAL
order = CONSTANT
[]
[openmc_flux] # the second tally we added (score is 'flux', but we set a custom name)
family = MONOMIAL
order = CONSTANT
[]
[]
By default, Cardinal will name all temperature feedback with the temp variable, all density feedback with the density variable, and all tally scores with the same name as the score. Suppose we instead wanted to rely on defaults; we would set our [Problem] block as:
[Problem]
type = OpenMCCellAverageProblem
density_blocks = 'water helium'
temperature_blocks = 'fuel cladding water helium'
[Tallies]
[cell_tally]
type = CellTally
score = 'heating flux'
[]
[]
[]
Then Cardinal is instead building the following automatically for you:
[AuxVariables]
[temp] # added for all temperature_blocks
family = MONOMIAL
order = CONSTANT
block = 'fuel cladding water helium'
[]
[density] # added for all density_blocks
family = MONOMIAL
order = CONSTANT
block = 'water helium'
[]
[heating] # the first tally we added (score is 'heating')
family = MONOMIAL
order = CONSTANT
[]
[flux] # the second tally we added (score is 'flux')
family = MONOMIAL
order = CONSTANT
[]
[]
Cell to Element Mapping
Next, a mapping from the elements in the MooseMesh (i.e. the mesh in the [Mesh] block) is established to the OpenMC cell geometry.
The OpenMC geometry is always specified in length units of centimeters. Most other MOOSE applications use SI units, i.e. meters for the length unit. See Mesh Scaling to learn how to couple OpenMC models to non-centimeter-based MOOSE applications.
In the [Mesh] block, you should provide a mesh onto which OpenMC will write its tally values, as well as read temperature and density. This mesh is only used for reading/writing data, so there are no requirements on node continuity across elements. We loop over all the elements and map each to an OpenMC cell according to the element centroid. As an example, Figure 1 depicts an OpenMC geometry, a mesh on which temperature feedback is to be applied, and a visualization of the mapping from these elements to the OpenMC cells. There are no requirements on alignment of elements/cells or on preserving volumes - the OpenMC cells and mesh mirror elements do not need to be conformal. Elements that don't map to an OpenMC cell simply do not participate in the multiphysics coupling (and vice versa for the cells). This feature can be used to exclude regions such as reflectors from multiphysics feedback.

Figure 1: Illustration of OpenMC cells and the mapping to a mesh.
You can visualize how the OpenMC cells map to the mesh by viewing the cell_id and cell_instance variables Cardinal automatically outputs. For more information on how to interpret these variables, see: CellIDAux and CellInstanceAux.
The cell-to-element mapping should be established with care. There are two general behavior patterns that are typically undesirable. In Figure 2, consider the case where the [Mesh] has four equal-sized elements, each of volume , while the OpenMC domain has three equal-sized cells. Assume that the power produced by each OpenMC cell is , so that the total power of the OpenMC domain is . By nature of the centroid mapping, one OpenMC cell will map to a much larger region of space than the other two cells. Even though the fission power in each OpenMC cell is , the power density will differ by a factor of two once mapped to the [Mesh]. In practice, this might not have a detrimental or even noticeable effect on temperature solutions due to the smoothing nature of heat conduction, but you should be aware of it.
![Element to cell mapping for OpenMC cells coarser than the `[Mesh]`](../../media/openmc_coarser.png)
Figure 2: Element to cell mapping for OpenMC cells coarser than the [Mesh]
You can monitor the mapping by checking the mesh volumes that each OpenMC cell maps to by setting verbose = true, which will print a mapping table. You can also add an OpenMCVolumeCalculation which will run a stochastic volume calculation and print out the actual volume of the OpenMC cells in the "Actual Vol" column (not just the volume of the mesh elements the cells map to in the "Mapped Vol" column!).
---------------------------------------------------------------------------
| Cell | T | T+rho | Other | Mapped Vol | Actual Vol |
---------------------------------------------------------------------------
| 1, instance 0 (of 10) | 168 | 0 | 0 | 5.298e-01 | |
| 1, instance 1 (of 10) | 168 | 0 | 0 | 5.298e-01 | |
| 1, instance 2 (of 10) | 168 | 0 | 0 | 5.298e-01 | |
---------------------------------------------------------------------------
If you know that all the tallied OpenMC cells are actually the same volume, you can also use the check_equal_mapped_tally_volumes parameter to automatically check that the mapped volume for each tally bin is identical.
In Figure 3, consider the case where the [Mesh] has two equal-sized elements, while the OpenMC domain has three equal-sized cells. By nature of the centroid mapping, one OpenMC cell will not participate in coupling because no elements in the [Mesh] have a centroid within the cell. This situation is more difficult to detect, but can be monitored by setting verbose = true and monitoring the table outputs.
![Element to cell mapping for OpenMC cells finer than the `[Mesh]`](../../media/openmc_finer.png)
Figure 3: Element to cell mapping for OpenMC cells finer than the [Mesh]
Of course, the situations shown in Figure 2 and Figure 3 can occur even if the number of mesh elements exactly match the number of OpenMC cells, depending on where the element centroids are located. Therefore, we recommend using verbose = true when getting started.
Cell Levels
A unique temperature and density will be assigned to each OpenMC cell that has a unique combination of a cell ID and instance. As such, the cell "level" on which to apply multiphysics feedback must be defined, using either the cell_level or lowest_cell_level parameter.
The cell "level" is the coordinate "level" in the OpenMC geometry to "stop at" for identifying the cell ID/instance pairs. Cell-based geometries can be constructed by nesting repeated universes/lattices at multiple locations in the domain, but you may not be interested in always coupling cells at the lowest level to MOOSE. This feature was added to Cardinal specifically for TRISO applications, where heat conduction feedback is usually not explicitly resolving TRISO particles (instead, you'd prefer to set each fuel pebble or compact to a single temperature, requiring Cardinal to figure out the list of cells (TRISO layers, matrix) filling some higher-level cell (the pebble surface, the compact cylinder surface). The cell_level and lowest_cell_level parameters indicate the coordinate level (relative to 0, the highest level in the geometry) at which to "stop" the find cell routine.
You can visualize your OpenMC model at different geometry hierarchies using OpenMC plots and setting the level.
As an example, the figure below shows a TRISO-fueled HTGR fuel assembly from the gas assembly tutorial. This image shows the geomtery, colored by cell, at different levels in the geometry. If we wanted to apply a single temperature value to all the TRISO particles nested inside a compact, we would set cell_level = 1 for this problem. If we chose cell_level = 2, we'd be trying to set a unique temperature for every individual TRISO particle. If we chose cell_level = 3, we'd be trying to set a unique temperature for every layer in every TRISO particle.

Figure 4: Cell level concept, using a TRISO assembly as an example
In many cases, the coordinate levels on which you would like to couple OpenMC to MOOSE are not the same everywhere in the OpenMC geometry. This was the case in Figure 4 (levels 2 and 3 only exist in parts of the domain). You can use lowest_cell_level to indicate that coupling should be performed on the specified level except in regions where there are no cells at that level.
Adding Tallies
Mapped Tallies
This class takes the tally objects initialized by the [Tallies] block and uses them to construct tally auxvariables. At the moment there are two options for discretizing tallies spatially in Cardinal:
If no tallies are specified by the [Tallies] block, this class adds no tally auxvariables. Each is normalized according to the specified power or source_strength (depending on whether you are running a -eigenvalue or fixed-source problem). By default, the normalization is done against a global tally added over the entire OpenMC domain. By setting normalize_by_global_tally to false, however, the tally is instead normalized by the sum of the tally itself.
Mapped Tally Scores
You can customize the type of score that Cardinal uses to normalize tallies to power with the source_rate_normalization parameter. 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 data
For more information on the specific meanings of these various scores, please consult the OpenMC tally documentation. All of the tallies added are normalized with the same source_rate_normalization score when running in eigenvalue mode.
Tally Normalization
The tally units-transformation process involves division by a volume. In Cardinal, there are two different notions of volume:
The volume of the
[Mesh]elements which map to a tally bin regionThe actual volume of the tally bin region in OpenMC
Take Figure 5 as an example; on the left is a [Mesh], and on the right is a spherical OpenMC cell we are mapping to the [Mesh]. For this case, the two volumes are different, because of the faceted nature of the sphere surface. The tallies in Cardinal are all normalized by the [Mesh] volume (0.96 cm in this example). This is a good choice for heating-related tallies, because this will ensure we properly preserve a total integral (power) when integrated on the [Mesh]. For heating tallies, it is much more important to preserve the total power, as opposed to the raw pointwise value of the heat deposition (units of W/m).

Figure 5: Illustration of OpenMC particle transport geometry and the mapping of OpenMC cells to a user-supplied "mesh mirror."
However, for some other tallies (e.g. the 'flux' tallies), dividing by the [Mesh] volume indicates instead that we're normalizing so as to preserve a reaction rate (reactions/sec), as if you integrated over the [Mesh]. This will not give the same raw pointwise tally value as what OpenMC is actually predicting, if the volumes of the [Mesh] and the tally bin regions are significantly different. If the pointwise value is very important for your use case, you can post-multiply your AuxVariables by (in this example, 0.96 / 1.00), where is the volume of the [Mesh] elements which map to the tally bin, and is the volume of the corresponding tally region.
If your OpenMC tally bins and corresponding [Mesh] elements already are exactly the same volume, then no special thought is needed for the tally normalization, and the value will be exactly consistent with the interpretation used in OpenMC.
Tally and Filter Editors
Cardinal provides UserObjects for editing tallies and filters:
OpenMCTallyEditor: online control of tally parameters
OpenMCDomainFilterEditor: online control of domain filter parameters
These objects can be used to interact with tallies and/or filters that are present in a tallies.xml file for the problem being run (in other words, tallies the user manually sets up when building the OpenMC model). These objects can be used to create tallies and/or filters as well. In either case, these objects do not interact with tallies and filters used to map data to the mesh mirror (Mapped Tallies ).
Neutron Kinetics Parameters
Cardinal exposes the calculation of neutron kinetics parameters in OpenMC with iterated fission probabilities. and can be obtained by first setting calc_kinetics_params = true. The parameters can then be accessed with LambdaEffective and BetaEffective post-processors after the OpenMC simulation finishes. An example of this capability can be found below.
[Problem<<<{"href": "../../syntax/Problem/index.html"}>>>]
type = OpenMCCellAverageProblem
verbose = true
calc_kinetics_params = true
ifp_generations = 5
[](test/tests/neutronics/kinetics/both.i)[Postprocessors<<<{"href": "../../syntax/Postprocessors/index.html"}>>>]
[lambda]
type = LambdaEffective<<<{"description": "A post-processor which computes and returns the kinetics parameter $\\Lambda_{eff}$.", "href": "../postprocessors/LambdaEffective.html"}>>>
[]
[lambda_rel]
type = LambdaEffective<<<{"description": "A post-processor which computes and returns the kinetics parameter $\\Lambda_{eff}$.", "href": "../postprocessors/LambdaEffective.html"}>>>
output<<<{"description": "The value to output. Options are $\\Lambda_{eff}$ (mean), the standard deviation of $\\Lambda_{eff}$ (std_dev), or the relative error of $\\Lambda_{eff}$ (rel_err)."}>>> = rel_err
[]
[lambda_std]
type = LambdaEffective<<<{"description": "A post-processor which computes and returns the kinetics parameter $\\Lambda_{eff}$.", "href": "../postprocessors/LambdaEffective.html"}>>>
output<<<{"description": "The value to output. Options are $\\Lambda_{eff}$ (mean), the standard deviation of $\\Lambda_{eff}$ (std_dev), or the relative error of $\\Lambda_{eff}$ (rel_err)."}>>> = std_dev
[]
[beta]
type = BetaEffective<<<{"description": "A post-processor which computes and returns the kinetics parameter $\\beta_{eff}$.", "href": "../postprocessors/BetaEffective.html"}>>>
[]
[beta_rel]
type = BetaEffective<<<{"description": "A post-processor which computes and returns the kinetics parameter $\\beta_{eff}$.", "href": "../postprocessors/BetaEffective.html"}>>>
output<<<{"description": "The value to output. Options are $\\beta_{eff}$ (mean), the standard deviation of $\\beta_{eff}$ (std_dev), or the relative error of $\\beta_{eff}$ (rel_err)."}>>> = rel_err
[]
[beta_std]
type = BetaEffective<<<{"description": "A post-processor which computes and returns the kinetics parameter $\\beta_{eff}$.", "href": "../postprocessors/BetaEffective.html"}>>>
output<<<{"description": "The value to output. Options are $\\beta_{eff}$ (mean), the standard deviation of $\\beta_{eff}$ (std_dev), or the relative error of $\\beta_{eff}$ (rel_err)."}>>> = std_dev
[]
[](test/tests/neutronics/kinetics/both.i)The number of generations tracked to compute these kinetic parameters can be specified by setting ifp_generations. Note that ifp_generations must be less than or equal to the number of inactive batches.
The memory cost of a simulation running with iterated fission probabilities scales linearly with ifp_generations (an extra double and an extra integrer must be tracked per particle for each generation). It is recommend that the number of IFP generations be minimized when possible.
Other Features
While this class mainly facilitates data transfers to and from OpenMC, a number of other features are implemented.
CAD Geometry Skinning
OpenMC is currently limited to setting a single constant temperature and a single constant density in each cell. For CSG geometries, the user needs to manually set up sub-divisions in the geometry in order to capture spatial variation in temperature and density. For DAGMC geometries, you can instead optionally re-generate the OpenMC cells after each Picard iteration according to contours in temperature and/or density. With this approach, the OpenMC model can receive spatially-varying temperature and density without the user needing to manually subdivide regions of space a priori. To use this feature, set the skinner parameter to the name of a MoabSkinner user object. For more information, consult the documentation for MoabSkinner.
This skinning feature is only available for DAGMC geometries for which the [Mesh] obeys the same material boundaries in the starting .h5m file.
Mesh Scaling
OpenMC always uses a length unit of centimeters, but a coupled MOOSE application often uses a length unit of meters. When transferring field data, it is important to account for the length units of the coupled MOOSE application. The scaling parameter is used to apply a multiplicative factor to the [Mesh] and mesh_template (if using a file-based mesh tally) to get to units of centimeters assumed by OpenMC. This multiplicative factor is then used to
"Find cell" routines in OpenMC in order to map a centimeters-based OpenMC geometry to a different length unit`
Scale the fission power in OpenMC (units of W/cm) to a different volume unit
If an unstructured mesh tally is used, scale the
mesh_templateandmesh_translations/mesh_translations_fileto units of centimeters
For instance, if the [Mesh] is specified in units of meters, then scaling should be set to 100.0 to indicate that the [Mesh] is specified in a unit 100.0 times larger than the OpenMC unit of centimeters.
Tally Optimizations
"Spatially separate" tallies are tallies where a particle can only score to one bin for a given event - for instance, a tally with one bin per fuel pebble in a pebble bed reactor is a spatially separate tally because a particle scoring to fission in pebble cannot also score to fission in pebble . OpenMC allows you to specify that tallies are spatially separate, which can offer a big performance improvement. If your OpenMC input files do not contain any of their own tallies (i.e. in a tallies.xml), you can try using this feature to speed up your calculation.
Relaxation
OpenMC is coupled to MOOSE via fixed point iteration, also referred to as Picard iteration. For many problems, instabilities can exist between OpenMC and the coupled thermal-fluid physics. The OpenMC wrapping offers several options by which the tally can be "relaxed" between iterations to effectively damp these oscillations. For all these relaxation schemes, the tally that gets coupled to MOOSE for iteration is taken as a weighted sum of the previous iterate and the most-recent Monte Carlo calculation:
(1)
where is the weighting factor, indicates the -th Monte Carlo solve, and the number of samples is . For the very first fixed point iteration, because there is no previous iterate, . For , Eq. (1) is referred to as "over-relaxation" because more than a full step is taken in the direction of the most recent iterate. Conversely, for , Eq. (1) is referred to as "under-relaxation" because less than a full step is taken in the direction of the most recent iterate. Several options are available for selecting and . These are chosen with the relaxation parameter. Options include:
constant: choose a constant androbbins_monro: and constant ; applying the recursion in Eq. (1) shows that the solution at iteration is the average of the previous Monte Carlo solutions
(2)
dufek_gudowski: variable and ; the step size is selected based on the fraction of samples in the -th Monte Carlo solve relative to the total number of samples performed so far. The number of samples is then based on the notion that the step size should be proportional to the convergence rate of the central limit theorem (inversely proportional to the square root of the total number of simulated particles):
(3)
Controlling OpenMC Termination
OpenMC's tally triggers allow OpenMC to automatically end its active batches once reaching certain criteria in and/or the tally uncertainties, including:
standard deviation
variance
relative error
tally relative error
Setting k_trigger enables triggers based on , and setting k_trigger_threshold sets the required convergence criteria. Individual tally triggers can be set in the tally_trigger and tally_trigger_threshold parameters of the tally classes (CellTally and MeshTally). Both and multiple tally triggers can be used simultaneously.
Controlling the OpenMC Settings
This class provides minimal capabilities to control the OpenMC simulation settings directly from the Cardinal input file:
batches: the number of batches (inactive plus active)inactive_batches: the number of inactive batchesopenmc_verbosity: verbosity level in OpenMCparticles: the number of particles per batch
For all of the above, a setting in the Cardinal input file will override any settings in the OpenMC XML files.
Volume Calculations
It can be helpful for debugging problem setup to compare actual OpenMC cell volumes against the [Mesh] element volumes to which they map. A well-designed mapping should have good agreement between actual cell volumes and the [Mesh] volumes they map to. To add a volume calculation, set the volume_calculation parameter to the name of a OpenMCVolumeCalculation object. If you then set verbose = true, you will be able to compare the cell volumes with the MOOSE elements.
Symmetric Data Transfers
Many neutronics problems are symmetric - such as half-core or quarter-core symmetry. However, some MOOSE mesh generators don't yet support symmetric geometries by slicing along arbitrary planes. This class supports both half-symmetric OpenMC models and general -th symmetric rotational models by coupling symmetric OpenMC models to full-system thermal-fluid models.
The symmetric mapping is specified with the symmetry_mapper parameter, a SymmetryPointGenerator user object. Note that if asymmetries exist in whatever physics OpenMC is coupled to, they will be averaged on both sides of the plane before sending temperatures and densities to OpenMC. Please consult the SymmetryPointGenerator for more information.
Input Parameters
- allow_initial_conditions_with_restartFalseTrue to allow the user to specify initial conditions when restarting. Initial conditions can override any restarted field
Default:False
C++ Type:bool
Controllable:No
Description:True to allow the user to specify initial conditions when restarting. Initial conditions can override any restarted field
- restart_file_baseFile base name used for restart (e.g.
/ or /LATEST to grab the latest file available) C++ Type:FileNameNoExtension
Controllable:No
Description:File base name used for restart (e.g.
/ or /LATEST to grab the latest file available)
Restart 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.
- default_ghostingFalseWhether or not to use libMesh's default amount of algebraic and geometric ghosting
Default:False
C++ Type:bool
Controllable:No
Description:Whether or not to use libMesh's default amount of algebraic and geometric ghosting
- enableTrueSet the enabled status of the MooseObject.
Default:True
C++ Type:bool
Controllable:No
Description:Set the enabled status of the MooseObject.
Advanced Parameters
- kernel_coverage_block_listList of subdomains for kernel coverage check. The meaning of this list is controlled by the parameter 'kernel_coverage_check' (whether this is the list of subdomains to be checked, not to be checked or not taken into account).
C++ Type:std::vector<SubdomainName>
Controllable:No
Description:List of subdomains for kernel coverage check. The meaning of this list is controlled by the parameter 'kernel_coverage_check' (whether this is the list of subdomains to be checked, not to be checked or not taken into account).
- material_coverage_block_listList of subdomains for material coverage check. The meaning of this list is controlled by the parameter 'material_coverage_check' (whether this is the list of subdomains to be checked, not to be checked or not taken into account).
C++ Type:std::vector<SubdomainName>
Controllable:No
Description:List of subdomains for material coverage check. The meaning of this list is controlled by the parameter 'material_coverage_check' (whether this is the list of subdomains to be checked, not to be checked or not taken into account).
- material_coverage_checkTRUEControls, if and how a material subdomain coverage check is performed. With 'TRUE' or 'ON' all subdomains are checked (the default). Setting 'FALSE' or 'OFF' will disable the check for all subdomains. To exclude a predefined set of subdomains 'SKIP_LIST' is to be used, while the subdomains to skip are to be defined in the parameter 'material_coverage_block_list'. To limit the check to a list of subdomains, 'ONLY_LIST' is to be used (again, using the parameter 'material_coverage_block_list').
Default:TRUE
C++ Type:MooseEnum
Options:FALSE, TRUE, OFF, ON, SKIP_LIST, ONLY_LIST
Controllable:No
Description:Controls, if and how a material subdomain coverage check is performed. With 'TRUE' or 'ON' all subdomains are checked (the default). Setting 'FALSE' or 'OFF' will disable the check for all subdomains. To exclude a predefined set of subdomains 'SKIP_LIST' is to be used, while the subdomains to skip are to be defined in the parameter 'material_coverage_block_list'. To limit the check to a list of subdomains, 'ONLY_LIST' is to be used (again, using the parameter 'material_coverage_block_list').
Simulation Checks Parameters
- not_zeroed_tag_vectorsExtra vector tags which the sytem will not zero when other vector tags are zeroed. The outer index is for which nonlinear system the extra tag vectors should be added for
C++ Type:std::vector<std::vector<TagName>>
Controllable:No
Description:Extra vector tags which the sytem will not zero when other vector tags are zeroed. The outer index is for which nonlinear system the extra tag vectors should be added for
Contribution To Tagged Field Data Parameters
- parallel_barrier_messagingFalseDisplays messaging from parallel barrier notifications when executing or transferring to/from Multiapps (default: false)
Default:False
C++ Type:bool
Controllable:No
Description:Displays messaging from parallel barrier notifications when executing or transferring to/from Multiapps (default: false)
- verbose_multiappsFalseSet to True to enable verbose screen printing related to MultiApps
Default:False
C++ Type:bool
Controllable:No
Description:Set to True to enable verbose screen printing related to MultiApps
- verbose_restoreFalseSet to True to enable verbose screen printing related to solution restoration
Default:False
C++ Type:bool
Controllable:No
Description:Set to True to enable verbose screen printing related to solution restoration
- verbose_setupfalseSet to 'true' to have the problem report on any object created. Set to 'extra' to also display all parameters.
Default:false
C++ Type:MooseEnum
Options:false, true, extra
Controllable:No
Description:Set to 'true' to have the problem report on any object created. Set to 'extra' to also display all parameters.
Verbosity Parameters
- restore_original_nonzero_patternFalseWhether we should reset matrix memory for every Jacobian evaluation. This option is useful if the sparsity pattern is constantly changing and you are using hash table assembly or if you wish to continually restore the matrix to the originally preallocated sparsity pattern computed by relationship managers.
Default:False
C++ Type:bool
Controllable:No
Description:Whether we should reset matrix memory for every Jacobian evaluation. This option is useful if the sparsity pattern is constantly changing and you are using hash table assembly or if you wish to continually restore the matrix to the originally preallocated sparsity pattern computed by relationship managers.
- use_hash_table_matrix_assemblyFalseWhether to assemble matrices using hash tables instead of preallocating matrix memory. This can be a good option if the sparsity pattern changes throughout the course of the simulation.
Default:False
C++ Type:bool
Controllable:No
Description:Whether to assemble matrices using hash tables instead of preallocating matrix memory. This can be a good option if the sparsity pattern changes throughout the course of the simulation.
Nonlinear System(S) Parameters
- show_invalid_solution_consoleTrueSet to true to show the invalid solution occurance summary in console
Default:True
C++ Type:bool
Controllable:No
Description:Set to true to show the invalid solution occurance summary in console
Solution Validity Control 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)
- (test/tests/neutronics/feedback/multi_component_density/multi/multi_vars.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/openmc_errors/mode/volume/volume.i)
- (test/tests/criticality/material_density/target.i)
- (test/tests/postprocessors/fission_tally_relative_error/multi.i)
- (test/tests/openmc_errors/mesh_tally/incorrect_file.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/triggers/k_std_dev.i)
- (test/tests/neutronics/filters/sh/openmc_l1.i)
- (test/tests/neutronics/heat_source/default_tally_blocks.i)
- (tutorials/tokamak/openmc.i)
- (tutorials/openmc_subchannel/two_coupled/openmc.i)
- (tutorials/lwr_solid/openmc_um.i)
- (test/tests/neutronics/moving_mesh/scale.i)
- (test/tests/neutronics/heat_source/partial_mapping_openmc_union.i)
- (test/tests/neutronics/adaptivity/mesh.i)
- (test/tests/neutronics/fixed_source/mapping_solid.i)
- (test/tests/openmc_errors/level/phase_too_high/fluid_too_high.i)
- (tutorials/pebbles/openmc_um.i)
- (tutorials/lwr_amr/openmc_amr_single.i)
- (test/tests/neutronics/feedback/density_per_cell/openmc.i)
- (test/tests/neutronics/heat_source/from_postprocessor.i)
- (test/tests/neutronics/mesh_tally/one_mesh_no_input_file.i)
- (test/tests/neutronics/feedback/temperature/one_two/openmc.i)
- (test/tests/neutronics/indicators/rel_err/openmc.i)
- (test/tests/neutronics/feedback/multi_component_density/multi/openmc.i)
- (test/tests/neutronics/symmetry/openmc.i)
- (test/tests/neutronics/feedback/triso/different_fill_univs/openmc.i)
- (test/tests/neutronics/tally_system/multi_estimator.i)
- (test/tests/neutronics/tallies/reaction_rates/openmc.i)
- (test/tests/neutronics/triggers/tally_rel_err.i)
- (tutorials/dagmc/openmc.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)
- (tutorials/lwr_amr/openmc_amr.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/feedback/temperature/two_one/openmc_default.i)
- (test/tests/neutronics/density/openmc.i)
- (test/tests/neutronics/heat_source/zero_particles_from_postprocessor.i)
- (test/tests/neutronics/gen_mgxs/all_mgxs_mesh.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/neutronics/kinetics/non_eigen/openmc.i)
- (test/tests/neutronics/dagmc/mesh_tallies/disjoint_bins.i)
- (test/tests/userobjects/openmc_nuclide_densities/thermal_density.i)
- (test/tests/neutronics/triggers/ignore_zeros/ignore_zero.i)
- (test/tests/neutronics/filters/xml/mesh.i)
- (test/tests/neutronics/solid/openmc_zero.i)
- (test/tests/neutronics/openmc_xml/skip_statepoint.i)
- (test/tests/neutronics/feedback/temperature/two_one/openmc.i)
- (test/tests/neutronics/dagmc/wrong_uo.i)
- (test/tests/neutronics/openmc_xml/openmc.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/no_range/openmc.i)
- (test/tests/neutronics/tally_grad/finite_diff/openmc.i)
- (test/tests/neutronics/kinetics/beta.i)
- (test/tests/openmc_errors/block_mappings/skipping_moose_feedback.i)
- (test/tests/neutronics/dagmc/mesh_tallies/openmc.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/openmc_errors/input_params/invalid_max_batches.i)
- (test/tests/neutronics/dagmc/missing_graveyard.i)
- (test/tests/neutronics/symmetry/triso/openmc.i)
- (test/tests/neutronics/openmc_statepoint/openmc.i)
- (test/tests/neutronics/heat_source/multi_tally_mapping_solid.i)
- (test/tests/neutronics/tally_system/multi_mesh_relax.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/coupled_cells/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/dagmc/mesh_tallies/one_bin.i)
- (test/tests/neutronics/dagmc/mesh_tallies/csg_step_2/openmc.i)
- (test/tests/neutronics/filters/particle/cell.i)
- (test/tests/openmc_errors/input_params/missing_properties.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/openmc_errors/mesh_translations/invalid_row.i)
- (test/tests/userobjects/openmc_cell_transform/multiple_cells/translate_cells.i)
- (test/tests/neutronics/dagmc/cell_tallies/unmapped_cells.i)
- (test/tests/neutronics/gen_mgxs/mgxs_aux/mg_tc_scatter_xs.i)
- (test/tests/neutronics/mesh_tally/different_units_and_translations.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/mesh_tally/multiple_meshes_global.i)
- (test/tests/neutronics/tally_system/multi_mesh.i)
- (test/tests/neutronics/dagmc/cell_tallies/csg_step_2/openmc.i)
- (test/tests/openmc_errors/fixed_source/k.i)
- (test/tests/neutronics/filters/legendre/cell.i)
- (test/tests/neutronics/dagmc/no_symmetry.i)
- (test/tests/neutronics/markers/look_ahead/openmc.i)
- (test/tests/neutronics/dagmc/mesh_tallies/direct_tally.i)
- (test/tests/neutronics/feedback/lattice/non_material_fluid.i)
- (test/tests/neutronics/solid/openmc_missing_pebble.i)
- (test/tests/criticality/material_density/openmc.i)
- (test/tests/openmc_errors/zero_tally/openmc.i)
- (test/tests/neutronics/dagmc/with_csg/dag_lattice/openmc.i)
- (test/tests/neutronics/relaxation/mesh_tallies/openmc.i)
- (tutorials/gas_compact_multiphysics/openmc_thm.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/neutronics/output/mesh.i)
- (test/tests/postprocessors/eigenvalue/xml_directory/openmc.i)
- (test/tests/neutronics/dagmc/mesh_tallies/with_scaling.i)
- (test/tests/neutronics/feedback/triso/cache/openmc.i)
- (test/tests/neutronics/adaptivity/unchanged_mesh.i)
- (test/tests/neutronics/feedback/temperature/one_one/openmc.i)
- (test/tests/userobjects/openmc_cell_transform/empty_cell_ids.i)
- (test/tests/openmc_errors/fixed_source/k_trigger.i)
- (test/tests/neutronics/filters/filter_no_norm_score.i)
- (test/tests/neutronics/moving_mesh/volumes.i)
- (test/tests/neutronics/tally_system/multi_cell.i)
- (test/tests/openmc_errors/block_mappings/absent_solid_block.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/neutronics/feedback/interchangeable/no_data_flow.i)
- (test/tests/neutronics/tally_system/multi_mesh_triggers.i)
- (test/tests/userobjects/openmc_nuclide_densities/openmc.i)
- (test/tests/neutronics/density/mat_mult_cell/openmc.i)
- (test/tests/openmc_errors/block_mappings/unequal_volumes.i)
- (test/tests/neutronics/dagmc/density_skin/only_solid.i)
- (test/tests/neutronics/moving_mesh/temperature.i)
- (test/tests/openmc_errors/input_params/invalid_batches.i)
- (test/tests/neutronics/axisymmetric/openmc.i)
- (test/tests/neutronics/dagmc/cell_tallies/csg_step_1/openmc.i)
- (tutorials/msfr/openmc.i)
- (test/tests/neutronics/moving_mesh/mesh_tally_file.i)
- (test/tests/openmc_errors/block_mappings/nonexistent_block.i)
- (test/tests/symmetry/reflection.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/openmc_errors/xs_temperatures/openmc.i)
- (test/tests/neutronics/filters/sh/openmc_l1_mult.i)
- (test/tests/neutronics/feedback/multiple_levels/openmc.i)
- (test/tests/neutronics/mg/void_region/openmc.i)
- (test/tests/neutronics/moving_mesh/density.i)
- (test/tests/neutronics/dagmc/density_skin/csg_step_2/openmc.i)
- (test/tests/neutronics/mesh_tally/one_mesh.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/criticality/borated_water/openmc.i)
- (test/tests/openmc_errors/densities/zero_density.i)
- (test/tests/neutronics/filters/no_filter.i)
- (test/tests/neutronics/mesh_tally/one_mesh_global.i)
- (test/tests/neutronics/filters/legendre/cell_l0_from_l1.i)
- (test/tests/openmc_errors/mode/plot/plot.i)
- (tutorials/openmc_subchannel/all_coupled/openmc.i)
- (test/tests/openmc_errors/input_params/no_dag.i)
- (test/tests/neutronics/flux/flux.i)
- (test/tests/neutronics/feedback/universes/fill_in_flat/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/gen_mgxs/hide_tally_vars.i)
- (test/tests/neutronics/heat_source/mapping_fluid.i)
- (test/tests/neutronics/gen_mgxs/all_mgxs_cell.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/openmc_errors/mesh_tally/incorrect_order.i)
- (test/tests/userobjects/openmc_cell_transform/cells_shadow.i)
- (test/tests/neutronics/filters/azimuthal/mesh.i)
- (test/tests/neutronics/mesh_tally/block_restrict.i)
- (test/tests/neutronics/heat_source/particles_from_postprocessor.i)
- (test/tests/neutronics/mesh_tally/fission_tally_std_dev.i)
- (test/tests/neutronics/tally_system/cell_with_unmapped.i)
- (test/tests/neutronics/relaxation/cell_tallies/output_fission_tally.i)
- (test/tests/neutronics/dagmc/mesh_tallies/csg_step_1/openmc.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)
- (test/tests/neutronics/dagmc/incompatible_geom/mismatch/openmc.i)
- (tutorials/pebbles/openmc.i)
- (test/tests/openmc_errors/cell_instances/lattice_outer/temp.i)
- (test/tests/neutronics/relaxation/mesh_tallies/output_fission_tally.i)
- (test/tests/neutronics/kinetics/both.i)
- (test/tests/neutronics/filters/delayed/cell.i)
- (test/tests/neutronics/filters/polar/cell.i)
- (test/tests/neutronics/indicators/od/openmc_dup.i)
- (test/tests/neutronics/mesh_tally/different_units.i)
- (test/tests/userobjects/volume_calculation/no_vol.i)
- (test/tests/neutronics/feedback/multi_component_density/openmc.i)
- (test/tests/neutronics/relaxation/cell_tallies/multi_tally.i)
- (test/tests/neutronics/triggers/mesh_tally_rel_err.i)
- (test/tests/neutronics/feedback/triso/openmc.i)
- (test/tests/criticality/rotation/openmc.i)
- (test/tests/neutronics/heat_source/multi_tally_mesh.i)
- (test/tests/userobjects/volume_calculation/openmc.i)
- (test/tests/userobjects/openmc_nuclide_densities/only_density.i)
- (test/tests/neutronics/gen_mgxs/subset_cell.i)
- (doc/content/source/actions/multi_tally_example.i)
- (test/tests/neutronics/kinetics/geom_reset/one_bin.i)
- (test/tests/neutronics/mesh_tally/no_coupling.i)
- (test/tests/neutronics/filters/multi_filter.i)
- (test/tests/symmetry/rotation.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/kinetics/six_grp.i)
- (test/tests/neutronics/feedback/interchangeable/no_tally.i)
- (tutorials/lwr_mgxs/openmc_mgxs.i)
- (test/tests/neutronics/feedback/universes/lattice_in_flat/openmc.i)
- (tutorials/csg_to_cad/openmc.i)
- (test/tests/neutronics/triggers/multi_rel_err.i)
- (test/tests/neutronics/filters/xml/cell.i)
- (test/tests/neutronics/relaxation/cell_tallies/dufek_gudowski.i)
- (test/tests/neutronics/indicators/od/openmc.i)
- (test/tests/userobjects/openmc_cell_transform/scaled.i)
- (doc/content/source/problems/smallest_openmc_input.i)
- (tutorials/lwr_amr/openmc.i)
- (test/tests/neutronics/feedback/temperature/two_one/openmc_multi_temp.i)
- (test/tests/neutronics/fixed_source/flux.i)
- (test/tests/openmc_errors/mesh_tally/incorrect_scaling.i)
- (test/tests/neutronics/moving_mesh/mesh_tally.i)
- (test/tests/openmc_errors/input_params/levels.i)
- (test/tests/neutronics/flux/missing_norm.i)
- (test/tests/neutronics/mesh_tally/multiple_meshes.i)
- (test/tests/neutronics/dagmc/with_csg/dag_cell_not_root/openmc.i)
- (test/tests/neutronics/mesh_tally/scaling_mm.i)
- (test/tests/neutronics/feedback/multi_component_density/multi/multi_vars_alt.i)
- (test/tests/neutronics/feedback/different_units/openmc.i)
- (test/tests/neutronics/tally_system/multi_diff.i)
- (test/tests/postprocessors/openmc_particles/openmc.i)
- (test/tests/openmc_errors/mode/particle/particle.i)
- (tutorials/openmc_subchannel/openmc/openmc.i)
- (test/tests/neutronics/symmetry/wrong_uo.i)
- (test/tests/userobjects/openmc_cell_transform/translate_cells.i)
- (test/tests/userobjects/volume_calculation/user_bb.i)
- (test/tests/neutronics/adaptivity/cell.i)
- (test/tests/postprocessors/reactivity/openmc.i)
(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/kinetics/both.i)
[Mesh]
[sphere]
type = FileMeshGenerator
file = ../meshes/sphere.e
[]
[]
[Problem]
type = OpenMCCellAverageProblem
verbose = true
calc_kinetics_params = true
ifp_generations = 5
[]
[Executioner]
type = Steady
[]
[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
[]
[]
[Outputs]
csv = true
[]
(test/tests/neutronics/kinetics/both.i)
[Mesh]
[sphere]
type = FileMeshGenerator
file = ../meshes/sphere.e
[]
[]
[Problem]
type = OpenMCCellAverageProblem
verbose = true
calc_kinetics_params = true
ifp_generations = 5
[]
[Executioner]
type = Steady
[]
[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
[]
[]
[Outputs]
csv = true
[]
(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
[]
(test/tests/neutronics/feedback/multi_component_density/multi/multi_vars.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
[]
[split_top]
type = ParsedSubdomainMeshGenerator
input = upper_block
combinatorial_geometry = 'x > 30.0 & y > 12.5'
block_id = 50
[]
[]
[AuxVariables]
[cell_density]
family = MONOMIAL
order = CONSTANT
[]
[total_density]
family = MONOMIAL
order = CONSTANT
[]
[]
[AuxKernels]
[cell_density]
type = CellDensityAux
variable = cell_density
[]
[]
[ICs]
[d1]
type = ConstantIC
variable = density1
value = 15e3
block = '0'
[]
[d2]
type = ConstantIC
variable = density2
value = 3000
block = '1'
[]
[d3]
type = ConstantIC
variable = density3
value = 7000
block = '50'
[]
[dd1]
type = ConstantIC
variable = total_density
value = 15e3
block = '0'
[]
[dd2]
type = ConstantIC
variable = total_density
value = 3000
block = '1'
[]
[dd3]
type = ConstantIC
variable = total_density
value = 7000
block = '50'
[]
[]
[Problem]
type = OpenMCCellAverageProblem
verbose = true
cell_level = 0
density_variables = 'density1; density2; density3'
density_blocks = '0; 1; 50'
temperature_blocks = '0 1 50'
[]
[Postprocessors]
[k]
type = KEigenvalue
[]
[rho_0]
type = ElementAverageValue
variable = cell_density
block = '0'
[]
[rho_1]
type = ElementAverageValue
variable = cell_density
block = '1'
[]
[avg_cell0]
type = ElementAverageValue
variable = cell_density
block = '0'
[]
[avg_cell1]
type = ElementAverageValue
variable = cell_density
block = '1 50'
[]
[]
[Executioner]
type = Transient
num_steps = 1
[]
[Outputs]
csv = true
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/openmc_errors/mode/volume/volume.i)
[Mesh]
[sphere]
type = FileMeshGenerator
file = ../../../neutronics/meshes/sphere.e
[]
[]
[Problem]
type = OpenMCCellAverageProblem
[]
[Executioner]
type = Transient
[]
(test/tests/criticality/material_density/target.i)
[Mesh]
[g]
type = GeneratedMeshGenerator
dim = 3
xmin = 0
xmax = 10
ymin = 0
ymax = 10
zmin = 0
zmax = 10
[]
[]
[Problem]
type = OpenMCCellAverageProblem
[CriticalitySearch]
type = OpenMCMaterialDensity
material_id = 1
minimum = 10000
maximum = 20000
tolerance = 1e-2
target = 0.9
[]
[]
[Executioner]
type = Steady
[]
[Postprocessors]
[k]
type = KEigenvalue
[]
[k_residual]
type = ParsedPostprocessor
expression = 'abs(k - 0.9)'
pp_names = 'k'
[]
[k_converged_within_tolerance]
type = ParsedPostprocessor
expression = 'if (k_residual < 1e-2, 1, 0)'
pp_names = 'k_residual'
[]
[]
[Outputs]
csv = true
hide = 'k k_residual critical_value'
[]
(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/openmc_errors/mesh_tally/incorrect_file.i)
[Mesh]
[sphere]
type = FileMeshGenerator
file = ../../neutronics/meshes/sphere.e
[]
[block]
type = SubdomainIDGenerator
input = sphere
subdomain_id = '0'
[]
allow_renumbering = false
[]
[Problem]
type = OpenMCCellAverageProblem
temperature_blocks = '0'
initial_properties = xml
verbose = true
cell_level = 0
power = 100.0
[Tallies]
[Mesh]
type = MeshTally
# make the mistake of clearly using a totally different mesh
mesh_template = '../../neutronics/meshes/pincell.e'
[]
[]
[]
[Executioner]
type = Transient
num_steps = 1
[]
(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/triggers/k_std_dev.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
k_trigger = std_dev
k_trigger_threshold = 1.2e-2
max_batches = 100
[]
[Executioner]
type = Transient
num_steps = 1
[]
[Postprocessors]
[k_std_dev]
type = KEigenvalue
output = 'std_dev'
[]
[]
[Outputs]
csv = true
[]
(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/tokamak/openmc.i)
[Mesh]
[file]
type = FileMeshGenerator
file = tokamak.e
[]
[]
[AuxVariables]
[cell_temperature]
family = MONOMIAL
order = CONSTANT
[]
[]
[AuxKernels]
[cell_temperature]
type = CellTemperatureAux
variable = cell_temperature
[]
[]
[Problem]
type = OpenMCCellAverageProblem
scaling = 100.0
source_strength = 2e18
cell_level = 0
temperature_blocks = 'plasma_facing multiplier breeder divertor vacuum_vessel'
# this is a low number of particles; you will want to increase in order to obtain
# high-quality results
first_iteration_particles = 1000
relaxation = dufek_gudowski
skinner = moab
[Tallies]
[tokamak]
type = MeshTally
mesh_template = tokamak.e
score = 'heating_local H3_production'
output = unrelaxed_tally_std_dev
[]
[]
[]
[UserObjects]
[moab]
type = MoabSkinner
temperature_min = 0
temperature_max = 2000
n_temperature_bins = 40
temperature = temp
build_graveyard = true
output_skins = true
[]
[]
[Postprocessors]
[heating]
type = ElementIntegralVariablePostprocessor
variable = heating_local
[]
[tritium_production]
type = ElementIntegralVariablePostprocessor
variable = H3_production
[]
[tritium_error]
type = TallyRelativeError
tally_score = H3_production
value_type = average
[]
[heating_error]
type = TallyRelativeError
tally_score = heating_local
value_type = average
[]
[]
[Executioner]
type = Transient
[]
[Outputs]
exodus = true
csv = true
[]
(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'
[]
[]
(tutorials/lwr_solid/openmc_um.i)
[Mesh]
[file]
type = FileMeshGenerator
file = mesh_in.e
[]
allow_renumbering = false
[]
[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
particles = 20000
inactive_batches = 500
batches = 10000
[Tallies]
[heat_source]
type = MeshTally
name = heat_source
normalize_by_global_tally = false
[]
[]
[]
[Executioner]
type = Transient
[]
[Outputs]
exodus = true
csv = true
[]
[Postprocessors]
[heat_source]
type = ElementIntegralVariablePostprocessor
variable = heat_source
[]
[max_tally_rel_err]
type = TallyRelativeError
[]
[max_heat_source]
type = ElementExtremeValue
variable = heat_source
[]
[]
(test/tests/neutronics/moving_mesh/scale.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 = 5
nz = 5
[]
[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'
[]
[tets]
type = ElementsToTetrahedronsConverter
input = name
[]
[]
[Problem]
type = OpenMCCellAverageProblem
scaling = 100.0
temperature_blocks = 'left right'
cell_level = 0
skinner = skin
verbose = true
# settings to match the reference/ case
#particles = 500000
#inactive_batches = 200
#batches = 1000
[]
[AuxVariables]
[disp_x]
[]
[disp_y]
[]
[disp_z]
[]
[]
[ICs]
[temp]
type = ConstantIC
variable = temp
value = 1000
[]
[]
[AuxKernels]
[disp_x] # this executes after the [Problem]
type = FunctionAux
variable = disp_x
function = disp_x
[]
[]
[Functions]
[disp_x]
type = ParsedFunction
expression = 'exp((x+0.05))-1'
[]
[]
[UserObjects]
[skin]
type = MoabSkinner
temperature = temp
n_temperature_bins = 1
temperature_min = 0
temperature_max = 2000
build_graveyard = true
verbose = True
[]
[]
[Executioner]
type = Transient
num_steps = 2
[]
[Postprocessors]
[k]
type = KEigenvalue
[]
[]
[Outputs]
csv = true
exodus = true
[]
(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/adaptivity/mesh.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
[]
[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]
[Mesh]
type = MeshTally
score = kappa_fission
# 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
execute_on = timestep_end
hide = 'temp cell_instance'
[]
(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
[]
(tutorials/pebbles/openmc_um.i)
[Mesh]
[pebble]
type = FileMeshGenerator
file = mesh_in.e
[]
[repeat]
type = CombinerGenerator
inputs = pebble
positions = '0 0 0.02
0 0 0.06
0 0 0.10'
[]
allow_renumbering = false
[]
[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 = MeshTally
mesh_translations = '0 0 0.02
0 0 0.06
0 0 0.10'
mesh_template = mesh_in.e
name = heat_source
normalize_by_global_tally = false
[]
[]
[]
[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
[]
[]
(tutorials/lwr_amr/openmc_amr_single.i)
[Mesh]
[file]
type = FileMeshGenerator
file = mesh_pin_in.e
[]
[]
[Adaptivity]
marker = error_combo
steps = 2
[Indicators/optical_depth]
type = ElementOpticalDepthIndicator
rxn_rate = 'fission'
h_type = 'max'
[]
[Markers]
[depth_frac]
type = ErrorFractionMarker
indicator = optical_depth
refine = 0.3
coarsen = 0.0
[]
[rel_error]
type = ValueThresholdMarker
invert = true
coarsen = 1e-1
refine = 5e-2
variable = heat_source_rel_error
third_state = DO_NOTHING
[]
[error_combo]
type = BooleanComboMarker
# Only refine iff the relative error is sufficiently low AND the optical depth is
# sufficiently large.
refine_markers = 'rel_error depth_frac'
# Coarsen based exclusively on relative error.
coarsen_markers = 'rel_error'
boolean_operator = and
[]
[]
[]
[Problem]
type = OpenMCCellAverageProblem
particles = 1000
inactive_batches = 50
batches = 1000
power = ${fparse 3000e6 / 273 * 4}
source_rate_normalization = 'kappa_fission'
assume_separate_tallies = true
skip_statepoint = true
[Tallies]
[heat_source]
type = MeshTally
score = 'kappa_fission fission flux'
name = 'heat_source fission flux'
output = 'unrelaxed_tally_std_dev unrelaxed_tally_rel_error'
block = 'uo2_center uo2'
normalize_by_global_tally = false
[]
[]
[]
[Postprocessors]
[num_elem]
type = NumElements
elem_filter = active
[]
[max_rel_err]
type = TallyRelativeError
value_type = max
tally_score = kappa_fission
[]
[min_rel_err]
type = TallyRelativeError
value_type = min
tally_score = kappa_fission
[]
[avg_rel_err]
type = TallyRelativeError
value_type = average
tally_score = kappa_fission
[]
[]
[Executioner]
type = Steady
[]
[Outputs]
execute_on = 'timestep_end'
exodus = true
csv = 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/mesh_tally/one_mesh_no_input_file.i)
[Mesh]
[sphere]
type = FileMeshGenerator
file = ../meshes/sphere.e
[]
[solid_ids]
type = SubdomainIDGenerator
input = sphere
subdomain_id = '100'
[]
allow_renumbering = false
[]
[Problem]
type = OpenMCCellAverageProblem
temperature_blocks = '100'
initial_properties = xml
verbose = true
cell_level = 0
power = 100.0
[Tallies]
[Mesh]
type = MeshTally
normalize_by_global_tally = false
[]
[]
[]
[Executioner]
type = Steady
[]
[Postprocessors]
[heat_source]
type = ElementIntegralVariablePostprocessor
variable = kappa_fission
[]
[]
[Outputs]
execute_on = final
exodus = true
hide = 'temp cell_instance cell_id'
[]
(test/tests/neutronics/feedback/temperature/one_two/openmc.i)
[Mesh]
type = GeneratedMesh
dim = 3
xmin = -50.0
xmax = 50.0
ymin = -25.0
ymax = 25.0
zmin = 0.0
zmax = 50.0
nx = 20
ny = 15
nz = 15
[]
[ICs]
[temp]
type = FunctionIC
variable = temp
function = temperature
[]
[]
[Functions]
[temperature]
type = ParsedFunction
expression = '1000 + 10*x'
[]
[]
[AuxVariables]
[cell_temp]
family = MONOMIAL
order = CONSTANT
[]
[]
[AuxKernels]
[cell_temp]
type = CellTemperatureAux
variable = cell_temp
[]
[]
[Problem]
type = OpenMCCellAverageProblem
verbose = true
temperature_blocks = '0'
cell_level = 0
[]
[Executioner]
type = Steady
[]
[Postprocessors]
[k]
type = KEigenvalue
[]
[T_left]
type = PointValue
variable = cell_temp
point = '-25.0 0.0 0.0'
[]
[T_right]
type = PointValue
variable = cell_temp
point = '25.0 0.0 0.0'
[]
[]
[Outputs]
csv = true
[]
(test/tests/neutronics/indicators/rel_err/openmc.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
source_rate_normalization = 'kappa_fission'
[Tallies]
[Mesh]
type = MeshTally
score = 'kappa_fission'
output = 'unrelaxed_tally_rel_error'
normalize_by_global_tally = false
[]
[]
[]
[Executioner]
type = Steady
[]
[Outputs]
execute_on = final
exodus = true
hide = 'kappa_fission kappa_fission_rel_error'
[]
(test/tests/neutronics/feedback/multi_component_density/multi/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_density]
family = MONOMIAL
order = CONSTANT
[]
[]
[AuxKernels]
[cell_density]
type = CellDensityAux
variable = cell_density
[]
[]
[ICs]
[d1]
type = ConstantIC
variable = density1
value = 15e3
block = '0'
[]
[d2]
type = ConstantIC
variable = density2
value = 3000
block = '1'
[]
[]
[Problem]
type = OpenMCCellAverageProblem
verbose = true
cell_level = 0
density_variables = 'density1 ; density2'
density_blocks = '0; 1'
temperature_blocks = '0 1'
[]
[Postprocessors]
[k]
type = KEigenvalue
[]
[rho_0]
type = ElementAverageValue
variable = cell_density
block = '0'
[]
[rho_1]
type = ElementAverageValue
variable = cell_density
block = '1'
[]
[]
[Executioner]
type = Transient
num_steps = 1
[]
[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/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/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
[]
(tutorials/dagmc/openmc.i)
[Mesh]
[file]
type = FileMeshGenerator
file = mesh_in.e
[]
allow_renumbering = false
[]
[AuxVariables]
[cell_temperature]
family = MONOMIAL
order = CONSTANT
[]
[]
[AuxKernels]
[cell_temperature]
type = CellTemperatureAux
variable = cell_temperature
[]
[]
[Problem]
type = OpenMCCellAverageProblem
verbose = true
cell_level = 0
temperature_blocks = '2 3'
power = 1000.0
volume_calculation = vol
[Tallies]
[heat_source]
type = MeshTally
mesh_template = mesh_in.e
name = heat_source
check_tally_sum = false
normalize_by_global_tally = false
[]
[]
[]
[UserObjects]
[vol]
type = OpenMCVolumeCalculation
n_samples = 200000
[]
[]
[Postprocessors]
[heat_source]
type = ElementIntegralVariablePostprocessor
variable = heat_source
[]
[k]
type = KEigenvalue
[]
[]
[Executioner]
type = Transient
[]
[Outputs]
exodus = true
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'
[]
(tutorials/lwr_amr/openmc_amr.i)
[Mesh]
[file]
type = FileMeshGenerator
file = mesh_in.e
[]
[]
[Adaptivity]
marker = error_combo
steps = 2
[Indicators/optical_depth]
type = ElementOpticalDepthIndicator
rxn_rate = 'fission'
h_type = 'max'
[]
[Markers]
[depth_frac]
type = ErrorFractionMarker
indicator = optical_depth
refine = 0.3
coarsen = 0.0
[]
[rel_error]
type = ValueThresholdMarker
invert = true
coarsen = 1e-1
refine = 5e-2
variable = heat_source_rel_error
third_state = DO_NOTHING
[]
[error_combo]
type = BooleanComboMarker
# Only refine iff the relative error is sufficiently low AND the optical depth is
# sufficiently large.
refine_markers = 'rel_error depth_frac'
# Coarsen based exclusively on relative error.
coarsen_markers = 'rel_error'
boolean_operator = and
[]
[]
[]
[Problem]
type = OpenMCCellAverageProblem
particles = 10000
inactive_batches = 50
batches = 1000
power = ${fparse 3000e6 / 273 * 4}
source_rate_normalization = 'kappa_fission'
assume_separate_tallies = true
skip_statepoint = true
[Tallies]
[heat_source]
type = MeshTally
score = 'kappa_fission fission flux'
name = 'heat_source fission flux'
output = 'unrelaxed_tally_std_dev unrelaxed_tally_rel_error'
block = 'uo2_center uo2'
normalize_by_global_tally = false
[]
[]
[]
[Postprocessors]
[num_elem]
type = NumElements
elem_filter = active
[]
[max_rel_err]
type = TallyRelativeError
value_type = max
tally_score = kappa_fission
[]
[min_rel_err]
type = TallyRelativeError
value_type = min
tally_score = kappa_fission
[]
[avg_rel_err]
type = TallyRelativeError
value_type = average
tally_score = kappa_fission
[]
[]
[Executioner]
type = Steady
[]
[Outputs]
execute_on = 'timestep_end'
exodus = true
csv = true
[]
(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/feedback/temperature/two_one/openmc_default.i)
[Mesh]
[initial]
type = GeneratedMeshGenerator
dim = 3
xmin = -50.0
xmax = 50.0
ymin = -25.0
ymax = 25.0
zmin = 0.0
zmax = 50.0
nx = 20
ny = 15
nz = 15
[]
[split]
type = ParsedSubdomainMeshGenerator
input = initial
combinatorial_geometry = 'x < 0.0'
block_id = '3'
[]
[]
[ICs]
[temp]
type = FunctionIC
variable = temp
function = temperature
[]
[]
[Functions]
[temperature]
type = ParsedFunction
expression = '1000 + 10*x'
[]
[]
[AuxVariables]
[cell_temp]
family = MONOMIAL
order = CONSTANT
[]
[]
[AuxKernels]
[cell_temp]
type = CellTemperatureAux
variable = cell_temp
[]
[]
[Problem]
type = OpenMCCellAverageProblem
verbose = true
cell_level = 0
temperature_blocks = '3 0'
[]
[Executioner]
type = Steady
[]
[Postprocessors]
[k]
type = KEigenvalue
[]
[T_left]
type = PointValue
variable = cell_temp
point = '-25.0 0.0 0.0'
[]
[T_right]
type = PointValue
variable = cell_temp
point = '25.0 0.0 0.0'
[]
[]
[Outputs]
csv = true
[]
(test/tests/neutronics/density/openmc.i)
[Mesh]
[file]
type = FileMeshGenerator
file = ../dagmc/mesh_tallies/slab.e
[]
[split_right]
type = ParsedSubdomainMeshGenerator
input = file
combinatorial_geometry = 'x > 37.5'
block_id = 100
excluded_subdomains = '1'
[]
[split_left]
type = ParsedSubdomainMeshGenerator
input = split_right
combinatorial_geometry = 'x < 37.5'
block_id = 200
excluded_subdomains = '2'
[]
[scale]
type = TransformGenerator
input = split_left
transform = translate
vector_value = '0.0 0.0 0.0'
[]
[]
[AuxVariables]
[cell_temperature]
family = MONOMIAL
order = CONSTANT
[]
[cell_density]
family = MONOMIAL
order = CONSTANT
[]
[cell_material]
family = MONOMIAL
order = CONSTANT
[]
[]
x0 = 12.5
x1 = 37.5
x2 = 62.5
T0 = 600.0
dT = 50.0
drho = 100.0
rho0 = 1000.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})))'
[]
[rho]
type = ParsedFunction
expression = 'if (x <= ${x0}, ${fparse rho0 - drho}, if (x <= ${x1}, ${rho0}, if (x <= ${x2}, ${fparse rho0 + drho}, ${fparse rho0 + 2 * drho})))'
[]
[]
[AuxKernels]
[cell_temperature]
type = CellTemperatureAux
variable = cell_temperature
[]
[cell_density]
type = CellDensityAux
variable = cell_density
[]
[cell_material]
type = CellMaterialIDAux
variable = cell_material
[]
[]
[AuxKernels]
[temp]
type = FunctionAux
variable = temp
function = temp
execute_on = timestep_begin
[]
[rho]
type = FunctionAux
variable = density
function = rho
execute_on = timestep_begin
[]
[]
[Problem]
type = OpenMCCellAverageProblem
verbose = true
density_blocks = '2 1'
temperature_blocks = '200 1'
cell_level = 0
[]
[Postprocessors]
[k]
type = KEigenvalue
[]
[rho_2]
type = ElementAverageValue
variable = density
block = '2'
[]
[rho_1]
type = ElementAverageValue
variable = density
block = '1'
[]
[T_200]
type = ElementAverageValue
variable = temp
block = '200'
[]
[T_1]
type = ElementAverageValue
variable = temp
block = '1'
[]
[]
[Executioner]
type = Steady
[]
[Outputs]
exodus = true
[]
(test/tests/neutronics/heat_source/zero_particles_from_postprocessor.i)
[Mesh]
[sphere]
type = FileMeshGenerator
file = ../meshes/sphere.e
[]
[]
[Functions]
[nparticles_fn]
type = ParsedFunction
value = 0
[]
[]
[Postprocessors]
[n_particles]
type = FunctionValuePostprocessor
function = nparticles_fn
execute_on = 'timestep_begin'
[]
[particles_reporter]
type = OpenMCParticles
value_type = instantaneous
[]
[total_particles_reporter]
type = OpenMCParticles
value_type = total
[]
[]
[Problem]
type = OpenMCCellAverageProblem
power = 100
particles = n_particles
verbose = true
cell_level = 0
[]
[Executioner]
type = Transient
num_steps = 2
[]
[Outputs]
csv = true
exodus = false
[]
(test/tests/neutronics/gen_mgxs/all_mgxs_mesh.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'
[MGXS]
tally_type = mesh
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 = true
add_fission = true
add_fission_heating = true
add_inverse_velocity = true
add_diffusion_coefficient = true
add_absorption = true
[]
[]
[Executioner]
type = Steady
[]
[Postprocessors]
[abs_xs_g1]
type = ElementIntegralVariablePostprocessor
block = '100'
variable = abs_xs_g1
[]
[abs_xs_g2]
type = ElementIntegralVariablePostprocessor
block = '100'
variable = abs_xs_g2
[]
[chi_g1]
type = ElementIntegralVariablePostprocessor
block = '100'
variable = chi_g1
[]
[chi_g2]
type = ElementIntegralVariablePostprocessor
block = '100'
variable = chi_g2
[]
[diff_g1]
type = ElementIntegralVariablePostprocessor
block = '100'
variable = diff_g1
[]
[diff_g2]
type = ElementIntegralVariablePostprocessor
block = '100'
variable = diff_g2
[]
[inv_v_g1]
type = ElementIntegralVariablePostprocessor
block = '100'
variable = inv_v_g1
[]
[inv_v_g2]
type = ElementIntegralVariablePostprocessor
block = '100'
variable = inv_v_g2
[]
[kappa_fission_g1]
type = ElementIntegralVariablePostprocessor
block = '100'
variable = kappa_fission_g1
[]
[kappa_fission_g2]
type = ElementIntegralVariablePostprocessor
block = '100'
variable = kappa_fission_g2
[]
[nu_fission_xs_g1]
type = ElementIntegralVariablePostprocessor
block = '100'
variable = nu_fission_xs_g1
[]
[nu_fission_xs_g2]
type = ElementIntegralVariablePostprocessor
block = '100'
variable = nu_fission_xs_g2
[]
[scatter_xs_g1_gp1_l0]
type = ElementIntegralVariablePostprocessor
block = '100'
variable = scatter_xs_g1_gp1_l0
[]
[scatter_xs_g1_gp2_l0]
type = ElementIntegralVariablePostprocessor
block = '100'
variable = scatter_xs_g1_gp2_l0
[]
[scatter_xs_g2_gp1_l0]
type = ElementIntegralVariablePostprocessor
block = '100'
variable = scatter_xs_g2_gp1_l0
[]
[scatter_xs_g2_gp2_l0]
type = ElementIntegralVariablePostprocessor
block = '100'
variable = scatter_xs_g2_gp2_l0
[]
[total_xs_g1]
type = ElementIntegralVariablePostprocessor
block = '100'
variable = total_xs_g1
[]
[total_xs_g2]
type = ElementIntegralVariablePostprocessor
block = '100'
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/neutronics/kinetics/non_eigen/openmc.i)
[Mesh]
[sphere]
type = FileMeshGenerator
file = ../../meshes/sphere.e
[]
[]
[Problem]
type = OpenMCCellAverageProblem
verbose = true
calc_kinetics_params = true
ifp_generations = 5
[]
[Executioner]
type = Steady
[]
[Outputs]
csv = true
[]
(test/tests/neutronics/dagmc/mesh_tallies/disjoint_bins.i)
[Mesh]
type = FileMesh
file = slab.e
allow_renumbering = false
parallel_type = replicated
[]
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]
[Mesh]
type = MeshTally
mesh_template = slab.e
[]
[]
[]
[UserObjects]
[moab]
type = MoabSkinner
temperature_min = ${fparse T0 - dT}
temperature_max = ${fparse T0 + 2 * dT}
n_temperature_bins = 4
temperature = temp
build_graveyard = true
output_skins = true
[]
[]
[Postprocessors]
[k]
type = KEigenvalue
[]
[]
[Executioner]
type = Transient
num_steps = 2
[]
[Outputs]
exodus = 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/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/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/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/openmc_xml/skip_statepoint.i)
[Mesh]
[sphere]
type = FileMeshGenerator
file = ../meshes/sphere.e
[]
[]
[Problem]
type = OpenMCCellAverageProblem
power = 100.0
inactive_batches = 3
batches = 8
skip_statepoint = true
[]
[Executioner]
type = Transient
num_steps = 1
[]
(test/tests/neutronics/feedback/temperature/two_one/openmc.i)
[Mesh]
[initial]
type = GeneratedMeshGenerator
dim = 3
xmin = -50.0
xmax = 50.0
ymin = -25.0
ymax = 25.0
zmin = 0.0
zmax = 50.0
nx = 20
ny = 15
nz = 15
[]
[split]
type = ParsedSubdomainMeshGenerator
input = initial
combinatorial_geometry = 'x < 0.0'
block_id = '3'
[]
[]
[ICs]
[temp]
type = FunctionIC
variable = temp
function = temperature
[]
[]
[Functions]
[temperature]
type = ParsedFunction
expression = '1000 + 10*x'
[]
[]
[AuxVariables]
[cell_temp]
family = MONOMIAL
order = CONSTANT
[]
[]
[AuxKernels]
[cell_temp]
type = CellTemperatureAux
variable = cell_temp
[]
[]
[Problem]
type = OpenMCCellAverageProblem
verbose = true
power = 100.0
temperature_blocks = '0 3'
cell_level = 0
[]
[Executioner]
type = Steady
[]
[Postprocessors]
[k]
type = KEigenvalue
[]
[T_left]
type = PointValue
variable = cell_temp
point = '-25.0 0.0 0.0'
[]
[T_right]
type = PointValue
variable = cell_temp
point = '25.0 0.0 0.0'
[]
[]
[Outputs]
csv = 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/openmc_xml/openmc.i)
[Mesh]
[sphere]
type = FileMeshGenerator
file = ../meshes/sphere.e
[]
[]
[Problem]
type = OpenMCCellAverageProblem
[]
[Executioner]
type = Transient
num_steps = 1
[]
[Postprocessors]
[k]
type = KEigenvalue
[]
[]
[Outputs]
csv = true
[]
(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/no_range/openmc.i)
[Mesh]
type = GeneratedMesh
dim = 3
xmin = -2
xmax = 2
ymin = -2
ymax = 2
zmin = -2
zmax = 10
nx = 5
ny = 5
nz = 5
[]
[Problem]
type = OpenMCCellAverageProblem
temperature_blocks = '0'
[]
[Executioner]
type = Transient
num_steps = 1
[]
(test/tests/neutronics/tally_grad/finite_diff/openmc.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
[]
[]
[AuxKernels]
[comp_grad_kappa_fission]
type = FDTallyGradAux
variable = grad_kappa_fission
score = 'kappa_fission'
[]
[]
[Problem]
type = OpenMCCellAverageProblem
temperature_blocks = '100'
initial_properties = xml
verbose = true
cell_level = 0
power = 100.0
[Tallies]
[Mesh]
type = MeshTally
score = 'kappa_fission'
normalize_by_global_tally = false
[]
[]
[]
[Executioner]
type = Steady
[]
[Outputs]
execute_on = final
exodus = true
hide = 'temp cell_instance cell_id kappa_fission'
[]
(test/tests/neutronics/kinetics/beta.i)
[Mesh]
[sphere]
type = FileMeshGenerator
file = ../meshes/sphere.e
[]
[]
[Problem]
type = OpenMCCellAverageProblem
verbose = true
calc_kinetics_params = false
ifp_generations = 5
[]
[Executioner]
type = Steady
[]
[Postprocessors]
[beta]
type = BetaEffective
[]
[]
[Outputs]
csv = true
[]
(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/dagmc/mesh_tallies/openmc.i)
[Mesh]
type = FileMesh
file = 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]
[Mesh]
type = MeshTally
mesh_template = slab.e
[]
[]
[]
[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/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/openmc_errors/input_params/invalid_max_batches.i)
[Mesh]
[sphere]
type = FileMeshGenerator
file = ../../neutronics/meshes/sphere.e
[]
[]
[Problem]
type = OpenMCCellAverageProblem
# there are only 10 inactive batches, so we should error
max_batches = 8
k_trigger = std_dev
k_trigger_threshold = 1e-2
[]
[Executioner]
type = Transient
[]
(test/tests/neutronics/dagmc/missing_graveyard.i)
[Mesh]
[file]
type = FileMeshGenerator
file = ../meshes/tet_cube.e
[]
allow_renumbering = false
parallel_type = replicated
[]
[Problem]
type = OpenMCCellAverageProblem
cell_level = 0
temperature_blocks = '1'
power = 1000.0
skinner = moab
[Tallies]
[Mesh]
type = MeshTally
[]
[]
[]
[UserObjects]
[moab]
type = MoabSkinner
temperature = temp
temperature_min = 0.0
temperature_max = 900.0
n_temperature_bins = 1
[]
[]
[Executioner]
type = Steady
[]
(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/openmc_statepoint/openmc.i)
[Mesh]
[sphere]
type = FileMeshGenerator
file = ../meshes/sphere.e
[]
[]
[Problem]
type = OpenMCCellAverageProblem
[]
[Executioner]
type = Transient
num_steps = 1
batches = 50 # this number needs to match the value in settings.xml for the purpose of the test
[]
[Postprocessors]
[k]
type = KEigenvalue
[]
[]
[Outputs]
csv = true
[]
(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/tally_system/multi_mesh_relax.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
[]
[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]
[Mesh_1]
type = MeshTally
score = kappa_fission
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
[]
[Mesh_2]
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 = Transient
num_steps = 3
[]
[Outputs]
exodus = 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/coupled_cells/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'
[]
[]
[Problem]
type = OpenMCCellAverageProblem
temperature_blocks = '100 200'
density_blocks = '200'
verbose = true
cell_level = 0
initial_properties = xml
[]
[Executioner]
type = Steady
[]
[Postprocessors]
[cells]
type = OpenMCCoupledCells
[]
[]
[Outputs]
csv = true
[]
(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/dagmc/mesh_tallies/one_bin.i)
[Mesh]
type = FileMesh
file = 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
temperature_blocks = '1 2'
cell_level = 0
power = 100.0
skinner = moab
[Tallies]
[Mesh]
type = MeshTally
mesh_template = slab.e
[]
[]
[]
[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/dagmc/mesh_tallies/csg_step_2/openmc.i)
[Mesh]
type = FileMesh
file = ../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]
[Mesh]
type = MeshTally
mesh_template = ../slab.e
[]
[]
[]
[Postprocessors]
[k]
type = KEigenvalue
[]
[]
[Executioner]
type = Transient
num_steps = 2
[]
[Outputs]
exodus = true
[]
(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/openmc_errors/input_params/missing_properties.i)
[Mesh]
[sphere]
type = FileMeshGenerator
file = ../../neutronics/meshes/sphere.e
[]
[]
[Problem]
type = OpenMCCellAverageProblem
temperature_blocks = '1'
cell_level = 0
initial_properties = hdf5
[]
[Executioner]
type = Transient
[]
(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/openmc_errors/mesh_translations/invalid_row.i)
[Mesh]
[sphere]
type = FileMeshGenerator
file = ../../neutronics/meshes/sphere.e
[]
[combine]
type = CombinerGenerator
inputs = 'sphere'
positions = '0 0 0
0 0 4
0 0 8'
[]
allow_renumbering = false
[]
[Problem]
type = OpenMCCellAverageProblem
power = 100.0
[Tallies]
[Mesh]
type = MeshTally
mesh_template = '../neutronics/meshes/sphere.e'
mesh_translations_file = pebble_centers.txt
[]
[]
[]
[Executioner]
type = Transient
[]
(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/dagmc/cell_tallies/unmapped_cells.i)
[Mesh]
[file]
type = FileMeshGenerator
file = ../mesh_tallies/slab.e
[]
[delete]
type = BlockDeletionGenerator
input = file
block = '2'
[]
allow_renumbering = false
parallel_type = replicated
[]
[Problem]
type = OpenMCCellAverageProblem
cell_level = 0
temperature_blocks = '1'
skinner = moab
[]
[UserObjects]
[moab]
type = MoabSkinner
temperature = temp
temperature_min = 0.0
temperature_max = 900.0
n_temperature_bins = 1
[]
[]
[Executioner]
type = Steady
[]
(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/mesh_tally/different_units_and_translations.i)
[Mesh]
[sphere]
type = FileMeshGenerator
file = ../meshes/sphere_in_m.e
[]
[solid1]
type = SubdomainIDGenerator
input = sphere
subdomain_id = '100'
[]
[sphereb]
type = FileMeshGenerator
file = ../meshes/sphere_in_m.e
[]
[solid2]
type = SubdomainIDGenerator
input = sphereb
subdomain_id = '200'
[]
[spherec]
type = FileMeshGenerator
file = ../meshes/sphere_in_m.e
[]
[solid3]
type = SubdomainIDGenerator
input = spherec
subdomain_id = '300'
[]
[combine]
type = CombinerGenerator
inputs = 'solid1 solid2 solid3'
positions_file = pebble_centers_in_m.txt
[]
allow_renumbering = false
[]
[Problem]
type = OpenMCCellAverageProblem
temperature_blocks = '100 200 300'
initial_properties = xml
verbose = true
cell_level = 0
# Because the [Mesh] is in units of meters, the mesh translations and mesh template
# must also be in units of meters
scaling = 100.0
power = 100.0
[Tallies]
[Mesh]
type = MeshTally
mesh_template = '../meshes/sphere_in_m.e'
mesh_translations_file = pebble_centers_in_m.txt
normalize_by_global_tally = false
[]
[]
[]
[Executioner]
type = Steady
[]
[Postprocessors]
[kappa_fission]
type = ElementIntegralVariablePostprocessor
variable = kappa_fission
[]
[heat_pebble1]
type = ElementIntegralVariablePostprocessor
variable = kappa_fission
block = '100'
[]
[heat_pebble2]
type = ElementIntegralVariablePostprocessor
variable = kappa_fission
block = '200'
[]
[heat_pebble3]
type = ElementIntegralVariablePostprocessor
variable = kappa_fission
block = '300'
[]
[]
[Outputs]
execute_on = final
exodus = true
hide = 'temp cell_instance cell_id'
[]
(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/mesh_tally/multiple_meshes_global.i)
[Mesh]
[sphere]
type = FileMeshGenerator
file = ../meshes/sphere.e
[]
[solid1]
type = SubdomainIDGenerator
input = sphere
subdomain_id = '100'
[]
[sphereb]
type = FileMeshGenerator
file = ../meshes/sphere.e
[]
[solid2]
type = SubdomainIDGenerator
input = sphereb
subdomain_id = '200'
[]
[spherec]
type = FileMeshGenerator
file = ../meshes/sphere.e
[]
[solid3]
type = SubdomainIDGenerator
input = spherec
subdomain_id = '300'
[]
[combine]
type = CombinerGenerator
inputs = 'solid1 solid2 solid3'
positions = '0 0 0
0 0 4
0 0 8'
[]
allow_renumbering = false
[]
[Problem]
type = OpenMCCellAverageProblem
temperature_blocks = '100 200 300'
initial_properties = xml
verbose = true
cell_level = 0
power = 100.0
[Tallies]
[Mesh]
type = MeshTally
mesh_template = '../meshes/sphere.e'
mesh_translations = '0 0 0
0 0 4
0 0 8'
normalize_by_global_tally = true
check_tally_sum = false
[]
[]
[]
[Executioner]
type = Steady
[]
[Postprocessors]
[kappa_fission]
type = ElementIntegralVariablePostprocessor
variable = kappa_fission
[]
[heat_pebble1]
type = ElementIntegralVariablePostprocessor
variable = kappa_fission
block = '100'
[]
[heat_pebble2]
type = ElementIntegralVariablePostprocessor
variable = kappa_fission
block = '200'
[]
[heat_pebble3]
type = ElementIntegralVariablePostprocessor
variable = kappa_fission
block = '300'
[]
[]
[Outputs]
execute_on = final
exodus = true
hide = 'temp cell_instance cell_id'
[]
(test/tests/neutronics/tally_system/multi_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]
[Mesh_1]
type = MeshTally
score = kappa_fission
mesh_translations = '0 0 0
0 0 4
0 0 8'
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
[]
[Mesh_2]
type = MeshTally
score = flux
mesh_translations = '0 0 0
0 0 4
0 0 8'
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/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/openmc_errors/fixed_source/k.i)
[Mesh]
[sphere]
type = FileMeshGenerator
file = ../../neutronics/meshes/sphere.e
[]
[]
[Problem]
type = OpenMCCellAverageProblem
source_strength = 1e6
[]
[Executioner]
type = Transient
[]
[Postprocessors]
[k]
type = KEigenvalue
[]
[]
(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/dagmc/no_symmetry.i)
[Mesh]
[file]
type = FileMeshGenerator
file = ../meshes/tet_cube.e
[]
allow_renumbering = false
parallel_type = replicated
[]
[Problem]
type = OpenMCCellAverageProblem
cell_level = 0
temperature_blocks = '1'
power = 1000.0
skinner = moab
symmetry_mapper = sym
[Tallies]
[Mesh]
type = MeshTally
mesh_template = ../meshes/tet_cube.e
[]
[]
[]
[UserObjects]
[moab]
type = MoabSkinner
temperature = temp
temperature_min = 0.0
temperature_max = 900.0
n_temperature_bins = 1
build_graveyard = true
[]
[sym]
type = SymmetryPointGenerator
normal = '1.0 0.0 0.0'
[]
[]
[Executioner]
type = Steady
[]
(test/tests/neutronics/markers/look_ahead/openmc.i)
[Mesh]
[sphere]
type = FileMeshGenerator
file = ../../meshes/sphere.e
[]
[solid1]
type = SubdomainIDGenerator
input = sphere
subdomain_id = '100'
[]
allow_renumbering = false
parallel_type = replicated
[]
[Adaptivity]
[Markers/lh]
type = ErrorFractionLookAheadMarker
# Statistical error
rel_error_refine = 0.2
stat_error_indicator = 'stat_err'
# Spatial error
indicator = 'od'
refine = 0.3
coarsen = 0.0
[]
[Indicators]
[od]
type = ElementOpticalDepthIndicator
rxn_rate = 'fission'
h_type = 'cube_root'
[]
[stat_err]
type = StatRelErrorIndicator
score = 'kappa_fission'
[]
[]
[]
[Problem]
type = OpenMCCellAverageProblem
verbose = true
power = 100.0
source_rate_normalization = 'kappa_fission'
[Tallies]
[Mesh_1]
type = MeshTally
score = 'kappa_fission'
output = 'unrelaxed_tally_rel_error'
normalize_by_global_tally = false
[]
[Mesh_2]
type = MeshTally
score = 'flux fission'
normalize_by_global_tally = false
[]
[]
[]
[Executioner]
type = Steady
[]
[Outputs]
execute_on = final
exodus = true
hide = 'kappa_fission kappa_fission_rel_error fission flux od stat_err'
[]
(test/tests/neutronics/dagmc/mesh_tallies/direct_tally.i)
[Mesh]
type = FileMesh
file = slab.e
allow_renumbering = false
parallel_type = replicated
[]
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]
[Mesh]
type = MeshTally
[]
[]
[]
[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/neutronics/feedback/lattice/non_material_fluid.i)
[Mesh]
type = FileMesh
file = ../../meshes/pincell.e
allow_renumbering = false
[]
[Problem]
type = OpenMCCellAverageProblem
power = 500.0
temperature_blocks = '2'
density_blocks = '2'
cell_level = 0
[Tallies]
[Mesh]
type = MeshTally
mesh_template = ../../meshes/pincell.e
[]
[]
[]
[Executioner]
type = Transient
[]
[Outputs]
exodus = 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/criticality/material_density/openmc.i)
[Mesh]
[g]
type = GeneratedMeshGenerator
dim = 3
xmin = 0
xmax = 10
ymin = 0
ymax = 10
zmin = 0
zmax = 10
[]
[]
[Problem]
type = OpenMCCellAverageProblem
[CriticalitySearch]
type = OpenMCMaterialDensity
material_id = 1
minimum = 10000
maximum = 20000
tolerance = 1e-2
[]
[]
[Executioner]
type = Steady
[]
[Postprocessors]
[k]
type = KEigenvalue
[]
[k_residual]
type = ParsedPostprocessor
expression = 'abs(k - 1.0)'
pp_names = 'k'
[]
[k_converged_within_tolerance]
type = ParsedPostprocessor
expression = 'if (k_residual < 1e-2, 1, 0)'
pp_names = 'k_residual'
[]
[]
[Outputs]
csv = true
hide = 'k k_residual critical_value'
[]
(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/neutronics/relaxation/mesh_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
[]
allow_renumbering = false
[]
[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]
[Mesh]
type = MeshTally
mesh_template = ../../meshes/sphere_in_m.e
mesh_translations = '0.0 0.0 0.02
0.0 0.0 0.06
0.0 0.0 0.10'
check_tally_sum = false
[]
[]
[]
[Executioner]
type = Transient
num_steps = 3
[]
[Outputs]
exodus = true
[]
[Postprocessors]
[heat_source]
type = ElementIntegralVariablePostprocessor
variable = kappa_fission
[]
[]
(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'
[]
[]
(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/neutronics/output/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'
[]
[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
source_strength = 1e6
temperature_blocks = '100 200'
density_blocks = '200'
cell_level = 0
initial_properties = xml
[Tallies]
[Mesh]
type = MeshTally
score = 'flux'
output = 'unrelaxed_tally'
check_tally_sum = false
[]
[]
[]
[Executioner]
type = Steady
[]
[Postprocessors]
[total_flux]
type = ElementIntegralVariablePostprocessor
variable = flux_raw
[]
[]
[Outputs]
execute_on = final
csv = 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/dagmc/mesh_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]
[Mesh]
type = MeshTally
mesh_template = scale_in.e
[]
[]
[]
[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
[]
(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/adaptivity/unchanged_mesh.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
[]
[Adaptivity]
steps = 1
marker = uniform
[Markers/uniform]
type = UniformMarker
mark = DO_NOTHING
[]
[]
[Problem]
type = OpenMCCellAverageProblem
verbose = true
power = 1e4
temperature_blocks = '100'
cell_level = 0
initial_properties = xml
[Tallies]
[Mesh]
type = MeshTally
score = kappa_fission
# 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
execute_on = timestep_end
hide = 'temp cell_instance'
[]
(test/tests/neutronics/feedback/temperature/one_one/openmc.i)
[Mesh]
type = GeneratedMesh
dim = 3
xmin = -50.0
xmax = 50.0
ymin = -25.0
ymax = 25.0
zmin = 0.0
zmax = 50.0
nx = 15
ny = 15
nz = 15
[]
[ICs]
[temp]
type = ConstantIC
variable = temp
value = 500.0
[]
[]
[Problem]
type = OpenMCCellAverageProblem
verbose = true
temperature_blocks = '0'
cell_level = 0
[]
[Executioner]
type = Steady
[]
[Postprocessors]
[k]
type = KEigenvalue
[]
[]
[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/openmc_errors/fixed_source/k_trigger.i)
[Mesh]
[sphere]
type = FileMeshGenerator
file = ../../neutronics/meshes/sphere.e
[]
[]
[Problem]
type = OpenMCCellAverageProblem
k_trigger = std_dev
k_trigger_threshold = 1e-4
max_batches = 100
source_strength = 1e6
[]
[Executioner]
type = Transient
[]
(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/neutronics/moving_mesh/volumes.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 = 2
nz = 2
[]
[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'
[]
[tets]
type = ElementsToTetrahedronsConverter
input = name
[]
[]
[Problem]
type = OpenMCCellAverageProblem
scaling = 100.0
temperature_blocks = 'left right'
cell_level = 0
skinner = skin
volume_calculation = vol
verbose = true
[]
[AuxVariables]
[disp_x]
[]
[disp_y]
[]
[disp_z]
[]
[mapped_vol]
family = MONOMIAL
order = CONSTANT
[]
[actual_openmc_vol]
family = MONOMIAL
order = CONSTANT
[]
[]
[ICs]
[temp]
type = ConstantIC
variable = temp
value = 1000
[]
[]
[AuxKernels]
[disp_x] # this executes after the [Problem]
type = FunctionAux
variable = disp_x
function = disp_x
[]
[mapped_vol]
type = CellVolumeAux
variable = mapped_vol
volume_type = mapped
[]
[actual_openmc_vol]
type = CellVolumeAux
variable = actual_openmc_vol
volume_type = actual
[]
[]
[Functions]
[disp_x]
type = ParsedFunction
expression = 'exp((x+0.05))-1'
[]
[]
[UserObjects]
[skin]
type = MoabSkinner
temperature = temp
n_temperature_bins = 1
temperature_min = 0
temperature_max = 2000
build_graveyard = true
verbose = True
[]
[vol]
type = OpenMCVolumeCalculation
n_samples = 1000000
[]
[]
[Executioner]
type = Transient
num_steps = 2
[]
[Postprocessors]
[moose_vol_left]
type = VolumePostprocessor
block = 'left'
[]
[moose_vol_right]
type = VolumePostprocessor
block = 'right'
[]
[mapped_vol_left]
type = ElementExtremeValue
variable = mapped_vol
block = 'left'
[]
[mapped_vol_right]
type = ElementExtremeValue
variable = mapped_vol
block = 'right'
[]
[openmc_vol_left]
type = ElementExtremeValue
variable = actual_openmc_vol
block = 'left'
[]
[openmc_vol_right]
type = ElementExtremeValue
variable = actual_openmc_vol
block = 'right'
[]
[]
[Outputs]
csv = 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/openmc_errors/block_mappings/absent_solid_block.i)
# This test checks that if we specify 'density_blocks', but no fluid maps to OpenMC,
# that we get an error.
[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'
[]
[solid_ids]
type = SubdomainIDGenerator
input = solid
subdomain_id = '100'
[]
[fluid]
type = FileMeshGenerator
file = ../../neutronics/meshes/sphere.e
[]
[fluid_ids]
type = SubdomainIDGenerator
input = fluid
subdomain_id = '500'
[]
[combine]
type = CombinerGenerator
inputs = 'solid_ids fluid_ids'
positions = '0 0 0
100 0 0'
[]
[]
[Problem]
type = OpenMCCellAverageProblem
power = 70.0
temperature_blocks = '500'
cell_level = 0
[]
[Executioner]
type = Transient
num_steps = 1
[]
[Outputs]
exodus = 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/neutronics/feedback/interchangeable/no_data_flow.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_id]
family = MONOMIAL
order = CONSTANT
[]
[cell_instance]
family = MONOMIAL
order = CONSTANT
[]
[cell_temperature]
family = MONOMIAL
order = CONSTANT
[]
[material_id]
family = MONOMIAL
order = CONSTANT
[]
[cell_density]
family = MONOMIAL
order = CONSTANT
[]
[]
[AuxKernels]
[cell_id]
type = CellIDAux
variable = cell_id
[]
[cell_instance]
type = CellInstanceAux
variable = cell_instance
[]
[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
[]
[Postprocessors]
[k]
type = KEigenvalue
[]
[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/tally_system/multi_mesh_triggers.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'
particles = 100
max_batches = 200
[Tallies]
[Mesh_1]
type = MeshTally
score = kappa_fission
trigger = rel_err
trigger_threshold = 5e-1
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
[]
[Mesh_2]
type = MeshTally
score = flux
trigger = rel_err
trigger_threshold = 5e-1
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/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/neutronics/density/mat_mult_cell/openmc.i)
[Mesh]
[file]
type = FileMeshGenerator
file = ../../dagmc/mesh_tallies/slab.e
[]
[split_right]
type = ParsedSubdomainMeshGenerator
input = file
combinatorial_geometry = 'x > 37.5'
block_id = 100
excluded_subdomains = '1'
[]
[split_left]
type = ParsedSubdomainMeshGenerator
input = split_right
combinatorial_geometry = 'x < 37.5'
block_id = 200
excluded_subdomains = '2'
[]
[scale]
type = TransformGenerator
input = split_left
transform = translate
vector_value = '0.0 0.0 0.0'
[]
[]
[AuxVariables]
[cell_temperature]
family = MONOMIAL
order = CONSTANT
[]
[cell_density]
family = MONOMIAL
order = CONSTANT
[]
[cell_material]
family = MONOMIAL
order = CONSTANT
[]
[]
x0 = 12.5
x1 = 37.5
x2 = 62.5
T0 = 600.0
dT = 50.0
drho = 100.0
rho0 = 1000.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})))'
[]
[rho]
type = ParsedFunction
expression = 'if (x <= ${x0}, ${fparse rho0 - drho}, if (x <= ${x1}, ${rho0}, if (x <= ${x2}, ${fparse rho0 + drho}, ${fparse rho0 + 2 * drho})))'
[]
[]
[AuxKernels]
[cell_temperature]
type = CellTemperatureAux
variable = cell_temperature
[]
[cell_density]
type = CellDensityAux
variable = cell_density
[]
[cell_material]
type = CellMaterialIDAux
variable = cell_material
[]
[]
[AuxKernels]
[temp]
type = FunctionAux
variable = temp
function = temp
execute_on = timestep_begin
[]
[rho]
type = FunctionAux
variable = density
function = rho
execute_on = timestep_begin
[]
[]
[Problem]
type = OpenMCCellAverageProblem
verbose = true
density_blocks = '2 1'
temperature_blocks = '200 1'
cell_level = 0
[]
[Postprocessors]
[k]
type = KEigenvalue
[]
[rho_200]
type = ElementAverageValue
variable = cell_density
block = '200'
[]
[rho_2]
type = ElementAverageValue
variable = cell_density
block = '2'
[]
[rho_1]
type = ElementAverageValue
variable = cell_density
block = '1'
[]
[T_200]
type = ElementAverageValue
variable = cell_temperature
block = '200'
[]
[T_1]
type = ElementAverageValue
variable = cell_temperature
block = '1'
[]
[]
[Executioner]
type = Steady
[]
[Outputs]
execute_on = 'TIMESTEP_END'
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/moving_mesh/temperature.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
temperature_blocks = 'left right'
verbose = true
# other tests cover cell IDs and instances, so we dont need to output them
output_cell_mapping = false
[]
[AuxVariables]
[disp_x]
[]
[disp_y]
[]
[disp_z]
[]
[cell_temperature]
family = MONOMIAL
order = CONSTANT
[]
[]
[AuxKernels]
[cell_temperature]
type = CellTemperatureAux
variable = cell_temperature
[]
[]
[ICs]
[temp_l]
type = ConstantIC
variable = temp
value = 1000
block = 'left'
[]
[temp_r]
type = ConstantIC
variable = temp
value = 1200
block = 'right'
[]
[]
[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'
[]
[]
[Executioner]
type = Transient
num_steps = 2
[]
[Outputs]
exodus = true
hide = 'temp'
[]
(test/tests/openmc_errors/input_params/invalid_batches.i)
[Mesh]
[sphere]
type = FileMeshGenerator
file = ../../neutronics/meshes/sphere.e
[]
[]
[Problem]
type = OpenMCCellAverageProblem
batches = 8
[]
[Executioner]
type = Transient
[]
(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/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
[]
(tutorials/msfr/openmc.i)
[Mesh]
[mesh]
type = FileMeshGenerator
file = msr.e
[]
[]
[ICs]
[temp]
type = ConstantIC
variable = temp
value = 948.0
[]
[density]
type = ConstantIC
variable = density
value = ${fparse -0.882*948+4983.6}
[]
[]
[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 = ParsedAux
variable = density
expression = '-0.882*temp+4983.6'
coupled_variables = temp
execute_on = timestep_begin
[]
[]
[Problem]
type = OpenMCCellAverageProblem
verbose = true
# this will start each Picard iteration from the fission source from the previous one
reuse_source = true
scaling = 100.0
density_blocks = '1'
temperature_blocks = '1'
cell_level = 0
power = 300.0e6
relaxation = dufek_gudowski
first_iteration_particles = 5000
skinner = moab
[Tallies]
[heat_source]
type = MeshTally
mesh_template = msr.e
output = unrelaxed_tally_std_dev
[]
[]
[]
nb = 15.0
tmin = 800.0
tmax = 1150.0
[UserObjects]
[moab]
type = MoabSkinner
temperature = temp
n_temperature_bins = ${nb}
temperature_min = ${tmin}
temperature_max = ${tmax}
density = density
n_density_bins = ${nb}
density_min = ${fparse -0.882*tmax+4983.6}
density_max = ${fparse -0.882*tmin+4983.6}
build_graveyard = true
output_skins = true
[]
[]
[MultiApps]
[nek]
type = TransientMultiApp
input_files = 'nek.i'
sub_cycling = true
execute_on = timestep_end
[]
[]
[Transfers]
[temp_to_openmc]
type = MultiAppGeneralFieldNearestLocationTransfer
from_multi_app = nek
variable = temp
source_variable = temperature
[]
[power_to_nek]
type = MultiAppGeneralFieldNearestLocationTransfer
to_multi_app = nek
source_variable = kappa_fission
variable = source
[]
[power_integral_to_nek]
type = MultiAppPostprocessorTransfer
to_postprocessor = source_integral
from_postprocessor = power
to_multi_app = nek
[]
[synchronize_in]
type = MultiAppPostprocessorTransfer
to_postprocessor = transfer_in
from_postprocessor = synchronize
to_multi_app = nek
[]
[]
[Postprocessors]
[power]
type = ElementIntegralVariablePostprocessor
variable = kappa_fission
[]
[k]
type = KEigenvalue
[]
[k_std_dev]
type = KEigenvalue
output = 'std_dev'
[]
[max_tally_err]
type = TallyRelativeError
[]
[max_T]
type = ElementExtremeValue
variable = temp
[]
[avg_T]
type = ElementAverageValue
variable = temp
[]
[max_q]
type = ElementExtremeValue
variable = kappa_fission
[]
[synchronize]
type = Receiver
default = 1.0
[]
[]
t_nek = ${fparse 2e-4 * 7.669}
[Executioner]
type = Transient
dt = ${fparse 2000 * t_nek}
[]
[Outputs]
exodus = true
csv = true
hide = 'synchronize'
[]
(test/tests/neutronics/moving_mesh/mesh_tally_file.i)
[GlobalParams]
use_displaced_mesh = true
displacements = 'disp_x disp_y disp_z'
[]
[Mesh]
[file]
type = FileMeshGenerator
file = mesh_tally_in.e
[]
allow_renumbering = false
[]
[Problem]
type = OpenMCCellAverageProblem
cell_level = 0
verbose = true
power = 1
[Tallies]
[heat]
type = MeshTally
score = 'kappa_fission'
mesh_template = mesh_tally_in.e
# the underlying OpenMC model is not changing, so parts of the geometry become
# uncovered as the [Mesh] moves
check_tally_sum = false
[]
[]
[]
[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'
[]
[]
[Executioner]
type = Transient
[]
(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/symmetry/reflection.i)
[Mesh]
# using a finer mesh will more clearly show the symmetry plane,
# but we use coarser here to have a smaller gold file
[sphere]
type = FileMeshGenerator
file = ../neutronics/meshes/sphere.e
[]
[solid_ids]
type = SubdomainIDGenerator
input = sphere
subdomain_id = '100'
[]
[]
[AuxVariables]
[x]
family = MONOMIAL
order = CONSTANT
[]
[y]
family = MONOMIAL
order = CONSTANT
[]
[z]
family = MONOMIAL
order = CONSTANT
[]
[]
[AuxKernels]
[x]
type = PointTransformationAux
variable = x
component = x
[]
[y]
type = PointTransformationAux
variable = y
component = y
[]
[z]
type = PointTransformationAux
variable = z
component = z
[]
[]
[Problem]
type = OpenMCCellAverageProblem
symmetry_mapper = sym
[]
[UserObjects]
[sym]
type = SymmetryPointGenerator
normal = '1.0 1.0 1.0'
[]
[]
[Executioner]
type = Transient
num_steps = 1
[]
[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/openmc_errors/xs_temperatures/openmc.i)
[Mesh]
type = GeneratedMesh
dim = 3
xmin = -2
xmax = 2
ymin = -2
ymax = 2
zmin = -2
zmax = 10
nx = 5
ny = 5
nz = 5
[]
[ICs]
[temp]
type = ConstantIC
variable = temp
value = 1e5
[]
[]
[Problem]
type = OpenMCCellAverageProblem
temperature_blocks = '0'
verbose = true
cell_level = 0
[]
[Executioner]
type = Transient
[]
(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/mg/void_region/openmc.i)
[Mesh]
type = GeneratedMesh
dim = 3
xmin = -50.0
xmax = 50.0
ymin = -1.0
ymax = 1.0
zmin = -1.0
zmax = 1.0
nx = 1
ny = 1
nz = 1
[]
[Problem]
type = OpenMCCellAverageProblem
verbose = true
temperature_blocks = '0'
cell_level = 0
[]
[ICs]
[temp]
type = ConstantIC
variable = temp
value = 293
[]
[]
[Executioner]
type = Steady
[]
[Postprocessors]
[k]
type = KEigenvalue
[]
[]
[Outputs]
csv = true
[]
(test/tests/neutronics/moving_mesh/density.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
density_blocks = 'left right'
verbose = true
# other tests cover cell IDs and instances, so we dont need to output them
output_cell_mapping = false
[]
[AuxVariables]
[disp_x]
[]
[disp_y]
[]
[disp_z]
[]
[cell_density]
family = MONOMIAL
order = CONSTANT
[]
[material_id]
family = MONOMIAL
order = CONSTANT
[]
[]
[AuxKernels]
[cell_density]
type = CellDensityAux
variable = cell_density
[]
[material_id]
type = CellMaterialIDAux
variable = material_id
[]
[]
[ICs]
[rho_l]
type = ConstantIC
variable = density
value = 1000
block = 'left'
[]
[rho_r]
type = ConstantIC
variable = density
value = 1200
block = 'right'
[]
[]
[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'
[]
[]
[Executioner]
type = Transient
num_steps = 2
[]
[Outputs]
exodus = true
hide = 'density'
[]
(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/mesh_tally/one_mesh.i)
[Mesh]
[sphere]
type = FileMeshGenerator
file = ../meshes/sphere.e
[]
[solid_ids]
type = SubdomainIDGenerator
input = sphere
subdomain_id = '100'
[]
allow_renumbering = false
[]
[Problem]
type = OpenMCCellAverageProblem
temperature_blocks = '100'
initial_properties = xml
verbose = true
cell_level = 0
power = 100.0
[Tallies]
[Mesh]
type = MeshTally
mesh_template = '../meshes/sphere.e'
normalize_by_global_tally = false
[]
[]
[]
[Executioner]
type = Steady
[]
[Postprocessors]
[heat_source]
type = ElementIntegralVariablePostprocessor
variable = kappa_fission
[]
[]
[Outputs]
execute_on = final
exodus = true
hide = 'temp'
[]
(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/criticality/borated_water/openmc.i)
[Mesh]
[g]
type = GeneratedMeshGenerator
dim = 3
xmin = 10
xmax = 20
ymin = 0
ymax = 10
zmin = 0
zmax = 10
nx = 10
ny = 1
nz = 1
[]
[]
[ICs]
[density]
type = ConstantIC
variable = density
value = 1900.0
[]
[]
[Problem]
type = OpenMCCellAverageProblem
density_blocks = '0'
cell_level = 0
verbose = true
[CriticalitySearch]
type = BoratedWater
absent_nuclides = 'O18'
material_id = 2
minimum = 0
maximum = 1000
tolerance = 1e-2
[]
[]
[Executioner]
type = Steady
[]
[Postprocessors]
[k]
type = KEigenvalue
[]
[k_residual]
type = ParsedPostprocessor
expression = 'abs(k - 1.0)'
pp_names = 'k'
[]
[k_converged_within_tolerance]
type = ParsedPostprocessor
expression = 'if (k_residual < 1e-2, 1, 0)'
pp_names = 'k_residual'
[]
[]
[Outputs]
csv = true
hide = 'k k_residual critical_value'
[]
(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/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/mesh_tally/one_mesh_global.i)
[Mesh]
[sphere]
type = FileMeshGenerator
file = ../meshes/sphere.e
[]
[solid_ids]
type = SubdomainIDGenerator
input = sphere
subdomain_id = '100'
[]
allow_renumbering = false
[]
[Problem]
type = OpenMCCellAverageProblem
temperature_blocks = '100'
initial_properties = xml
verbose = true
cell_level = 0
power = 100.0
[Tallies]
[Mesh]
type = MeshTally
mesh_template = '../meshes/sphere.e'
check_tally_sum = false
normalize_by_global_tally = true
[]
[]
[]
[Executioner]
type = Steady
[]
[Postprocessors]
[heat_source]
type = ElementIntegralVariablePostprocessor
variable = kappa_fission
[]
[]
[Outputs]
execute_on = final
exodus = true
hide = 'temp cell_instance cell_id'
[]
(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/openmc_errors/mode/plot/plot.i)
[Mesh]
[sphere]
type = FileMeshGenerator
file = ../../../neutronics/meshes/sphere.e
[]
[]
[Problem]
type = OpenMCCellAverageProblem
[]
[Executioner]
type = Transient
[]
(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/openmc_errors/input_params/no_dag.i)
[Mesh]
[sphere]
type = FileMeshGenerator
file = ../../neutronics/meshes/sphere.e
[]
[]
[Problem]
type = OpenMCCellAverageProblem
temperature_blocks = '1'
cell_level = 0
skinner = moab
[]
[UserObjects]
[moab]
type = MoabSkinner
temperature = temp
temperature_max = 1000.0
n_temperature_bins = 5
[]
[]
[Executioner]
type = Transient
[]
(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
[]
(test/tests/neutronics/feedback/universes/fill_in_flat/openmc.i)
[Mesh]
[m]
type = GeneratedMeshGenerator
dim = 3
nx = 2
ny = 1
nz = 1
xmax = 10
ymax = 10
zmax = 10
[]
[]
[AuxVariables]
[cell_temperature]
family = MONOMIAL
order = CONSTANT
[]
[]
[AuxKernels]
[cell_temperature]
type = CellTemperatureAux
variable = cell_temperature
[]
[]
[Problem]
type = OpenMCCellAverageProblem
verbose = true
temperature_blocks = '0'
cell_level = 0
[]
[ICs]
[temp]
type = FunctionIC
variable = temp
function = temp
[]
[]
[Functions]
[temp]
type = ParsedFunction
expression = '500+50*x'
[]
[]
[Executioner]
type = Steady
[]
[Postprocessors]
[tl]
type = PointValue
variable = cell_temperature
point = '2.5 5 5'
[]
[tr]
type = PointValue
variable = cell_temperature
point = '7.5 5 5'
[]
[k]
type = KEigenvalue
[]
[]
[Outputs]
csv = true
[]
(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/gen_mgxs/hide_tally_vars.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'
[MGXS]
tally_type = cell
particle = neutron
energy_boundaries = '1e7 0.0'
estimator = 'analog'
normalize_by_global_tally = false
add_scattering = true
legendre_order = 0
transport_correction = false
add_fission = true
add_fission_heating = true
add_inverse_velocity = true
add_diffusion_coefficient = true
add_absorption = true
[]
[]
[Executioner]
type = Steady
[]
[Outputs]
execute_on = final
exodus = 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/gen_mgxs/all_mgxs_cell.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'
[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 = true
add_fission = true
add_fission_heating = true
add_inverse_velocity = true
add_diffusion_coefficient = true
add_absorption = true
[]
[]
[Executioner]
type = Steady
[]
[Postprocessors]
[abs_xs_g1]
type = PointValue
point = '0 0 0'
variable = abs_xs_g1
[]
[abs_xs_g2]
type = PointValue
point = '0 0 0'
variable = abs_xs_g2
[]
[chi_g1]
type = PointValue
point = '0 0 0'
variable = chi_g1
[]
[chi_g2]
type = PointValue
point = '0 0 0'
variable = chi_g2
[]
[diff_g1]
type = PointValue
point = '0 0 0'
variable = diff_g1
[]
[diff_g2]
type = PointValue
point = '0 0 0'
variable = diff_g2
[]
[inv_v_g1]
type = PointValue
point = '0 0 0'
variable = inv_v_g1
[]
[inv_v_g2]
type = PointValue
point = '0 0 0'
variable = inv_v_g2
[]
[kappa_fission_g1]
type = PointValue
point = '0 0 0'
variable = kappa_fission_g1
[]
[kappa_fission_g2]
type = PointValue
point = '0 0 0'
variable = kappa_fission_g2
[]
[nu_fission_xs_g1]
type = PointValue
point = '0 0 0'
variable = nu_fission_xs_g1
[]
[nu_fission_xs_g2]
type = PointValue
point = '0 0 0'
variable = nu_fission_xs_g2
[]
[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
[]
[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/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/openmc_errors/mesh_tally/incorrect_order.i)
[Mesh]
[sphere]
type = FileMeshGenerator
file = ../../neutronics/meshes/sphere.e
[]
[combine]
type = CombinerGenerator
inputs = sphere
positions = '0 0 0
0 0 4
0 0 8'
[]
[block]
type = SubdomainIDGenerator
input = combine
subdomain_id = '0'
[]
allow_renumbering = false
[]
[Problem]
type = OpenMCCellAverageProblem
temperature_blocks = '0'
initial_properties = xml
verbose = true
cell_level = 0
power = 100.0
[Tallies]
[Mesh]
type = MeshTally
mesh_template = '../../neutronics/meshes/sphere.e'
# Make the mistake of listing the mesh template translations in a different order than
# was used to create the [Mesh]. This should catch that the mesh template does not
# exactly match the [Mesh]
mesh_translations = '0 0 0
0 0 8
0 0 4'
[]
[]
[]
[Executioner]
type = Transient
num_steps = 1
[]
(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/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/neutronics/mesh_tally/block_restrict.i)
[Mesh]
[sphere]
type = FileMeshGenerator
file = ../meshes/sphere.e
[]
[solid1]
type = SubdomainIDGenerator
input = sphere
subdomain_id = '100'
[]
[sphereb]
type = FileMeshGenerator
file = ../meshes/sphere.e
[]
[solid2]
type = SubdomainIDGenerator
input = sphereb
subdomain_id = '200'
[]
[spherec]
type = FileMeshGenerator
file = ../meshes/sphere.e
[]
[solid3]
type = SubdomainIDGenerator
input = spherec
subdomain_id = '300'
[]
[combine]
type = CombinerGenerator
inputs = 'solid1 solid2 solid3'
positions_file = pebble_centers.txt
[]
[delete_solid3]
type = BlockDeletionGenerator
input = combine
block = 300
[]
allow_renumbering = false
parallel_type = replicated
[]
[Problem]
type = OpenMCCellAverageProblem
temperature_blocks = '100 200'
initial_properties = xml
verbose = true
cell_level = 0
power = 100.0
[Tallies]
[Mesh]
type = MeshTally
block = '200'
normalize_by_global_tally = false
[]
[]
[]
[Executioner]
type = Steady
[]
[Outputs]
execute_on = final
exodus = true
hide = 'temp cell_instance cell_id'
[]
(test/tests/neutronics/heat_source/particles_from_postprocessor.i)
[Mesh]
[sphere]
type = FileMeshGenerator
file = ../meshes/sphere.e
[]
[]
[Functions]
[nparticles_fn]
type = ParsedFunction
value = 100*t
[]
[]
[Postprocessors]
[n_particles]
type = FunctionValuePostprocessor
function = nparticles_fn
execute_on = 'timestep_begin'
[]
[particles_reporter]
type = OpenMCParticles
value_type = instantaneous
[]
[total_particles_reporter]
type = OpenMCParticles
value_type = total
[]
[]
[Problem]
type = OpenMCCellAverageProblem
power = 100
particles = n_particles
verbose = true
[]
[Executioner]
type = Transient
num_steps = 2
[]
[Outputs]
csv = true
exodus = false
[]
(test/tests/neutronics/mesh_tally/fission_tally_std_dev.i)
[Mesh]
[sphere]
type = FileMeshGenerator
file = ../meshes/sphere.e
[]
[solid_ids]
type = SubdomainIDGenerator
input = sphere
subdomain_id = '100'
[]
allow_renumbering = false
[]
[Problem]
type = OpenMCCellAverageProblem
temperature_blocks = '100'
initial_properties = xml
verbose = true
cell_level = 0
power = 100.0
[Tallies]
[Mesh]
type = MeshTally
mesh_template = '../meshes/sphere.e'
output = 'unrelaxed_tally_std_dev'
normalize_by_global_tally = true
check_tally_sum = false
[]
[]
[]
[Executioner]
type = Transient
num_steps = 1
[]
[Postprocessors]
[heat_source_at_pt]
type = PointValue
variable = kappa_fission
point = '0.896826 0.189852 0.608855' # centroid of first element in mesh
[]
[std_dev_at_pt]
type = PointValue
variable = kappa_fission_std_dev
point = '0.896826 0.189852 0.608855'
[]
[]
[Outputs]
csv = 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/dagmc/mesh_tallies/csg_step_1/openmc.i)
[Mesh]
type = FileMesh
file = ../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]
[Mesh]
type = MeshTally
mesh_template = ../slab.e
[]
[]
[]
[Postprocessors]
[k]
type = KEigenvalue
[]
[]
[Executioner]
type = Transient
num_steps = 2
[]
[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'
[]
(test/tests/neutronics/dagmc/incompatible_geom/mismatch/openmc.i)
[Mesh]
[load]
type = FileMeshGenerator
file = ../../mesh_tallies/slab.e
[]
[merge]
type = RenameBlockGenerator
input = load
old_block = '2'
new_block = '1'
[]
allow_renumbering = false
parallel_type = replicated
[]
[Problem]
type = OpenMCCellAverageProblem
temperature_blocks = '1'
cell_level = 0
power = 100.0
initial_properties = xml
skinner = moab
[Tallies]
[Mesh]
type = MeshTally
mesh_template = ../../mesh_tallies/slab.e
[]
[]
[]
[UserObjects]
[moab]
type = MoabSkinner
temperature_min = 0.0
temperature_max = 1000.0
n_temperature_bins = 4
temperature = temp
build_graveyard = true
[]
[]
[Executioner]
type = Steady
[]
(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/openmc_errors/cell_instances/lattice_outer/temp.i)
[Mesh]
type = GeneratedMesh
dim = 3
xmin = -1
xmax = 2
ymin = -1
ymax = 2
zmin = -1
zmax = 1
nx = 20
ny = 20
nz = 20
[]
[ICs]
[temp]
type = ConstantIC
variable = temp
value = 500
[]
[]
[Problem]
type = OpenMCCellAverageProblem
power = 1.0
temperature_blocks = 0
cell_level = 1
[]
[Executioner]
type = Steady
[]
(test/tests/neutronics/relaxation/mesh_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
[]
allow_renumbering = false
[]
[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]
[Mesh]
type = MeshTally
mesh_template = ../../meshes/sphere_in_m.e
mesh_translations = '0.0 0.0 0.02
0.0 0.0 0.06
0.0 0.0 0.10'
output = 'unrelaxed_tally'
check_tally_sum = false
[]
[]
[]
[Executioner]
type = Transient
num_steps = 3
[]
[Outputs]
exodus = true
[]
(test/tests/neutronics/kinetics/both.i)
[Mesh]
[sphere]
type = FileMeshGenerator
file = ../meshes/sphere.e
[]
[]
[Problem]
type = OpenMCCellAverageProblem
verbose = true
calc_kinetics_params = true
ifp_generations = 5
[]
[Executioner]
type = Steady
[]
[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
[]
[]
[Outputs]
csv = true
[]
(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/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/neutronics/mesh_tally/different_units.i)
[Mesh]
[sphere]
type = FileMeshGenerator
file = ../meshes/sphere_in_m.e
[]
[solid_ids]
type = SubdomainIDGenerator
input = sphere
subdomain_id = '100'
[]
allow_renumbering = false
[]
[Problem]
type = OpenMCCellAverageProblem
temperature_blocks = '100'
initial_properties = xml
verbose = true
cell_level = 0
power = 100.0
# the [Mesh] is in units of meters, so the mesh_template must also be in units of meters
scaling = 100.0
[Tallies]
[Mesh]
type = MeshTally
mesh_template = '../meshes/sphere_in_m.e'
normalize_by_global_tally = false
[]
[]
[]
[Executioner]
type = Steady
[]
[Postprocessors]
[kappa_fission]
type = ElementIntegralVariablePostprocessor
variable = kappa_fission
[]
[]
[Outputs]
execute_on = final
exodus = true
hide = 'temp cell_instance cell_id'
[]
(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/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/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/triggers/mesh_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'
[]
allow_renumbering = false
[]
[Problem]
type = OpenMCCellAverageProblem
verbose = true
power = 100.0
particles = 1000
max_batches = 200
[Tallies]
[Mesh]
type = MeshTally
mesh_template = '../meshes/sphere.e'
mesh_translations = '0 0 0
0 0 4
0 0 8'
trigger = rel_err
trigger_threshold = 5e-1
normalize_by_global_tally = false
[]
[]
[]
[Executioner]
type = Transient
num_steps = 1
[]
[Postprocessors]
[max_tally_err]
type = TallyRelativeError
[]
[]
[Outputs]
csv = true
[]
(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/criticality/rotation/openmc.i)
!include common_input.i
[Mesh]
[annulus]
type = ConcentricCircleMeshGenerator
radii = '${r_inner} ${r_outer}'
rings = '1 1'
num_sectors = '4'
has_outer_square = 'False'
preserve_volumes = 'False'
[]
[extrude]
type = AdvancedExtruderGenerator
input = 'annulus'
heights = '${height}'
num_layers = '1'
direction = '0 0 1'
subdomain_swaps = '2 1'
[]
[]
[Problem]
type = OpenMCCellAverageProblem
[CriticalitySearch]
type = RotationSearch
cell_ids = '5'
rotation_axis = 'z'
minimum = '0.0'
maximum = '90.0'
tolerance = 1e-2
[]
[]
[Executioner]
type = Steady
[]
# This test will output a 1 to CSV if the timestep converges a criticality search
[Postprocessors]
[k]
type = KEigenvalue
[]
[k_residual]
type = ParsedPostprocessor
expression = 'abs(k - 1.0)'
pp_names = 'k'
[]
[k_converged_within_tolerance]
type = ParsedPostprocessor
expression = 'if (k_residual < 1e-2, 1, 0)'
pp_names = 'k_residual'
[]
[]
[Outputs]
csv = true
hide = 'k k_residual critical_value'
[]
(test/tests/neutronics/heat_source/multi_tally_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
power = 100.0
particles = 1000.0
temperature_blocks = '100'
verbose = true
cell_level = 0
initial_properties = xml
[Tallies]
[Mesh]
type = MeshTally
score = 'kappa_fission heating'
mesh_template = ../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]
[kappa_fission]
type = ElementIntegralVariablePostprocessor
variable = kappa_fission
[]
[heating]
type = ElementIntegralVariablePostprocessor
variable = heating
[]
[]
[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
[]
(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/neutronics/gen_mgxs/subset_cell.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'
[MGXS]
tally_type = cell
particle = neutron
group_structure = CASMO_2
estimator = 'analog'
normalize_by_global_tally = false
hide_tally_vars = true
add_scattering = false
legendre_order = 0
transport_correction = true
add_fission = false
add_fission_heating = true
add_inverse_velocity = true
add_diffusion_coefficient = false
add_absorption = true
[]
[]
[Executioner]
type = Steady
[]
[Postprocessors]
[abs_xs_g1]
type = PointValue
point = '0 0 0'
variable = abs_xs_g1
[]
[abs_xs_g2]
type = PointValue
point = '0 0 0'
variable = abs_xs_g2
[]
[inv_v_g1]
type = PointValue
point = '0 0 0'
variable = inv_v_g1
[]
[inv_v_g2]
type = PointValue
point = '0 0 0'
variable = inv_v_g2
[]
[kappa_fission_g1]
type = PointValue
point = '0 0 0'
variable = kappa_fission_g1
[]
[kappa_fission_g2]
type = PointValue
point = '0 0 0'
variable = kappa_fission_g2
[]
[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
[]
(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/mesh_tally/no_coupling.i)
[Mesh]
[sphere]
type = FileMeshGenerator
file = ../meshes/sphere.e
[]
allow_renumbering = false
[]
[Problem]
type = OpenMCCellAverageProblem
verbose = true
power = 100.0
[Tallies]
[Mesh]
type = MeshTally
check_tally_sum = false
[]
[]
[]
[Executioner]
type = Steady
[]
[Postprocessors]
[power]
type = ElementIntegralVariablePostprocessor
variable = kappa_fission
[]
[]
[Outputs]
csv = true
[]
(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/symmetry/rotation.i)
[Mesh]
# using a finer mesh will more clearly show the symmetry plane,
# but we use coarser here to have a smaller gold file
[sphere]
type = FileMeshGenerator
file = ../neutronics/meshes/sphere.e
#file = ../../../tutorials/pebbles/sphere_finer.e
[]
[solid_ids]
type = SubdomainIDGenerator
input = sphere
subdomain_id = '100'
[]
[]
[AuxVariables]
[x]
family = MONOMIAL
order = CONSTANT
[]
[y]
family = MONOMIAL
order = CONSTANT
[]
[z]
family = MONOMIAL
order = CONSTANT
[]
[]
[AuxKernels]
[x]
type = PointTransformationAux
variable = x
component = x
[]
[y]
type = PointTransformationAux
variable = y
component = y
[]
[z]
type = PointTransformationAux
variable = z
component = z
[]
[]
[Problem]
type = OpenMCCellAverageProblem
symmetry_mapper = sym
[]
[UserObjects]
[sym]
type = SymmetryPointGenerator
normal = '0.0 1.0 0.0'
rotation_axis = '0.0 0.0 1.0'
rotation_angle = ${fparse 360.0 / 6.0}
[]
[]
[Executioner]
type = Transient
num_steps = 1
[]
[Outputs]
exodus = 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/kinetics/six_grp.i)
[Mesh]
[sphere]
type = FileMeshGenerator
file = ../meshes/sphere.e
[]
[]
[Problem]
type = OpenMCCellAverageProblem
verbose = true
calc_kinetics_params = true
ifp_generations = 5
[]
[Executioner]
type = Steady
[]
[Postprocessors]
[beta]
type = BetaEffective
[]
[beta_rel]
type = BetaEffective
output = rel_err
[]
[beta_std]
type = BetaEffective
output = std_dev
[]
[beta_1]
type = BetaEffective
beta_type = '1'
[]
[beta_1_rel]
type = BetaEffective
output = rel_err
beta_type = '1'
[]
[beta_1_std]
type = BetaEffective
output = std_dev
beta_type = '1'
[]
[beta_2]
type = BetaEffective
beta_type = '2'
[]
[beta_2_rel]
type = BetaEffective
output = rel_err
beta_type = '2'
[]
[beta_2_std]
type = BetaEffective
output = std_dev
beta_type = '2'
[]
[beta_3]
type = BetaEffective
beta_type = '3'
[]
[beta_3_rel]
type = BetaEffective
output = rel_err
beta_type = '3'
[]
[beta_3_std]
type = BetaEffective
output = std_dev
beta_type = '3'
[]
[beta_4]
type = BetaEffective
beta_type = '4'
[]
[beta_4_rel]
type = BetaEffective
output = rel_err
beta_type = '4'
[]
[beta_4_std]
type = BetaEffective
output = std_dev
beta_type = '4'
[]
[beta_5]
type = BetaEffective
beta_type = '5'
[]
[beta_5_rel]
type = BetaEffective
output = rel_err
beta_type = '5'
[]
[beta_5_std]
type = BetaEffective
output = std_dev
beta_type = '5'
[]
[beta_6]
type = BetaEffective
beta_type = '6'
[]
[beta_6_rel]
type = BetaEffective
output = rel_err
beta_type = '6'
[]
[beta_6_std]
type = BetaEffective
output = std_dev
beta_type = '6'
[]
[]
[Outputs]
csv = true
[]
(test/tests/neutronics/feedback/interchangeable/no_tally.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
[]
[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
[]
(tutorials/lwr_mgxs/openmc_mgxs.i)
[Mesh]
[file]
type = FileMeshGenerator
file = mesh_in.e
[]
[]
[AuxVariables]
[scatter_ratio_g1]
type = MooseVariable
family = MONOMIAL
order = CONSTANT
block = '0 1 3 4 5 6 7 8 9 10'
[]
[scatter_ratio_g2]
type = MooseVariable
family = MONOMIAL
order = CONSTANT
block = '0 1 3 4 5 6 7 8 9 10'
[]
[]
[AuxKernels]
[comp_scatter_ratio_g1]
type = ParsedAux
variable = scatter_ratio_g1
coupled_variables = 'total_xs_g1 scatter_xs_g1_gp1_l0 scatter_xs_g1_gp2_l0'
expression = '(scatter_xs_g1_gp1_l0 + scatter_xs_g1_gp2_l0) / total_xs_g1'
block = '0 1 3 4 5 6 7 8 9 10'
[]
[comp_scatter_ratio_g2]
type = ParsedAux
variable = scatter_ratio_g2
coupled_variables = 'total_xs_g2 scatter_xs_g2_gp1_l0 scatter_xs_g2_gp2_l0'
expression = '(scatter_xs_g2_gp1_l0 + scatter_xs_g2_gp2_l0) / total_xs_g2'
block = '0 1 3 4 5 6 7 8 9 10'
[]
[]
[Problem]
type = OpenMCCellAverageProblem
# Since we're generating multi-group cross sections the value
# of power chosen is arbitrary.
power = 1.0
# We set the cell level to 1 to ensure we get multi-group cross
# sections for each unique cell in the lattice.
cell_level = 1
verbose = true
particles = 10000
inactive_batches = 50
batches = 1000
# The MGXS block is adding fission heating, so we set the source
# rate normalization to 'kappa_fission'.
source_rate_normalization = 'kappa_fission'
[]
[Problem/MGXS]
tally_type = cell
group_structure = CASMO_2
particle = neutron
estimator = analog
block = '0 1 3 4 5 6 7 8 9 10'
add_fission = true
add_fission_heating = true
transport_correction = false
[]
[Executioner]
type = Steady
[]
[Outputs]
exodus = true
execute_on = 'TIMESTEP_END'
[]
(test/tests/neutronics/feedback/universes/lattice_in_flat/openmc.i)
[Mesh]
[m]
type = GeneratedMeshGenerator
dim = 3
nx = 2
ny = 1
nz = 1
xmax = 10
ymax = 10
zmax = 10
[]
[]
[Problem]
type = OpenMCCellAverageProblem
temperature_blocks = '0'
cell_level = 0
[]
[ICs]
[temp]
type = FunctionIC
variable = temp
function = temp
[]
[]
[Functions]
[temp]
type = ParsedFunction
expression = '500+50*x'
[]
[]
[Executioner]
type = Steady
[]
(tutorials/csg_to_cad/openmc.i)
power = 3000
[Problem]
type = OpenMCCellAverageProblem
power = ${power}
temperature_blocks = '1'
cell_level = 1
skinner = skinner
source_rate_normalization = 'kappa_fission'
[Tallies]
[mesh]
type = MeshTally
score = 'kappa_fission flux'
normalize_by_global_tally = false
[]
[]
[]
[Mesh]
[fuel]
type = FileMeshGenerator
file = krusty_fuel.e
[]
[]
[UserObjects]
[skinner]
type = MoabSkinner
temperature = temp
n_temperature_bins = 4
temperature_min = 800
temperature_max = 1000
build_graveyard = true
[]
[]
[MultiApps]
[conduction]
type = TransientMultiApp
input_files = 'fuel.i'
execute_on = timestep_end
[]
[]
[Transfers]
[heat_source_from_openmc]
type = MultiAppGeneralFieldShapeEvaluationTransfer
to_multi_app = conduction
source_variable = kappa_fission
variable = power
from_postprocessors_to_be_preserved = tally_integral
to_postprocessors_to_be_preserved = tally_integral
[]
[temp_to_openmc]
type = MultiAppGeneralFieldShapeEvaluationTransfer
from_multi_app = conduction
variable = temp
source_variable = T
[]
[]
[ICs]
[temp]
type = ConstantIC
variable = temp
value = 800
[]
[power]
type = ConstantIC
variable = kappa_fission
value = ${fparse power/1.865e+03}
[]
[]
[Postprocessors]
[tally_integral]
type = ElementIntegralVariablePostprocessor
variable = kappa_fission
execute_on = 'initial transfer timestep_end'
[]
[]
[Executioner]
type = Transient
num_steps = 3
[]
[Outputs]
exodus = 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/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'
[]
[]
(test/tests/neutronics/indicators/od/openmc.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_hmin]
type = ElementOpticalDepthIndicator
rxn_rate = 'total'
h_type = 'min'
[]
[optical_depth_hmax]
type = ElementOpticalDepthIndicator
rxn_rate = 'total'
h_type = 'max'
[]
[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'
[Tallies]
[Mesh]
type = MeshTally
score = 'kappa_fission flux total'
normalize_by_global_tally = false
[]
[]
[]
[Executioner]
type = Steady
[]
[Outputs]
execute_on = final
exodus = true
hide = 'temp cell_instance cell_id kappa_fission flux total'
[]
(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
[]
(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
[]
(tutorials/lwr_amr/openmc.i)
[Mesh]
[file]
type = FileMeshGenerator
file = mesh_in.e
[]
[]
[Problem]
type = OpenMCCellAverageProblem
particles = 10000
inactive_batches = 50
batches = 1000
power = ${fparse 3000e6 / 273 * 4}
assume_separate_tallies = true
skip_statepoint = true
[Tallies]
[heat_source]
type = MeshTally
score = 'kappa_fission'
name = 'heat_source'
output = 'unrelaxed_tally_std_dev'
block = 'uo2_center uo2'
normalize_by_global_tally = false
[]
[]
[]
[Postprocessors]
[max_rel_err]
type = TallyRelativeError
value_type = max
tally_score = kappa_fission
[]
[min_rel_err]
type = TallyRelativeError
value_type = min
tally_score = kappa_fission
[]
[avg_rel_err]
type = TallyRelativeError
value_type = average
tally_score = kappa_fission
[]
[]
[Executioner]
type = Steady
[]
[Outputs]
execute_on = 'timestep_end'
exodus = true
csv = true
[]
(test/tests/neutronics/feedback/temperature/two_one/openmc_multi_temp.i)
[Mesh]
[initial]
type = GeneratedMeshGenerator
dim = 3
xmin = -50.0
xmax = 50.0
ymin = -25.0
ymax = 25.0
zmin = 0.0
zmax = 50.0
nx = 20
ny = 15
nz = 15
[]
[split]
type = ParsedSubdomainMeshGenerator
input = initial
combinatorial_geometry = 'x < 0.0'
block_id = '3'
[]
[]
[ICs]
[temp_left]
type = FunctionIC
variable = temp_left
function = temperature
[]
[temp_right]
type = FunctionIC
variable = temp_right
function = temperature
[]
[]
[Functions]
[temperature]
type = ParsedFunction
expression = '1000 + 10*x'
[]
[]
[AuxVariables]
[cell_temp]
family = MONOMIAL
order = CONSTANT
[]
[]
[AuxKernels]
[cell_temp]
type = CellTemperatureAux
variable = cell_temp
[]
[]
[Problem]
type = OpenMCCellAverageProblem
verbose = true
cell_level = 0
temperature_variables = 'temp_left; temp_right'
temperature_blocks = '3; 0'
[]
[Executioner]
type = Steady
[]
[Postprocessors]
[k]
type = KEigenvalue
[]
[T_left]
type = PointValue
variable = cell_temp
point = '-25.0 0.0 0.0'
[]
[T_right]
type = PointValue
variable = cell_temp
point = '25.0 0.0 0.0'
[]
[]
[Outputs]
csv = 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/openmc_errors/mesh_tally/incorrect_scaling.i)
[Mesh]
[sphere]
type = FileMeshGenerator
file = ../../neutronics/meshes/sphere_in_m.e
[]
[solid_ids]
type = SubdomainIDGenerator
input = sphere
subdomain_id = '100'
[]
allow_renumbering = false
[]
[Problem]
type = OpenMCCellAverageProblem
temperature_blocks = '100'
initial_properties = xml
verbose = true
cell_level = 0
power = 100.0
scaling = 100.0
normalize_by_global_tally = false
[Tallies]
[Mesh]
type = MeshTally
# We incorrectly provide a mesh in units of centimeters
mesh_template = '../../neutronics/meshes/sphere.e'
[]
[]
[]
[Executioner]
type = Transient
num_steps = 1
[]
(test/tests/neutronics/moving_mesh/mesh_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'
[]
allow_renumbering = false
[]
[Problem]
type = OpenMCCellAverageProblem
cell_level = 0
verbose = true
power = 1
[Tallies]
[heat]
type = MeshTally
score = 'kappa_fission'
# the underlying OpenMC model is not changing, so parts of the geometry become
# uncovered as the [Mesh] moves
check_tally_sum = false
[]
[]
[]
[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
[]
[power_left]
type = ElementIntegralVariablePostprocessor
variable = kappa_fission
block = 'left'
[]
[]
[Executioner]
type = Transient
num_steps = 2
[]
[Outputs]
exodus = true
[]
(test/tests/openmc_errors/input_params/levels.i)
[Mesh]
[sphere]
type = FileMeshGenerator
file = ../../neutronics/meshes/sphere.e
[]
[]
[Problem]
type = OpenMCCellAverageProblem
temperature_blocks = '1'
cell_level = 0
lowest_cell_level = 0
[]
[Executioner]
type = Transient
[]
(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/mesh_tally/multiple_meshes.i)
[Mesh]
[sphere]
type = FileMeshGenerator
file = ../meshes/sphere.e
[]
[solid1]
type = SubdomainIDGenerator
input = sphere
subdomain_id = '100'
[]
[sphereb]
type = FileMeshGenerator
file = ../meshes/sphere.e
[]
[solid2]
type = SubdomainIDGenerator
input = sphereb
subdomain_id = '200'
[]
[spherec]
type = FileMeshGenerator
file = ../meshes/sphere.e
[]
[solid3]
type = SubdomainIDGenerator
input = spherec
subdomain_id = '300'
[]
[combine]
type = CombinerGenerator
inputs = 'solid1 solid2 solid3'
positions_file = pebble_centers.txt
[]
allow_renumbering = false
[]
[Problem]
type = OpenMCCellAverageProblem
temperature_blocks = '100 200 300'
initial_properties = xml
verbose = true
cell_level = 0
power = 100.0
[Tallies]
[Mesh]
type = MeshTally
mesh_translations_file = pebble_centers.txt
mesh_template = '../meshes/sphere.e'
normalize_by_global_tally = false
[]
[]
[]
[Executioner]
type = Steady
[]
[Postprocessors]
[kappa_fission]
type = ElementIntegralVariablePostprocessor
variable = kappa_fission
[]
[heat_pebble1]
type = ElementIntegralVariablePostprocessor
variable = kappa_fission
block = '100'
[]
[heat_pebble2]
type = ElementIntegralVariablePostprocessor
variable = kappa_fission
block = '200'
[]
[heat_pebble3]
type = ElementIntegralVariablePostprocessor
variable = kappa_fission
block = '300'
[]
[]
[Outputs]
execute_on = final
exodus = true
hide = 'temp cell_instance cell_id'
[]
(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/mesh_tally/scaling_mm.i)
[Mesh]
[sphere]
type = FileMeshGenerator
file = ../meshes/sphere.e
[]
[solid_ids]
type = SubdomainIDGenerator
input = sphere
subdomain_id = '100'
[]
[smg]
type = TransformGenerator
input = solid_ids
transform = 'SCALE'
vector_value = '0.01 0.01 0.01'
[]
allow_renumbering = false
[]
[Problem]
type = OpenMCCellAverageProblem
temperature_blocks = '100'
initial_properties = xml
verbose = true
cell_level = 0
power = 100.0
scaling = 100.0
[Tallies]
[Mesh]
type = MeshTally
normalize_by_global_tally = false
[]
[]
[]
[Executioner]
type = Steady
[]
[Postprocessors]
[max_rel_err]
type = TallyRelativeError
value_type = max
[]
[min_rel_err]
type = TallyRelativeError
value_type = min
[]
[max]
type = ElementExtremeValue
variable = kappa_fission
value_type = max
[]
[min]
type = ElementExtremeValue
variable = kappa_fission
value_type = min
[]
[]
[Outputs]
execute_on = final
csv = true
[]
(test/tests/neutronics/feedback/multi_component_density/multi/multi_vars_alt.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
[]
[split_top]
type = ParsedSubdomainMeshGenerator
input = upper_block
combinatorial_geometry = 'x > 30.0 & y > 12.5'
block_id = 50
[]
[]
[AuxVariables]
[cell_density]
family = MONOMIAL
order = CONSTANT
[]
[total_density]
family = MONOMIAL
order = CONSTANT
[]
[]
[AuxKernels]
[cell_density]
type = CellDensityAux
variable = cell_density
[]
[]
[ICs]
[d1]
type = ConstantIC
variable = density1
value = 15e3
block = '0'
[]
[d2]
type = ConstantIC
variable = density2
value = 3000
block = '1'
[]
[d3]
type = ConstantIC
variable = density2
value = 7000
block = '50'
[]
[dd1]
type = ConstantIC
variable = total_density
value = 15e3
block = '0'
[]
[dd2]
type = ConstantIC
variable = total_density
value = 3000
block = '1'
[]
[dd3]
type = ConstantIC
variable = total_density
value = 7000
block = '50'
[]
[]
[Problem]
type = OpenMCCellAverageProblem
verbose = true
cell_level = 0
density_variables = 'density1; density2'
density_blocks = '0; 1 50'
temperature_blocks = '0 1 50'
[]
[Postprocessors]
[k]
type = KEigenvalue
[]
[rho_0]
type = ElementAverageValue
variable = cell_density
block = '0'
[]
[rho_1]
type = ElementAverageValue
variable = cell_density
block = '1'
[]
[avg_cell0]
type = ElementAverageValue
variable = cell_density
block = '0'
[]
[avg_cell1]
type = ElementAverageValue
variable = cell_density
block = '1 50'
[]
[]
[Executioner]
type = Transient
num_steps = 1
[]
[Outputs]
csv = true
exodus = true
[]
(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
[]
[]
(test/tests/openmc_errors/mode/particle/particle.i)
[Mesh]
[sphere]
type = FileMeshGenerator
file = ../../../neutronics/meshes/sphere.e
[]
[]
[Problem]
type = OpenMCCellAverageProblem
[]
[Executioner]
type = Transient
[]
(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/neutronics/symmetry/wrong_uo.i)
num_layers = 1
channel_diameter = 0.016 # diameter of the coolant channels (m)
height = 6.343 # height of the full core (m)
[Mesh]
[solid]
type = FileMeshGenerator
file = solid_mesh_in.e
[]
allow_renumbering = false
[]
[Problem]
type = OpenMCCellAverageProblem
power = 1000.0
scaling = 100.0
temperature_blocks = '1 2'
cell_level = 1
symmetry_mapper = sym
[Tallies]
[Mesh]
type = MeshTally
mesh_template = solid_mesh_in.e
[]
[]
[]
[UserObjects]
[sym]
type = NearestNodeNumberUO
point = '0.0 0.0 0.0'
[]
[]
[Executioner]
type = Steady
[]
(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/userobjects/volume_calculation/user_bb.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
verbose = true
cell_level = 0
temperature_blocks = '100'
initial_properties = xml
volume_calculation = vol
[]
[UserObjects]
[vol]
type = OpenMCVolumeCalculation
n_samples = 10000
lower_left = '0 0 0'
upper_right = '0.1 0.1 0.1'
[]
[]
[Executioner]
type = Steady
[]
[Postprocessors]
[vol_1]
type = PointValue
variable = cell_vol
point = '0.0 0.0 0.0'
[]
[]
[Outputs]
csv = 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
[]