https://github.com/arfc/openmcyclus

Repository of Cyclus archetypes to couple Cyclus with OpenMc

https://github.com/arfc/openmcyclus

Science Score: 13.0%

This score indicates how likely this project is to be science-related based on various indicators:

  • CITATION.cff file
  • codemeta.json file
    Found codemeta.json file
  • .zenodo.json file
  • DOI references
  • Academic publication links
  • Academic email domains
  • Institutional organization owner
  • JOSS paper metadata
  • Scientific vocabulary similarity
    Low similarity (12.3%) to scientific vocabulary
Last synced: 9 months ago · JSON representation

Repository

Repository of Cyclus archetypes to couple Cyclus with OpenMc

Basic Info
  • Host: GitHub
  • Owner: arfc
  • License: bsd-3-clause
  • Language: Jupyter Notebook
  • Default Branch: main
  • Size: 26.3 MB
Statistics
  • Stars: 3
  • Watchers: 1
  • Forks: 4
  • Open Issues: 5
  • Releases: 1
Created over 3 years ago · Last pushed almost 2 years ago
Metadata Files
Readme Changelog Contributing License

README.rst

OpenMCyclus
------------
.. image:: https://github.com/arfc/openmcyclus/actions/workflows/test-openmcyclus.yml/badge.svg?branch=main

Library of Cyclus archetypes to couple Cyclus with OpenMC.

Installation 
============

Dependencies
~~~~~~~~~~~~

You will need to have `Cyclus `_, `OpenMC `_, 
and their required dependencies. Both are available via conda binaries or can 
be installed from source via their github repositories. Please note 
the versions listed below, as these are *required versions, not minimum versions*. 

+---------------+----------+
| Dependency    | Version  |
+===============+==========+
| Cyclus        | 1.6      |
+---------------+----------+
| OpenMC        | 0.14     |
+---------------+----------+
| SciPy         | 1.11     |
+---------------+----------+

Directions to install Cyclus and OpenMC [1]_ 
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

It is advised to create a new conda environment for installing all of the dependencies. 

.. code-block:: bash
  
    ~ $ conda install -y mamba

    ~ $ mamba install -y cyclus openmc=0.14.0 scipy=1.11

    ~ $ git clone https://github.com/cyclus/cyclus.git

    ~ $ cd cyclus

    ~/cyclus $ python install.py

If desired, Cycamore can be installed from `source `_ 
or from Conda/Mamba. Cycamore is *highly* recommended, as it contains other archetypes for creating a 
fuel cycle model in Cyclus, but it is not a dependency for OpenMCyclus. 

Install OpenMCyclus
~~~~~~~~~~~~~~~~~~~

To install OpenMCyclus:

.. code-block:: bash

    ~ $ git clone https://github.com/arfc/openmcyclus.git 

    ~ $ cd openmcyclus

    ~/openmcyclus/ $ pip install .


To run the tests:

.. code-block:: bash

    ~/openmcyclus $ pytest tests/


Running
=======

This archetype assumes that you have a defined material file for OpenMC (``.xml``), 
a flux value for the fuel assemblies, and the required microscopic cross sections 
(``.csv`` file) for the model. 
The cross section data must be saved as a ``.csv`` file. These files must 
all be in the same location. Information about these can be found on the 
`OpenMC docpages `_. 

This archetype is then called during a Cyclus simulation by calling 
the ``DepleteReactor`` archetype from the ``openmcyclus.DepleteReactor`` 
library. The input structure is:

.. code-block:: xml

   
          
            string
            string
          
          
            double
            double
          
          
            string
            string
          
          
            string 
            string
          
          
            string 
            string
          
          double
          int
          int
          int
          int
          double
          string
          string
          double
          double
        

Some notes about this input structure:

- ``fuel_prefs`` and ``fuel_inrecipes`` must be equal in length to 
  ``fuel_incommods`` and ``fuel_outrecipes`` must be equal in length to ``fuel_outcommods``. 

- The ``model_path`` variable is the location of the files for OpenMC (can be 
  relative or absolute path): one-group cross sections, materials, and depletion 
  chain file. If using a relative path, it must be relative to the directory you are 
  running the Cyclus input file from, not the location of the file that defines the 
  prototype. 

- The archetype assumes that 
  the OpenMC materials are in the file called ``materials.xml`` and that the cross 
  section data is in a file called ``micro_xs.csv``. 

- The ``chain_file`` variable 
  is the depletion chain file, and the user provides the name of this file. 

- Each material in the ``materials.xml`` file that are fuel materials must 
  be marked as ``depletable`` and have the name ``assembly_#``. Define one material 
  for each assembly in the reactor core (matches with ``n_assem_core``),  
  the number assigned to each material name is irrelevant, just as long as  
  there is one. 

Outputs
~~~~~~~
The results of the simulation will be written to `cyclus.sqlite`
or the file name provided when Cyclus was called. 

.. [1] More installation options and instructions for installing OpenMC
  can be found at https://docs.openmc.org/en/stable/quickinstall.html
  

Owner

  • Name: Advanced Reactors and Fuel Cycles
  • Login: arfc
  • Kind: organization
  • Email: arfc@groups.google.com
  • Location: University of Illinois at Urbana-Champaign

A research group focused on modeling and simulation of advanced nuclear reactors and fuel cycles.

GitHub Events

Total
  • Issues event: 3
  • Watch event: 1
  • Issue comment event: 2
  • Pull request event: 1
  • Fork event: 1
Last Year
  • Issues event: 3
  • Watch event: 1
  • Issue comment event: 2
  • Pull request event: 1
  • Fork event: 1

Dependencies

.github/workflows/test-openmcyclus.yml actions
  • actions/checkout v3 composite
  • conda-incubator/setup-miniconda v2 composite
requirements.txt pypi
  • numpy *
  • pytest *
.github/workflows/unit-test.yml actions
  • actions/checkout v3 composite
  • conda-incubator/setup-miniconda v2 composite
Dockerfile docker
  • cyclus/cycamore latest build
environment.yml pypi
setup.py pypi