Skip to content
Fusion-Power-Plant-FrameworkPublic

About

Bluemira is an integrated inter-disciplinary design tool for future fusion reactors. It incorporates several modules, some of which rely on other codes, to carry out a range of typical conceptual fusion reactor design activities.

Topics

Resources

Code of conduct

Contributing

Stars

114 stars

Watchers

6 watching

Forks

Latest commit

 

History

2,171 Commits

Folders and files

Repository files navigation

DOI docs codecov

Bluemira

image

Bluemira is an integrated inter-disciplinary design tool for future fusion reactors. It incorporates several modules, some of which rely on other codes, to carry out a range of typical conceptual fusion reactor design activities.

Bluemira was created from two similar codes: BLUEPRINT and MIRA (see publications).

Indepth Examples

We have created some indepth examples using bluemira.

  • EU-DEMO - This is a parameterised version of a EU-DEMO like device (single null, conventional aspect ratio)
  • Spherical Tokamak - This is a parameterised version of a double null, spherical tokamak based on OpenSTEP data

Development and Timeline

The bluemira team has been working hard since mid-2021 to combine BLUEPRINT and MIRA into a single reactor design framework. We took the opportunity to embark upon a significant refactor of both code bases, delivering improved functionality, code quality, and hopefully maintainability.

In addition, we have created templates and examples;

and separate packages that others may find useful;

  • eqdsk: g-eqdsk reading and writing with identification and conversion between COCOS versions
  • matproplib: A Materials Property library
  • tokamak-neutron-source: A tool to create an arbitrary parametric tokamak neutron source
  • fast_ctd: a Python package for fast conversion of STEP files to DAGMC models

Below is an overview of our development roadmap for 2026/27:

Bluemira Roadmap

Modules

Bluemira is composed of various modules:

  • balance_of_plant: power balance solver and tools
  • base: the software backbone of the bluemira framework
  • codes: interfaces to external codes (both API and file PI)
  • display: plotting and display module
  • equilibria: equilibrium solvers and objects
  • fuel_cycle: fuel cycle model
  • geometry: the geometry "engine" of the bluemira framework
  • magnetostatics: magnetostatics solvers
  • materials: materials module
  • optimisation: interface to optimisers and associated tools
  • plasma_physics: 0-D plasma physics tools
  • radiation_transport [WIP]: radiation and advection transport solvers
  • structural: beam finite element structural solver
  • utilities: collection of utility toolboxes for file IO, databases, machine learning, and misc.

Publications

The bluemira code and its modules are described in the following publications:

As bluemira is the result of an integration between two historical codes, some previous publications may also be of interest.

The BLUEPRINT code and its modules are described in the following publications:

The MIRA code and its modules are described in the following publications:

Terms of use

Bluemira is released under the LGPLv2.1 license, but we also ask that you show professional courtesy when using this code:

  1. Since you are benefiting from work on bluemira, we ask that you submit any improvements you make to the code to us by submitting a pull request to this repository. If you are looking to develop aspects of this code or add parts to it, please contact us beforehand so that we can help/advise if necessary.

  2. If you use bluemira results in a paper or professional publication, we ask that you discuss your work and results with one of the bluemira authors first so that we can check them. It is not necessary to list bluemira developers as co-authors. If one or more of the bluemira team are involved in preparing results or new functionality used in your work, then those members should be offered a co-authorship.

  3. If you use bluemira or any of its modules in your work, please help ensure that all the authors get the credit they deserve by citing the relevant bluemira, BLUEPRINT, and MIRA papers.

For a full list of existing publications, see here.

Code of conduct

See code of conduct.

Installation

See our installation guide.

Developing

For working on bluemira you will also need to install the development dependencies and the git pre-commit hook:

python -m pip install --no-cache-dir  -e .'[dev]'
pre-commit install -f

Please see the guidelines for contributing to bluemira.

Tests are run with pytest. To run the main tests:

pytest

To run all the tests:

pytest --reactor --longrun --plotting-on

pytest also supports running individual test files and selecting tests by name or using a regular expression. See the pytest documentation.

After a test run an html report of the results can be found in report.html. A test coverage report can be found in the htmlcov directory.

Further information about our testing can be found here.

Building Documentation

The documentation is built with Sphinx. In addition the API documentation is created by sphinx-apidoc.

To build the html documentation execute this command:

sphinx-build documentation/source documentation/build

New pages can be added by adding them to the documentation/source directory and adding a link in the toctree section of index.rst. The index page lives at documentation/build/index.html. API documentation will be automatically generated from the bluemira source code.

About

Bluemira is an integrated inter-disciplinary design tool for future fusion reactors. It incorporates several modules, some of which rely on other codes, to carry out a range of typical conceptual fusion reactor design activities.

Topics

Resources

Code of conduct

Contributing

Stars

114 stars

Watchers

6 watching

Forks

Releases

Packages

Used by

Contributors

Languages