openmc
– Basic Functionality¶
Handling nuclear data¶
A multigroup cross section data set providing all the multigroup data necessary for a multigroup OpenMC calculation. 

MultiGroup Cross Sections file used for an OpenMC simulation. 
Simulation Settings¶
Distribution of phase space coordinates for source sites. 

Source particle 

Stochastic volume calculation specifications and results. 

Meshbased weight windows 

Settings used for an OpenMC simulation. 
Write a source file using a collection of source particles 

Create WeightWindows instances from a wwinp file 
Material Specification¶
A nuclide that can be used in a material. 

A natural element that autoexpands to add the isotopes of an element to a material in their natural abundance. 

A Macroscopic object that can be used in a material. 

A material composed of a collection of nuclides/elements. 

Collection of Materials used for an OpenMC simulation. 
Cross sections for nuclides, elements, and materials can be plotted using the following function:
Creates a figure of continuousenergy cross sections for this item. 
Building geometry¶
An arbitrary plane of the form \(Ax + By + Cz = D\). 

A plane perpendicular to the x axis of the form \(x  x_0 = 0\) 

A plane perpendicular to the y axis of the form \(y  y_0 = 0\) 

A plane perpendicular to the z axis of the form \(z  z_0 = 0\) 

An infinite cylinder whose length is parallel to the xaxis of the form \((y  y_0)^2 + (z  z_0)^2 = r^2\). 

An infinite cylinder whose length is parallel to the yaxis of the form \((x  x_0)^2 + (z  z_0)^2 = r^2\). 

An infinite cylinder whose length is parallel to the zaxis of the form \((x  x_0)^2 + (y  y_0)^2 = r^2\). 

A sphere of the form \((x  x_0)^2 + (y  y_0)^2 + (z  z_0)^2 = r^2\). 

A conical surface parallel to the x, y, or zaxis. 

A cone parallel to the xaxis of the form \((y  y_0)^2 + (z  z_0)^2 = r^2 (x  x_0)^2\). 

A cone parallel to the yaxis of the form \((x  x_0)^2 + (z  z_0)^2 = r^2 (y  y_0)^2\). 

A cone parallel to the zaxis of the form \((x  x_0)^2 + (y  y_0)^2 = r^2 (z  z_0)^2\). 

A surface of the form \(Ax^2 + By^2 + Cz^2 + Dxy + Eyz + Fxz + Gx + Hy + Jz + K = 0\). 

A torus of the form \((x  x_0)^2/B^2 + (\sqrt{(y  y_0)^2 + (z  z_0)^2}  A)^2/C^2  1 = 0\). 

A torus of the form \((y  y_0)^2/B^2 + (\sqrt{(x  x_0)^2 + (z  z_0)^2}  A)^2/C^2  1 = 0\). 

A torus of the form \((z  z_0)^2/B^2 + (\sqrt{(x  x_0)^2 + (y  y_0)^2}  A)^2/C^2  1 = 0\). 

A positive or negative halfspace region. 

Intersection of two or more regions. 

Union of two or more regions. 

Complement of a region. 

A region of space defined as the intersection of halfspace created by quadric surfaces. 

A collection of cells that can be repeated. 

A reference to a DAGMC file to be used in the model. 

A lattice consisting of rectangular prisms. 

A lattice consisting of hexagonal prisms. 

Geometry representing a collection of surfaces, cells, and universes. 
Many of the above classes are derived from several abstract classes:
An implicit surface with an associated boundary condition. 

Region of space that can be assigned to a cell. 

A repeating structure wherein each element is a universe. 
Constructing Tallies¶
Tally modifier that describes phasespace and other characteristics. 

Bins tally event locations based on the Universe they occurred in. 

Bins tally event locations based on the Material they occurred in. 

Bins tally event locations based on the Cell they occurred in. 

Bins tally on which cell the particle came from. 

Bins tally events based on which cell the particle was born in. 

Bins tally events based on which cell instance a particle is in. 

Bins tally events based on the number of collisions. 

Filters particles by surface crossing 

Bins tally event locations onto a regular, rectangular mesh. 

Filter events by surface crossings on a regular, rectangular mesh. 

Bins tally events based on incident particle energy. 

Bins tally events based on outgoing particle energy. 

Bins tally events based on particle scattering angle. 

Bins tally events based on the incident particle's direction. 

Bins tally events based on the incident particle's direction. 

Bins tally event locations on instances of repeated cells. 

Bins fission events based on the produced neutron precursor groups. 

Multiplies tally scores by an arbitrary function of incident energy. 

Score Legendre expansion moments up to specified order. 

Score Legendre expansion moments in space up to specified order. 

Score spherical harmonic expansion moments up to specified order. 

Bins tally events based on the particle's time. 

Score Zernike expansion moments in space up to specified order. 

Score the \(m = 0\) (radial variation only) Zernike moments up to specified order. 

Bins tally events based on the Particle type. 

A regular Cartesian mesh in one, two, or three dimensions 

A 3D rectilinear Cartesian mesh 

A 3D cylindrical mesh 

A 3D spherical mesh 

A 3D unstructured mesh 

A criterion for when to finish a simulation based on tally uncertainties. 

A material perturbation derivative to apply to a tally. 

A tally defined by a set of scores that are accumulated for a list of nuclides given a set of filters. 

Collection of Tallies used for an OpenMC simulation. 
Geometry Plotting¶
Definition of a finite region of space to be plotted. 

Collection of Plots used for an OpenMC simulation. 
Running OpenMC¶
Run an OpenMC simulation. 

Run stochastic volume calculations in OpenMC. 

Run OpenMC in plotting mode 

Display plots inline in a Jupyter notebook. 

Function to perform a keff search by modifying a model parametrized by a single independent variable. 
Postprocessing¶
Information used to restart a specific particle that caused a simulation to fail. 

Particle track information 

State information on a simulation at a certain point in time (at the end of a given batch). 

Summary of model used in a simulation. 

Tracks resulting from a single source particle 

Collection of particle tracks 
The following classes and functions are used for functional expansion reconstruction.
Create radial only Zernike polynomials given coefficients and domain. 
Return a Legendre series object based on expansion coefficients. 
Various classes may be created when performing tally slicing and/or arithmetic:
A specialpurpose tally score used to encapsulate all combinations of two tally's scores as an outer product for tally arithmetic. 

A specialpurpose nuclide used to encapsulate all combinations of two tally's nuclides as an outer product for tally arithmetic. 

A specialpurpose filter used to encapsulate all combinations of two tally's filter bins as an outer product for tally arithmetic. 

A specialpurpose tally score used to encapsulate an aggregate of a subset or all of tally's scores for tally aggregation. 

A specialpurpose tally nuclide used to encapsulate an aggregate of a subset or all of tally's nuclides for tally aggregation. 

A specialpurpose tally filter used to encapsulate an aggregate of a subset or all of a tally filter's bins for tally aggregation. 
Coarse Mesh Finite Difference Acceleration¶
CMFD is implemented in OpenMC and allows users to accelerate fission source
convergence during inactive neutron batches. To use CMFD, the
openmc.cmfd.CMFDRun
class executes OpenMC through the C API, solving
the CMFD system between fission generations and modifying the source weights.
Note that the openmc.cmfd
module is not imported by default with the
openmc
namespace and needs to be imported explicitly.
A structured Cartesian mesh used for CMFD acceleration. 

Class for running CMFD acceleration through the C API. 
At the minimum, a CMFD mesh needs to be specified in order to run CMFD. Once the
mesh and other optional properties are set, a simulation can be run with CMFD
turned on using openmc.cmfd.CMFDRun.run()
.