Skip to main content

fibe

FIxed Boundary Equilibrium (FIBE) solver for tokamak plasma geometries in pure Python

Installation

This package is available on PyPI, so installation can simply be done with:

pip install fibe

However, if you wish to make modifications to the source code or use alpha versions, it is possible to install via:

git clone <this_repo>
pip install [--user] -e fibe

Quick setup

Using the following lines in your script should allow for quick setup (parameters in <> are user-defined):

from fibe import FixedBoundaryEquilibrium
eq = FixedBoundaryEquilibrium()
eq.define_grid_and_boundary_with_mxh(
    nr=129,
    nz=129,
    rgeo=<R0_m>,
    zgeo=<Z0_m>,
    rminor=<Rmin_m>,
    kappa=<kappa>,
    cos_coeffs=[0.0, 0.0, 0.0],
    sin_coeffs=[0.0, np.arcsin(<delta>), -<zeta>],
)
eq.initialize_profiles_with_minimal_input(<P0_Pa>, <Ip_A>, <Bt_T>)
eq.initialize_psi()
eq.solve_psi()

To view the solution in script:

eq.plot_contour()
eq.plot_profiles()

To save the output in GEQDSK format:

eq.to_geqdsk(<geqdsk_filename>)

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

fibe-0.4.1.tar.gz (176.7 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

fibe-0.4.1-py3-none-any.whl (75.1 kB view details)

Uploaded Python 3

File details

Details for the file fibe-0.4.1.tar.gz.

File metadata

  • Download URL: fibe-0.4.1.tar.gz
  • Upload date:
  • Size: 176.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.12.13

File hashes

Hashes for fibe-0.4.1.tar.gz
Algorithm Hash digest
SHA256 3c22ade03efb0db2f425ffa8d240800c12c8251a99cf71ca8954860eefb7ae93
MD5 21b5a7235eea0be1a7d2b42c6e1dd43d
BLAKE2b-256 3559be6c3710c547e50a7538125f1c7bfed3ad7107d31fe3a5f6c4d7fee5d66f

See more details on using hashes here.

File details

Details for the file fibe-0.4.1-py3-none-any.whl.

File metadata

  • Download URL: fibe-0.4.1-py3-none-any.whl
  • Upload date:
  • Size: 75.1 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.12.13

File hashes

Hashes for fibe-0.4.1-py3-none-any.whl
Algorithm Hash digest
SHA256 90ccd628370f0dc531f2001c32e3ad9995d581e2f262db1e53e16256da6232da
MD5 bf09174ef9fa9ea7fac5c95eacbf9e34
BLAKE2b-256 5bbfb99a7f8d90bc18a5a7c6f6771e4f2fe8f6139164fea12e7f4a0148a1f2c5

See more details on using hashes here.

Release history Release notifications | RSS feed

0.4.2

2 files

This release

0.4.1 This release

2 files

0.4.0

2 files

0.3.2

2 files

0.3.1

2 files

0.3.0

2 files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page