Skip to content

Releases: openmc-dev/openmc

OpenMC 0.15.0

22 Jun 01:46
55b52b7
Compare
Choose a tag to compare

This release of OpenMC includes many bug fixes, performance improvements, and several notable new features. The major highlight of this release is the introduction of a new transport solver based on the random ray method, which is fully described in the user's guide. Other notable additions include a mesh-based source class (openmc.MeshSource), a generalization of source domain rejection through the notion of "constraints", and new methods on mesh-based classes for computing material volume fractions and homogenized materials.

Compatibility Notes and Deprecations

Previously, specifying domain rejection for a source was only possible on the openmc.IndependentSoure class and worked by specifying a domains argument. This capability has been generalized to all source classes and expanded as well; specifying a domain to reject on should now be done with the constraints argument as follows:

source = openmc.IndependentSource(..., constraints={'domains': [cell]})

The domains argument is deprecated and will be removed in a future version of OpenMC. Similarly, the only_fissionable argument to openmc.stats.Box has been replaced by a 'fissionable' constraint. That is, instead of specifying:

space = openmc.stats.Box(lower_left, upper_right, only_fissionable=True)
source = openmc.IndependentSource(space=space)

You should now provide the constraint as:

space = openmc.stats.Box(lower_left, upper_right)
source = openmc.IndependentSource(space=space, constraints={'fissionable': True})

The openmc.Settings.max_splits attribute was renamed to max_history_splits and its default value has been changed to 1e7 (#2954).

New Features

  • When running OpenMC in volume calculation mode, only atomic weight ratio data is loaded from data files which reduces initialization time. (#2741)
  • Introduced a GeometryState class in C++ to better separate particle and geometry data. (#2744))
  • A new openmc.MaterialFromFilter class allows filtering tallies by which material a particle came from. (#2750)
  • Implemented a openmc.deplete.MicroXS.from_multigroup_flux method that generates microscopic cross sections for depletion from a predetermined multigroup flux. (#2755)
  • A new openmc.MeshSource class enables the specification of a source distribution over a mesh, where each mesh element has a different energy/angle/time distribution. (#2759)
  • Improve performance of depletion solver by utilizing CSR sparse matrix representation. (#2764,
    #2771)
  • Added a openmc.CylindricalMesh.get_indices_at_coords method that provides the mesh element index corresponding to a given point in space. (#2782)
  • Added a path argument to the openmc.deplete.Integrator.integrate method. (#2784)
  • Added a openmc.Geometry.get_all_nuclides method. (#2796)
  • A new capability to compute material volume fractions over mesh elements was added in the openmc.lib.Mesh.material_volumes method. (#2802)
  • A new transport solver was added based on the random ray method. (#2823, #2988)
  • Added a openmc.lib.Material.depletable attribute. (#2843)
  • Added a openmc.lib.Mesh.get_plot_bins method and corresponding openmc_mesh_get_plot_bins C API function that can be utilized to generate mesh tally visualizations in the plotter application. (#2854)
  • Introduced a openmc.read_source_file function that enables reading a source file from the Python API. (#2858)
  • Added a bounding_box property on the openmc.RectilinearMesh and openmc.UnstructuredMesh classes. (#2861)
  • Added a openmc_mesh_get_volumes C API function. (#2869)
  • The openmc.Settings.surf_source_write dictionary now accepts cell, cellfrom, or cellto keys that limit surface source sites to those entering or leaving specific cells. (#2888)
  • Added a openmc.Region.plot method that allows regions to be plotted directly. (#2895)
  • Implemented "contains" operator for the openmc.BoundingBox class. (#2906)
  • Generalized source rejection via a new constraints argument to all source classes. (#2916)
  • Added a new openmc.MeshBornFilter class that filters tally events based on which mesh element a particle was born in. (#2925)
  • The openmc.Trigger class now has a ignore_zeros argument that results in any bins with zero score to be ignored when checking the trigger. (#2928)
  • Introduced a openmc.Settings.max_events attribute that controls the maximum number of events a particle can undergo. (#2945)
  • Added support for openmc.UnstructuredMesh in the openmc.MeshSource class. (#2949)
  • Added a openmc.MeshBase.get_homogenized_materials method that computes homogenized materials over mesh elements. (#2971)
  • Add an options argument to openmc.UnstructuredMesh that allows configuring underlying data structures in MOAB. (#2976)
  • Type hints were added to several classes in the :mod:openmc.deplete module. (#2866)

Bug Fixes

  • Fix unit conversion in openmc.deplete.Results.get_mass (#2761)
  • Fix Lagrangian interpolation (#2775)
  • Depletion restart with MPI (#2778)
  • Modify depletion transfer rates test to be more robust (#2779)
  • Call simulation_finalize if needed when finalizing OpenMC (#2790)
  • F90_NONE Removal (MGMC tallying optimization) (#2785)
  • Correctly apply volumes to materials when using DAGMC geometries (#2787)
  • Add inline to openmc::interpolate (#2789)
  • Use huge_tree=True in lxml parsing (#2791)
  • OpenMPMutex "Copying" (#2794)
  • Do not link against several transitive dependencies of HDF5 (#2797)
  • Added check to length of input arguments for IndependantOperator (#2799)
  • Pytest Update Documentation (#2801)
  • Move 'import lxml' to third-party block of imports (#2803)
  • Fix creation of meshes when from loading settings from XML (#2805)
  • Avoid high memory use when writing unstructured mesh VTK files (#2806)
  • Consolidating thread information into the openmp interface header (#2809)
  • Prevent underflow in calculation of speed (#2811)
  • Provide error message if a cell path can't be determined (#2812)
  • Fix distribcell labels for lattices used as fill in multiple cells (#2813)
  • Make creation of spatial trees based on usage for unstructured mesh. (#2815)
  • Ensure particle direction is normalized for plotting / volume calculations (#2816)
  • Added missing meshes to documentation (#2820)
  • Reset timers at correct place in deplete (#2821)
  • Fix config change not propagating through to decay energies (#2825)
  • Ensure that implicit complement cells appear last in DAGMC universes (#2838)
  • Export model.tallies to XML in CoupledOperator (#2840)
  • Fix locating h5m files references in DAGMC universes (#2842)
  • Prepare for NumPy 2.0 (#2845)
  • Added missing functions and classes to openmc.lib docs (#2847)
  • Fix compilation on CentOS 7 (missing link to libdl) (#2849)
  • Adding resulting nuclide to cross section plot legend (#2851)
  • Updating file extension for Excel files when exporting MGXS data (#2852)
  • Removed error raising when calling warn (#2853)
  • Setting surf_source_ attribute for DAGMC surfaces. (#2857)
  • Changing y axis label for heating plots (#2859)
  • Removed unused step_index arg from restart (#2867)
  • Fix issue with Cell::get_contained_cells() utility function (#2873)
  • Adding energy axis units to plot xs (#2876)
  • Set OpenMCOperator materials when diff_burnable_mats = True (#2877)
  • Fix expansion filter merging (#2882)
  • Added checks that tolerance value is between 0 and 1 (#2884)
  • Statepoint file loading refactor and CAPI function (#2886)
  • Added check for length of value passed into EnergyFilter (#2887)
  • Ensure that Model.run() works when specifying a custom XML path (#2889)
  • Updating docker file base to bookworm (#2890)
  • Clarifying documentation for cones (#2892)
  • Abort on cmake config if openmp requested but not found (#2893)
  • Tiny updates from experience building on Mac (#2894)
  • Added damage-energy as optional reaction for micro (#2903)
  • docs: add missing max_splits in settings specification (#2910)
  • Changed CI to use latest actions to get away from the Node 16 deprecation. (#2912)
  • Mkdir to always allow parents and exist ok (#2914)
  • Fixed small sphinx typo (#2915)
  • Hexagonal lattice iterators (#2921)
  • Fix Chain.form_matrix to work with scipy 1.12 (#2922)
  • Allow get_microxs_and_flux to use OPENMC_CHAIN_FILE environment variable (#2934)
  • Polygon fix to better handle colinear points (#2935)
  • Fix CMFD to work with scipy 1.13 (#2936)
  • Print warning if no natural isotopes when using add_element (#2938)
  • Update xtl and xtensor submodules (#2941)
  • Ensure two surfaces with different boundary type are not considered redundant (#2942)
  • Updated package versions in Dockerfile (#2946)
  • Add MPI calls to DAGMC external test (#2948)
  • Eliminate deprecation warnings from scipy and pandas (#2951)
  • Update math function unit test with catch2 (#2955)
  • Support track file writing for particle restart runs. (#2957)
  • Make UWUW optional (#2965)
  • Allow pure decay IndependentOperator (#2966)
  • Added fix to cfloat_endf for length 11 endf floats (#2967)
  • Moved apt get to optional CI parts (#2970)
  • Update bounding_box docstrings (#2972)
  • Added extra error checking on spherical mesh creation (#2973)
  • Update CODEOWNERS file (#2974)
  • Added error checking on cylindrical mesh (#2977)
  • Correction for histogram interpolation of Tabular distributions (#2981)
  • Enforce lower_left in lattice geometry (#2982)
  • Update random_dist.h comment to be less specific (#2991)
  • Apply memoization in get_all_universes (#2995)
  • Make sure skewed dataset is cast to bool properly (#3001)
  • Hexagonal lattice roundtrip (#3003)
  • Fix CylinderSector and IsogonalOctagon translations (#3018)
  • Sets used instead of lists when membership testing (#3021)
  • Fixing plot xs for when plotting element string reaction (#3029)
  • Fix shannon entropy broken link (...
Read more

OpenMC 0.14.0

06 Nov 21:21
fa23301
Compare
Choose a tag to compare

This release of OpenMC includes many bug fixes, performance improvements, and several notable new features. Some of the highlights include projection plots, pulse height tallies for photons, weight window generation, and an ability to specify continuous removal or feed of nuclides/elements during depletion. Additionally, one of the longstanding annoyances of depletion calculations, namely the need to include initial "dilute" nuclides, has been eliminated. There are also a wide array of general improvements in the Python API.

Compatibility Notes and Deprecations

  • The openmc.deplete.MicroXS class has been completely redesigned and improved. See further comments below under "New Features". (#2572, #2579, #2595, #2700)
  • The rectangular_prism function has been replaced by the openmc.model.RectangularPrism class and the hexagonal_prism function has been replaced by the openmc.model.HexagonalPrism class. Note that whereas the rectangular_prism and hexagonal_prism functions returned a region representing the interior of the prism, the new openmc.model.RectangularPrism and
    openmc.model.HexagonalPrism classes return composite surfaces, so you need to use the unary - or + operators to obtain a region that can be assigned to a cell. (#2739)
  • The Source class has been refactored and split up into three separate classes: openmc.IndependentSource, openmc.FileSource, and openmc.CompiledSource. (#2524)
  • The vertices and centroids attributes on mesh classes now always return Cartesian coordinates and the shape of the returned arrays has changed to allow ijk indexing using a tuple (i.e., xyz = vertices[i, j, k]). (#2711)
  • The openmc.Material.decay_photon_energy attribute has been replaced by the openmc.Material.get_decay_photon_energy method. (#2715)

New Features

  • A new openmc.ProjectionPlot class enables the generation of orthographic or perspective projection plots. (#1926)
  • The openmc.model.RightCircularCylinder class now supports optional filleted edges. (#2309)
  • Continuous removal or feed of nuclides/elements between materials can now be modeled during depletion via the openmc.deplete.abc.Integrator.add_transfer_rate method. (#2358, #2564, #2626)
  • The MAGIC method for global weight window generation has been implemented as part of the C++ API. (#2359)
  • A new capability for pulse height tallies (currently limited to photons) has been added and can be used via the "pulse-height" tally score. (#2452)
  • A openmc.model.CruciformPrism class has been added that provides a generalized cruciform prism composite surface. (#2457)
  • Type hints have been added in various places throughout the Python API. (#2462 , #2467, #2468, #2470, #2471, #2601)
  • Voxel plots can now be generated through the openmc.Plot.to_vtk method. (#2464)
  • The openmc.mgxs.EnergyGroups class now allows you to alternatively pass a string of the group structure name (e.g., "CCFE-709") instead of the energy group boundaries. (#2466)
  • Several enhancements have been made to the openmc.Universe.plot method (addition of axis labels with units, ability to show legend and/or outlines, automatic determination of origin/width, ability to pass total number of pixels). (#2472 , #2482, #2483, #2492, #2513, #2575)
  • Functionality in the Python API dealing with bounding boxes now relies on a new openmc.BoundingBox class. (#2475)
  • Users now have more flexibility in specifying nuclides and reactions in the openmc.plot_xs function. (#2478)
  • The import time of the openmc Python module has been improved by deferring the import of matplotlib. (#2488)
  • Mesh clases in the Python API now support a bounding_box property. (#2507, #2620, #2621)
  • The Source class has been refactored and split up into three separate classes: openmc.IndependentSource, openmc.FileSource, and openmc.CompiledSource. (#2524)
  • Support was added for curvilinear elements when exporting cylindrical and spherical meshes to VTK. (#2533)
  • The openmc.Tally class now has a openmc.Tally.multiply_density attribute that indicates whether reaction rate tallies should include the number density of the nuclide of interest. (#2539)
  • The openmc.wwinp_to_wws function now supports wwinp files with cylindrical or spherical meshes. (#2556)
  • Depletion no longer relies on adding initial "dilute" nuclides to each depletable material in order to compute reaction rates. (#2559, #2568)
  • The openmc.deplete.Results class now has openmc.deplete.Results.get_mass (#2565), openmc.deplete.Results.get_activity (#2617), and openmc.deplete.Results.get_decay_heat (#2625) methods.
  • The openmc.deplete.StepResult.save method now supports a path argument. (#2567)
  • The openmc.deplete.MicroXS has been completely redesigned and improved. First, it no longer relies on the openmc.mgxs module, no longer subclasses pandas.DataFrame, and doesn't require adding initial "dilute" nuclides into material compositions. It now enables users to specify an energy group structure to collect multigroup cross sections, specify nuclides/reactions, and works with mesh domains in addition to the existing domains. A new openmc.deplete.get_microxs_and_flux function was added that improves the workflow for calculating microscopic cross sections along with fluxes. Altogether, these changes make it straightforward to switch between coupled and independent operators for depletion/activation calculations. (#2572, #2579 , #2595, #2700)
  • The openmc.Geometry class now has merge_surfaces and surface_precision arguments. (#2602)
  • Several predefined energy group structures have been added ("MPACT-51", "MPACT-60", "MPACT-69", "SCALE-252"). (#2614)
  • When running a depletion calculation, you are now allowed to include nuclides in the initial material compositions that do not have neutron cross sections (decay-only nuclides). (#2616)
  • The openmc.CylindricalMesh and openmc.SphericalMesh classes can now be fully formed using the constructor. (#2619)
  • A time cutoff can now be specified in the openmc.Settings.cutoff attribute. (#2631)
  • The openmc.Material.add_element method now supports a cross_sections argument that allows a cross section data source to be specified. (#2633 )
  • The openmc.Cell class now has a plot method. (#2648)
  • The openmc.Geometry class now has a plot method. (#2661)
  • When weight window checks are performed can now be explicitly specified with the openmc.Settings.weight_window_checkpoints attribute. (#2670)
  • The openmc.Settings class now has a max_write_lost_particles attribute that can limit the number of lost particle files written. (#2688)
  • The openmc.deplete.CoupledOperator class now has a diff_volume_method argument that specifies how the volume of new materials should be determined. (#2691)
  • The openmc.DAGMCUniverse.bounding_region method now has a padding_distance argument. (#2701)
  • A new openmc.Material.get_decay_photon_energy method replaces the decay_photon_energy attribute and includes an ability to eliminate low-importance points. This is facilitated by a new openmc.stats.Discrete.clip method. (#2715)
  • The openmc.model.Model.differentiate_depletable_mats method allows depletable materials to be differentiated independent of the depletion calculation itself. (#2718)
  • Albedos can now be specified on surface boundary conditions. (#2724)

Bug Fixes

  • Enable use of NCrystal materials in plot_xs (#2435)
  • Avoid segfault from extern "C" std::string (#2455)
  • Fix several issues with the Model class (#2465)
  • Provide alternative batch estimation message (#2479)
  • Correct index check for remove_tally (#2494)
  • Support for NCrystal material in from_xml_element (#2496)
  • Fix compilation with gcc 5 (#2498)
  • Fixed in the Tally::add_filter method (#2501)
  • Fix meaning of "masking" for plots (#2510)
  • Fix description of statepoint.batches in Settings class (#2514)
  • Reorder list initialization of Plot constructor (#2519)
  • Added mkdir to cwd argument in Model.run (#2523)
  • Fix export of spherical coordinates in SphericalMesh (#2538)
  • Add virtual destructor on PlottableInterface (#2541)
  • Ensure parent directory is created during depletion (#2543)
  • Fix potential out-of-bounds access in TimeFilter (#2532)
  • Remove use of sscanf for reading surface coefficients (#2574)
  • Fix torus intersection bug (#2589)
  • Multigroup per-thread cache fixes (#2591)
  • Bank surface source particles in all active cycles (#2592)
  • Fix for muir standard deviation (#2598)
  • Check for zero fission cross section (#2600)
  • XML read fixes in Plot classes (#2623)
  • Added infinity check in VolumeCalculation (#2634)
  • Fix sampling issue in Mixture distributions (#2658)
  • Prevent segfault in distance to boundary calculation (#2659)
  • Several CylindricalMesh fixes (#2676, #2680, #2684, #2710)
  • Add type checks on Intersection, Union, Complement (#2685)
  • Fixed typo in CF4Integrator docstring (#2704)
  • Ensure property setters are used in CylindricalMesh and SphericalMesh (#2709)
  • Fix sample_external_source bug (#2713)
  • Fix localization issue affecting openmc-plotter (#2723)
  • Correct openmc.lib wrapper for evaluate_legendre (#2729)
  • Bug fix in Region.from_expression during tokenization (#2733)
  • Fix bug in temperature interpolation (#2734)
  • Check for invalid domain IDs in volume calculations (#2742)
  • Skip boundary condition check for volume calculations (#2743)
  • Fix loop over coordinates for source domain rejection (#2751)

Contributors

Read more

OpenMC 0.13.3

29 Mar 19:22
27cb0dc
Compare
Choose a tag to compare

This release of OpenMC includes many bug fixes, performance improvements, and several notable new features. Some of the highlights include support for MCPL source files, NCrystal thermal scattering materials, and a new openmc.stats.MeshSpatial class that allows a source distribution to be specified over a mesh. Additionally, OpenMC now allows you to export your model as a single XML file rather than separate XML files for geometry, materials, settings, and tallies.

Compatability Notes and Deprecations

  • Atomic mass data used in openmc.data.atomic_mass has been updated to AME 2020, which results in slightly different masses.

New Features

  • Support was added for MCPL files to be used as external sources. Additionally, source points and surfaces sources can be written as MCPL files instead of HDF5 files. (#2116)
  • Support was added for NCrystal thermal scattering materials. (#2222)
  • The openmc.CylindricalMesh and openmc.SphericalMesh classes now have an origin attribute that changes the center of the mesh. (#2256)
  • A new openmc.model.Polygon class allows defining generalized 2D polygons. (#2266)
  • A new openmc.data.decay_energy function and openmc.Material.get_decay_heat method enable determination of decay heat from a single nuclide or material. (#2287)
  • Full models can now be written as a single XML file rather than separate geometry, materials, settings, and tallies XML files. (#2291)
  • Discrete distributions are now sampled using alias sampling, which is O(1) in time. (#2329)
  • The new openmc.stats.MeshSpatial allows a spatial source distribution to be specified with source strengths for each mesh element. (#2334)
  • The new openmc.Geometry.get_surfaces_by_name method returns a list of matching surfaces in a geometry. (#2347)
  • A new openmc.Settings.create_delayed_neutrons attribute controls whether delayed neutrons are created during a simulation. (#2348)
  • The openmc.deplete.Results.export_to_materials method now takes a path argument. (#2364)
  • A new openmc.EnergyFilter.get_tabular method allows one to create a tabular distribution based on tally results using an energy filter. (#2371)
  • Several methods in the openmc.Material class that require a volume to be set (e.g., openmc.Material.get_mass) now accept a volume argument. (#2412)

Bug Fixes

  • Fix for finding redundant surfaces (#2263)
  • Adds tolerance for temperatures slightly out of bounds (#2265)
  • Fix getter/setter for weight window bounds (#2275)
  • Make sure Chain.reduce preserves decay source (#2283)
  • Fix array shape for weight window bounds (#2284)
  • Fix for non-zero CDF start points in TSL data (#2290)
  • Fix a case where inelastic scattering yield is zero (#2295)
  • Prevent Compton profile out-of-bounds memory access (#2297)
  • Produce light particles from decay (#2301)
  • Fix zero runtime attributes in depletion statepoints (#2302)
  • Fix bug in openmc.Universe.get_nuclide_densities (#2310)
  • Only show print output from depletion on rank 0 (#2311)
  • Fix photon transport with no atomic relaxation data (#2312)
  • Fix for precedence in region expressions (#2318)
  • Allow source particles with energy below cutoff (#2319)
  • Fix IncidentNeutron.from_njoy for high temperatures (#2320)
  • Add capability to unset cell temperatures (#2323)
  • Fix in plot_xs when S(a,b) tables are present (#2335)
  • Various fixes for tally triggers (#2344)
  • Raise error when mesh is flat (#2363)
  • Don't call normalize inside Tabular.mean (#2375)
  • Avoid out-of-bounds access in inelastic scatter sampling (#2378)
  • Use correct direction for anisotropic fission (#2381)
  • Fix several thermal scattering nuclide assignments (#2382)
  • Fix _materials_by_id attribute in Model (#2385)
  • Updates to batch checks for simulation restarts (#2390)
  • write_data_to_vtk volume normalization correction (#2397)
  • Enable generation of JEFF 3.3 depletion chain (#2410)
  • Fix spherical to Cartesian coordinate conversion (#2417)
  • Handle zero photon cross sections in IncidentPhoton.from_ace (#2433)
  • Fix hybrid depletion when nuclides are not present (#2436)
  • Fix bug in cylindrical and spherical meshes (#2439)
  • Improvements to mesh radial boundary coincidence (#2443)

Contributors

OpenMC 0.13.2

21 Oct 17:00
030f73a
Compare
Choose a tag to compare

This release of OpenMC includes several bug fixes, performance improvements for complex geometries and depletion simulations, and other general enhancements. Notably, a capability has been added to compute the photon spectra from decay of unstable nuclides. Alongside that, a new openmc.config configuration variable has been introduced that allows easier configuration of data sources. Additionally, users can now perform cell or material rejection when sampling external source distributions.

Compatability Notes and Deprecations

  • If you are building against libMesh for unstructured mesh tally support, version 1.6 or higher is now required.
  • The openmc.stats.Muir class has been replaced by a openmc.stats.muir function that returns an instance of openmc.stats.Normal.

New Features

  • The openmc.Material.get_nuclide_atom_densities method now takes an optional nuclide argument.
  • Functions/methods in the openmc.deplete module now accept times in Julian years ('a').
  • The openmc.Universe.plot method now allows a pre-existing axes object to be passed in.
  • Performance optimization for geometries with many complex regions.
  • Performance optimization for depletion by avoiding deepcopies and caching reaction rates.
  • The openmc.RegularMesh class now has a from_domain classmethod.
  • The openmc.CylindricalMesh class now has a from_domain classmethod.
  • Improved method to condense diffusion coefficients from the openmc.mgxs module.
  • A new :data:openmc.config configuration variable has been introduced that allows data sources to be specified at runtime or via environment variables.
  • The openmc.EnergyFunctionFilter class now supports multiple interpolation schemes, not just linear-linear interpolation.
  • The openmc.DAGMCUniverse class now has material_names, n_cells, and n_surfaces attributes.
  • A new openmc.data.decay_photon_energy function has been added that returns the energy spectrum of photons emitted from the decay of an unstable nuclide.
  • The openmc.Material class also has a new decay_photon_energy attribute that gives the decay photon energy spectrum from the material based on its constituent nuclides.
  • The openmc.deplete.StepResult now has a get_material method.
  • The openmc.Source class now takes a domains argument that specifies a list of cells, materials, or universes that is used to reject source sites (i.e., if the sampled sites are not within the specified domain, they are rejected).

Bug Fixes

Contributors

OpenMC 0.13.1

19 Aug 12:10
33bc948
Compare
Choose a tag to compare

This release of OpenMC includes many bug fixes as well as improvements in geometry modeling, mesh functionality, source specification, depletion capabilities, and other general enhancements. The depletion module features a new transport operator, openmc.deplete.IndependentOperator, that allows a depletion calculation to be performed using arbitrary one-group cross sections (e.g., generated by an external solver) along with a openmc.deplete.MicroXS class for managing one-group cross sections. The track file generation capability has been significantly overhauled and a new openmc.Tracks class was introduced to allow access to information in track files from the Python API. Support has been added for new ENDF thermal scattering evaluations that use mixed coherent/incoherent elastic scattering.

Compatibility Notes and Deprecations

  • The openmc.deplete.Operator class has been renamed openmc.deplete.CoupledOperator.

  • The openmc.deplete.ResultsList class has been renamed to openmc.deplete.Results and no longer requires you to call the from_hdf5() method in order to create it; instead, you can directly instantiate it.

  • A few methods that represent k-effective have been renamed for the sake of consistency:

    • openmc.StatePoint.k_combined is now openmc.StatePoint.keff
    • openmc.deplete.ResultsList.get_eigenvalue is now openmc.deplete.Results.get_keff
  • The openmc.stats.SphericalIndependent class, which used to accept a distribution for theta now accepts a distribution for cos_theta instead in order to more easily handle the common case of specifying a uniform spatial distribution over a sphere (also see the new openmc.stats.spherical_uniform function).

  • If you are building OpenMC from source, note that several of our CMake options have been changed:

    Old option New option
    debug ---
    optimize ---
    profile OPENMC_ENABLE_PROFILE
    coverage OPENMC_ENABLE_COVERAGE
    openmp OPENMC_USE_OPENMP
    --- OPENMC_USE_MPI
    dagmc OPENMC_USE_DAGMC
    libmesh OPENMC_USE_LIBMESH

    The debug and optimize options have been removed; instead, use the standard CMAKE_BUILD_TYPE variable.

New Features

  • Two new composite surfaces: openmc.model.IsogonalOctagon and openmc.model.CylinderSector.

  • The DAGMCUniverse class now has a bounding_box attribute and a bounding_region method.

  • When translating a Region using the translate method, there is now an inplace argument.

  • The Material class has several new methods and attributes:

    • The add_components methods allows you to add multiple nuclides/elements to a material with a single call by passing a dictionary.
    • The get_activity method returns the activity of a material in Bq, Bq/g, or Bq/cm³.
    • The remove_element method removes an element from a material
    • The get_nuclide_atoms method gives the number of atoms of each nuclide in a material
  • All mesh classes now have a volumes property that provides the volume of each mesh element as well as write_data_to_vtk methods.

  • Support for externally managed MOAB meshes or libMesh meshes.

  • Multiple discrete distributions can be merged with the new openmc.stats.Discrete.merge method.

  • The openmc.stats.spherical_uniform function creates a uniform distribution over a sphere using the SphericalIndependent class.

  • Univariate distributions in the openmc.stats module now have sample() methods.

  • An openmc_sample_external_source function has been added to the C API with a corresponding Python binding openmc.lib.sample_external_source.

  • The track file generation capability has been completely overhauled. Track files now include much more information, and a new openmc.Tracks class allows access to track file information from the Python API and has a write_to_vtk method for writing a VTK file. Multiple tracks are now written to a single file (one per MPI rank).

  • A new openmc.wwinp_to_wws function that converts weight windows from a wwinp file to a list of WeightWindows objects.

  • The new openmc.EnergyFilter.from_group_structure method provides a way of creating an energy filter with a group structure identified by name.

  • The openmc.data.Decay class now has a sources property that provides radioactive decay source distributions.

  • A openmc.mgxs.ReducedAbsorptionXS class produces a multigroup cross section representing "reduced" absorption (absorption less neutron production from (n,xn) reactions).

  • Added support in the Python API and HDF5 nuclear data format for new ENDF thermal neutron scattering evaluations with mixed coherent elastic and incoherent elastic.

  • CMake now relies on find_package(MPI) for a more standard means of identifying an MPI compiler configuration.


Bug Fixes

Contributors

OpenMC 0.13.0

14 Feb 16:37
cff247e
Compare
Choose a tag to compare

This release of OpenMC includes several noteworthy and unique features. Most importantly, mesh-based weight windows have been added and work with all supported mesh types (regular, rectilinear, cylindrical, spherical, and unstructured). Other additions include torus surfaces, an ability to place CAD-based geometries in universes, a feature to export/import physical properties, and a filter for particle time.

There is one breaking changing in the Python API. The openmc.deplete.Operator class used to accept Geometry and Settings objects as its first two arguments; users now need to pass a Model class instead.

The minimum supported Python version is now 3.6.

New Features

  • Variance reduction using mesh-based weight windows is now possible with the WeightWindows class.
  • Users can now model axis-aligned tori using the XTorus, YTorus, and ZTorus classes.
  • DAGMC CAD-based geometries can now be placed in a universe using DAGMCUniverse, allowing users to combine CSG and CAD-based geometry in a single model.
  • The C/C++ API has two new functions openmc_properties_export and openmc_properties_import with corresponding Python API bindings, openmc.lib.export_properties and openmc.lib.import_properties. These functions allow physical properties (temperatures, densities, material compositions) to be written to an HDF5 file and re-used for subsequent simulations.
  • A new openmc.stats.PowerLaw univariate distribution
  • The capabilities of the Model class have been substantially expanded (e.g., the Model.deplete, Model.plot_geometry, and Model.rotate_cells methods).
  • A new TimeFilter class that allows tallies to be filtered by the particle's time, which is now tracked.
  • The Source class now allows you to specify a time distribution.
  • The new CylindricalMesh and SphericalMesh classes can be used for mesh tallies over cylidrical and spherical meshes, respectively.
  • Geometry plotting, which used to produce the files in the unusual .ppm format, now produces .png files by default.

Bug Fixes

Contributors

This release contains new contributions from the following people:

OpenMC 0.12.2

15 Jun 02:24
cbfcf90
Compare
Choose a tag to compare

This release of OpenMC is primarily a hotfix release with numerous important bug fixes. Several tally-related enhancements have also been added.

New Features

Three tally-related enhancements were added to the code in this release:

  • A new CollisionFilter class that allows tallies to be filtered by the number of collisions a particle has undergone.
  • A translation attribute has been added to MeshFilter that allows a mesh to be translated from its original position before location checks are performed.
  • The UnstructuredMesh class now supports libMesh unstructured meshes to enable better ingration with MOOSE-based applications.

Bug Fixes

Contributors

This release contains new contributions from the following people:

OpenMC 0.12.1

25 Mar 19:44
3691358
Compare
Choose a tag to compare

This release of OpenMC includes an assortment of new features and many bug fixes. The openmc.deplete module incorporates a number of improvements in usability, accuracy, and performance. Other enhancements include generalized rotational periodic boundary conditions, expanded source modeling capabilities, and a capability to generate windowed multipole library files from ENDF files.

New Features

  • Boundary conditions have been refactored and generalized. Rotational periodic boundary conditions can now be applied to any N-fold symmetric geometry.

  • External source distributions have been refactored and extended. Users writing their own C++ custom sources need to write a class that derives from openmc::Source. These changes have enabled new functionality, such as:

    • Mixing more than one custom source library together
    • Mixing a normal source with a custom source
    • Using a file-based source for fixed source simulations
    • Using a file-based source for eigenvalue simulations even when the number of particles doesn't match
  • New capability to read and write a source file based on particles that cross a surface (known as a "surface source").

  • Various improvements related to depletion:

    • Reactions used in a depletion chain can now be configured through the reactions argument to openmc.deplete.Chain.from_endf.
    • Specifying a power of zero during a depletion simulation no longer results in an unnecessary transport solve.
    • Reaction rates can be computed either directly or using multigroup flux tallies that are used to collapse reaction rates afterward. This is enabled through the reaction_rate_mode and reaction_rate_opts to openmc.deplete.Operator.
    • Depletion results can be used to create a new openmc.Materials object using the openmc.deplete.ResultsList.export_to_materials method.
  • Multigroup current and diffusion cross sections can be generated through the openmc.mgxs.Current and openmc.mgxs.DiffusionCoefficient classes.

  • Added openmc.data.isotopes function that returns a list of naturally occurring isotopes for a given element.

  • Windowed multipole libraries can now be generated directly from the Python API using openmc.data.WindowedMultipole.from_endf.

  • The new openmc.write_source_file function allows source files to be generated programmatically.

Bug fixes

Contributors

This release contains new contributions from the following people:

OpenMC 0.12.0

22 Jul 20:22
93d6165
Compare
Choose a tag to compare

This release of OpenMC includes an assortment of new features and many bug fixes. In particular, the openmc.deplete module has been heavily tested which has resulted in a number of usability improvements, bug fixes, and other enhancements. Energy deposition calculations, particularly for coupled neutron-photon simulations, have been improved as well.

Improvements in modeling capabilities continue to be added to the code, including the ability to rotate surfaces in the Python API, several new "composite" surfaces, a variety of new methods on openmc.Material, unstructured mesh tallies that leverage the existing DAGMC infrastructure, effective dose coefficients from ICRP-116, and a new cell instance tally filter.

New Features

  • All surfaces now have a rotate method that allows them to be rotated.

  • Several "composite" surfaces, which are actually composed of multiple surfaces but can be treated as a normal surface through the -/+ unary operators, have been added. These include:

    • openmc.model.RightCircularCylinder
    • openmc.model.RectangularParallelepiped
    • openmc.model.XConeOneSided (and equivalent versions for y- and z-axes)
  • Various improvements related to depletion:

    • The matrix exponential solver can now be configured through the solver argument on depletion integrator classes.
    • The openmc.deplete.Chain.reduce method can automatically reduce the number of nuclides in a depletion chain.
    • Depletion integrator classes now allow a user to specify timesteps in several units (s, min, h, d, MWd/kg).
    • openmc.deplete.ResultsList.get_atoms now allows a user to obtain depleted material compositions in atom/b-cm.
  • Several new methods on openmc.Material:

    • The add_elements_from_formula method allows a user to create a material based on a chemical formula.
    • add_element now supports the enrichment argument for non-uranium elements when only two isotopes are naturally occurring.
    • add_element now supports adding elements by name rather than by symbol.
    • The get_elements method returns a list of elements within a material.
    • The mix_materials method allows multiple materials to be mixed together based on atom, weight, or volume fractions.
  • The acceptable number of lost particles can now be configured through openmc.Settings.max_lost_particles and openmc.Settings.rel_max_lost_particles.

  • Delayed photons produced from fission are now accounted for by default by scaling the yield of prompt fission photons. This behavior can be modified through the openmc.Settings.delayed_photon_scaling attribute.

  • A trigger can now be specified for a volume calculation via the openmc.VolumeCalculation.set_trigger method.

  • The openmc.stats.SphericalIndependent and openmc.stats.CylindricalIndependent classes allow a user to specify source distributions based on spherical or cylindrical coordinates.

  • Custom external source distributions can be used via the openmc.Source.library attribute.

  • Unstructured mesh class, openmc.UnstructuredMesh, that can be used in tallies.

  • The openmc.CellInstanceFilter class allows one or more instances of a repeated cell to be tallied. This is effectively a more flexible version of the existing openmc.DistribcellFilter class.

  • The openmc.data.dose_coefficients function provides effective dose coefficients from ICRP-116 and can be used in conjunction with openmc.EnergyFunctionFilter in a tally.

Bug fixes

Contributors

This release contains new contributions from the following people:

OpenMC 0.11.0

09 Oct 00:43
7a4c5b4
Compare
Choose a tag to compare

This release of OpenMC adds several major new features: depletion, photon transport, and support for CAD geometries through DAGMC. In addition, the core codebase has been rewritten in C++14 (it was previously written in Fortran 2008). This makes compiling the code considerably simpler as no Fortran compiler is needed.

Functional expansion tallies are now supported through several new tally filters that can be arbitrarily combined:

  • openmc.LegendreFilter
  • openmc.SpatialLegendreFilter
  • openmc.SphericalHarmonicsFilter
  • openmc.ZernikeFilter
  • openmc.ZernikeRadialFilter

Note that these filters replace the use expansion scores like scatter-P1. Instead, a normal scatter score should be used along with a openmc.LegendreFilter.

The interface for random sphere packing has been significantly improved. A new openmc.model.pack_spheres function takes a region and generates a random, non-overlapping configuration of spheres within the region.

New Features

  • White boundary conditions can be applied to surfaces

  • Support for rectilinear meshes through openmc.RectilinearMesh.

  • The Geometry, Materials, and Settings classes now have a from_xml method that will build an instance from an existing XML file.

  • Predefined energy group structures can be found in openmc.mgxs.GROUP_STRUCTURES.

  • New tally scores: H1-production, H2-production, H3-production, He3-production, He4-production, heating, heating-local, and damage-energy.

  • Switched to cell-based neighor lists (PR 1140)

  • Two new probability distributions that can be used for source distributions: openmc.stats.Normal and openmc.stats.Muir

  • The openmc.data module now supports reading and sampling from ENDF File 32 resonance covariance data (PR 1024).

  • Several new convenience functions/methods have been added:

    • The openmc.model.cylinder_from_points function creates a cylinder given two points passing through its center and a radius.
    • The openmc.Plane.from_points function creates a plane given three points that pass through it.
    • The openmc.model.pin function creates a pin cell universe given a sequence of concentric cylinders and materials.

Python API Changes

  • All surface classes now have coefficient arguments given as lowercase names.
  • The order of arguments in surface classes has been changed so that coefficients are the first arguments (rather than the optional surface ID). This means you can now write::
    x = openmc.XPlane(5.0, 'reflective')
    zc = openmc.ZCylinder(0., 0., 10.)
  • The Mesh class has been renamed openmc.RegularMesh.
  • The get_rectangular_prism function has been renamed openmc.model.rectangular_prism.
  • The get_hexagonal_prism function has been renamed openmc.model.hexagonal_prism.
  • Python bindings to the C/C++ API have been move from openmc.capi to openmc.lib.

Bug fixes

Contributors

This release contains new contributions from the following people: