Metadata-Version: 2.5
Name: yani
Version: 0.6.0
Summary: Yet Another Nuclide Inventory: transmutation and activation calculations
Project-URL: Homepage, https://github.com/fusion-neutronics/yani
Project-URL: Documentation, https://fusion-neutronics.github.io/yani/
Project-URL: Repository, https://github.com/fusion-neutronics/yani
Project-URL: Issues, https://github.com/fusion-neutronics/yani/issues
License-Expression: MIT
License-File: LICENSE
Keywords: activation,fusion,inventory,neutronics,nuclear,transmutation
Classifier: License :: OSI Approved :: MIT License
Classifier: Operating System :: OS Independent
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Rust
Classifier: Topic :: Scientific/Engineering :: Physics
Requires-Python: >=3.10
Requires-Dist: yani-core==0.6.0
Description-Content-Type: text/markdown

# YANI

**Y**et **A**nother **N**uclide **I**nventory. A material, an irradiation
schedule and a neutron spectrum in; inventories, activities, decay heat and
decay photon spectra out.

[Documentation](https://fusion-neutronics.github.io/yani/) |
[PyPI](https://pypi.org/project/yani/)

```bash
pip install yani
```

```python
import yani

yani.cross_section_data = "tendl-2025"
yani.transmutation_reactions = "tendl-2025"
yani.transmutation_branch_ratios = "tendl-2025"
yani.transmutation_decay_data = "endf-b8.1"      # TENDL has no decay data
yani.transmutation_fission_yields = "endf-b8.1"  # nor fission yields

steel = yani.materials.pnnl.material("Steel, Stainless 316", volume=1000.0)
spectrum = yani.NeutronSource(
    energy=yani.sources.Histogram([1e-5, 1e5, 1e6, 1.5e7], [1e12, 1e13, 1e14])
)
schedule = yani.PulseSchedule([
    yani.Pulse(rate=1.11e14, duration=(1, "a"), source=spectrum),
    yani.Cooldown(duration=(1, "d")),
])

final = steel.transmute(schedule=schedule)[-1]
print(final.activity(), "Bq")
print(final.decay_heat(), "W")
print(final.contact_dose(), "Gy/h")
```

## What it solves

The nuclide inventory under irradiation is the Bateman equations with reaction
terms, `dN/dt = A N`, solved as a matrix exponential `N(t) = exp(A t) N(0)` by
CRAM at order 48. The solver is Rust; the wheel needs no compiler and no
external toolchain.

## What this repository contains

Documentation, packaging and release automation. The code lives in the
`yani-core` wheel this package depends on, which provides the `yani` module
itself, its type stubs and its docstrings. `pip install yani` pulls it in.

That arrangement is why there is no Python here: one source of truth for the
API, and no re-export layer that can drift from it.

