Skip to main content

Crate nucleide_material

Crate nucleide_material 

Source
Expand description

Materials: compositions, mixing, and serialization for nuclear engineering.

A Material is a map from NuclideId to a stored mass in grams, plus an optional mass density (g/cm3 by convention) and free-form JSON metadata. Density lives outside the composition: it is a property of the stream rather than part of the composition itself.

Atomic-mass-dependent conversions (Material::from_atom_frac and Material::atom_fractions) take a MassProvider so the material crate stays independent of the nuclear-data tables; wire up nucleide_nuclei::data once it lands.

use nucleide_material::{MassProvider, Material, NoMasses};
use nucleide_nuclei::NuclideId;

let mut mat = Material::new();
mat.add_nuclide(NuclideId::from_name("U235").unwrap(), 19.0);
mat.add_nuclide(NuclideId::from_name("U238").unwrap(), 1.0);
assert_eq!(mat.mass(), 20.0);

// Atom conversions need atomic masses:
let atoms = mat.atom_fractions(&NoMasses);
assert!(atoms.is_err());

Structs§

Ame2020
MassProvider backed by the AME2020 tables in nucleide_nuclei::data.
Analytics
Provider bundle for radioanalytic quantities.
AuditIssue
One conservation problem found by audit.
ChainDecays
DecayProvider backed by the ENDF/B-VIII.0 half-life table in nucleide_nuclei::data.
Collision
One truncated label form claimed by more than one nuclide.
CompendiumElement
One elemental constituent.
CompendiumEntry
One compendium material entry.
CompendiumIsotope
One isotope row of an element inside a compendium material.
Cusum
One-sided upper Page CUSUM detector with Welford running statistics.
DecayEnergies
DecayEnergyProvider backed by the ENDF/B-VII.1 prompt-decay-energy table in nucleide_nuclei::data (mean-field evaluation values, generated by scripts/gen-nuclear-data.py — see the table docs before quoting heat numbers).
DoseFactors
DoseProvider backed by the HNF-5636/PyNE dose-factor table in nucleide_nuclei::data (generated by scripts/gen-nuclear-data.py — see the table docs; screening-level only, not for safety decisions).
Material
A nuclear material: nuclide masses plus optional density and metadata.
MaterialsDoc
A <materials> document bundling named Materials, optionally pointing at a cross-sections file via the root cross_sections attribute — the container shape of a materials collection document.
MaterialsLibrary
The full parsed compendium with fast lookups.
NaturalAbundances
AbundanceProvider backed by the natural-abundance table in nucleide_nuclei::data.
NoAbundances
An AbundanceProvider that knows no isotopes.
NoDecay
A DecayProvider that knows no decays.
NoDecayEnergies
A DecayEnergyProvider that knows no decay energies.
NoDoses
A DoseProvider that knows no dose factors.
NoMasses
A MassProvider that knows no masses.

Enums§

AnalyticsError
Errors from radioanalytics beyond the shared crate::Error set.
AuditKind
The class of a conservation problem found by audit.
CompendiumError
Errors from compendium loading.
DosePathway
Dose pathway and source types (re-exported from nucleide-nuclei so analytics call sites need one import). Dose pathway: external air/soil, ingestion, or inhalation.
DoseSource
Dose pathway and source types (re-exported from nucleide-nuclei so analytics call sites need one import). Dose-factor evaluation source: the three parallel HNF-5636 evaluations.
Error
Errors produced by material construction, conversion, and export.
FormulaError
Errors from formula parsing and element expansion.

Constants§

AVOGADRO
Avogadro constant, atoms per mole (exact, 2019 SI).
CI_PER_BQ
Curies per becquerel (PyNE Ci_per_Bq, src/data.cpp).
DEFAULT_WIDTHS
Default truncation widths probed by check_labels: 6 (DIF3D label limit) and 8 (MC2-3 label limit).
GRAMS_PER_U
One unified atomic mass unit in grams (2022 CODATA).
MEV_TO_JOULES
One MeV in joules (exact, 2019 SI: 1 eV = 1.602176634e-19 J).
PCI_PER_BQ
Picocuries per becquerel (PyNE pCi_per_Bq, Material::dose_per_g).

Traits§

AbundanceProvider
Source of natural-isotope composition data, element by element.
DecayEnergyProvider
Source of per-nuclide mean recoverable decay energies in MeV per decay.
DecayProvider
Source of per-nuclide decay constants λ in inverse seconds.
DoseProvider
Source of per-nuclide dose factors (raw table values).
MassProvider
Source of per-nuclide atomic masses in g/mol.

Functions§

audit
Validate mass-fraction normalization, mass signs, key uniqueness, and atomic-mass availability.
check_labels
Truncate every member’s cross-code labels to each of widths and report every truncated form claimed by more than one nuclide.
parse_formula
Parse a chemical formula into per-element atom counts.

Type Aliases§

FormulaResult
Result alias for formula parsing and expansion.
Result
Result alias for the material crate.