Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Improve the High-Level Introduction to ARMI in the Docs #1666

Open
john-science opened this issue Mar 18, 2024 · 1 comment
Open

Improve the High-Level Introduction to ARMI in the Docs #1666

john-science opened this issue Mar 18, 2024 · 1 comment
Assignees
Labels
documentation Improvements or additions to documentation enhancement New feature or request

Comments

@john-science
Copy link
Member

john-science commented Mar 18, 2024

Right now, ARMI technically has a high-level introduction in two places:

  • REAME.rst - Covers everything from installation to core concepts
  • doc/developer/guide.rst - It feels strange that this is in "developer docs" and not "user docs".

I also note that there are installation instructions in two places:

I don't love that. But I DO love that we are including our README file as the introduction to our docs:

.. include:: ../README.rst

Also, I don't super love the order of our docs:

armi/doc/index.rst

Lines 11 to 15 in b9f1f13

installation
gallery/index
tutorials/index
user/index
developer/index

@john-science john-science added documentation Improvements or additions to documentation enhancement New feature or request labels Mar 18, 2024
@john-science john-science self-assigned this Mar 18, 2024
@john-science
Copy link
Member Author

john-science commented Mar 18, 2024

Implementation of Plugin System

The first important design idea to understand is ARMI it is a framework for nuclear reactor modeling. What this means, is that none of the science or engineering calculations for nuclear reactor modeling actually happen in ARMI. The point of ARMI is to tie together disparate nuclear modeling softwares that already exist. Thus, ARMI must be able to wrap external codes, and orchestrate running them at each time step we want to model.

The second design idea is that at each time step, there is an ordered list of conceptual reactor modeling steps to be executed. ARMI calls these steps :py:class:Interfaces <armi.interfaces.Interface> and runs the code, in order, at each time step. While ARMI does have a default list of modeling steps, and a default order, none of the steps are mandatory, and their order is modifiable. An example interface stack would be:

  • preprocessing
  • fuel management
  • depletion
  • fuel performance
  • cross sections
  • critical control
  • flux
  • thermal hydraulics
  • reactivity coefficients
  • transient
  • bookkeeping
  • postprocessing

So, how do we add Interfaces to the simulation? The third major design idea is that developers can create an ARMI :py:class:Plugin <armi.plugins.ArmiPlugin>, which can add one or more Interfaces to the simulation.

Lastly, at the highest level of the design, a developer can create an ARMI :py:class:Application <armi.apps.App>. This is a flexible container that allows developers to register multiple Plugins, which register multiple Interfaces, which fully define all the code that will be run at each time step of the simulation.

Below is a diagram from an example ARMI Application. Following this design, in the real world you would expect an ARMI Application to be made by various teams of scientists and engineers that define one Plugin and a small number of Interfaces. Then a simulation of the reactor would be carried out over some number of cycles / time nodes, where each of the Interfaces would be run in a specified order at each time node.

armi_application_structure

Figure: An example ARMI Application.

If this high-level design seems abstract, that is by design. ARMI is not concerned with implementing scientific codes, or enforcing nuclear modelers do things a certain way. ARMI is a tool that aims to support a wide audience of nuclear reactor modelers.

Implementation of Reactor Data Model

In the previous section, we described how an ARMI Application is put together. But that Application is only useful if it can pass information about the reactor between all the external codes that are being wrapped by each Interface. Thus, an important part of the ARMI design is that is has a robust and detailed software data model to represent the current state of the reactor. This data model can be queried and manipulated by each Interface to get data that is needed to run the external reactor modeling codes.

The structure of the ARMI reactor data model is designed to be quite flexible, and heavily modifiable in code. But for the purposes of Natrium, this document will focus on pin-type reactor cores.

At the largest scale, the :py:class:Reactor <armi.reactor.reactors.Reactor> contains a :py:class:Core <armi.reactor.reactors.Core> and a :py:class:Spent Fuel Pool <armi.reactor.assemblyLists.SpentFuelPool>. The Core is made primarily of a collection of :py:class:Assemblies <armi.reactor.assemblies.Assembly>, which are vertical collections of :py:class:Blocks <armi.reactor.blocks.Block>. Each Block, and every other physical piece of the Reactor is a :py:class:Composite <armi.reactor.composites.Composite>. Composites have a defined shape, material(s), location in space, and parent. Composites have parents because ARMI defines all Reactors as a hierarchical model, where outer objects contain inner children and the Reactor is the outermost object. The important thing about this model is that it is in code, so developers of ARMI Interfaces can query and modify the reactor data model in any way they need.

armi_reactor_objects

Figure: Structure of the ARMI reactor data model.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
documentation Improvements or additions to documentation enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant