Skip to main content

Module table

Module table 

Source
Expand description

User-supplied S_e(E) tables, loaded from TOML, with mandatory provenance.

provenance = "Author, Journal vol, page (year), Table N"   # required
ion_z = 14
ion_mass_amu = 28.0855            # optional; default: standard weight
target_z = 14
energy_ev = [1.0e3, 1.0e4, 1.0e5]
stopping_ev_1e15_cm2 = [10.0, 30.0, 60.0]   # eV 1e-15 cm^2 per atom

A table without a non-empty provenance is rejected at load time (see docs/data-provenance.md: data without an origin is not admitted). Do not load SRIM- or ICRU-derived tables for anything committed to the repository.

The table is tied to the projectile mass it was declared for (the standard atomic weight when ion_mass_amu is omitted): a query for an ion whose mass differs by more than MASS_RELATIVE_TOLERANCE is an error (StoppingError::TableMassMismatch), because the same energy at a different mass is a different ion speed. No energy-axis conversion is attempted.

Interpolation is piecewise linear in ln S versus ln E, which preserves the monotonicity of each segment of the data. Out of range queries are an error (StoppingError::OutOfTableRange); nothing is extrapolated or clamped silently.

Structs§

StoppingTable
A validated user stopping table for one ion/target pair.
TableOverride
User tables layered over a base model: a query for a pair some table declares goes to that table (so its range and mass checks apply, and it is never silently replaced by the base model); every other pair goes to the base model.

Constants§

MASS_RELATIVE_TOLERANCE
Relative tolerance when comparing a table’s declared projectile mass with the queried ion’s mass. Tight enough to separate neighbouring isotopes, loose enough to absorb rounding in a quoted mass.