Docs

This module simulates an LBO injection with full Aurora transport. It follows
every charge state as the impurity enters, ionizes and leaves, without
assuming coronal equilibrium, and fits the transport coefficients to the
measured core-line curve (W44, Fe23, Ni25). It is used in
notebooks/10W3-10W4/10W4b_entregable.ipynb.

from aug.analysis.atomic import load_adf11_subset
from aug.analysis.aurora_lbo import fit_injection
from aug.io import read_lbo_profiles

atom = load_adf11_subset("cache/w_adf11_subset.txt")            # o feni_..., element="Fe"
p = read_lbo_profiles(shot.lbo_paths[0])
rho = p["Te"].rho.to_numpy()
prof = dict(rho=rho, ne=np.interp(rho, p["ne"].rho, p["ne"].value), Te=p["Te"].value.to_numpy())

f = fit_injection("W", res.details[(shot.shot, 1)], prof, atom)                    # estático
f2 = fit_injection("W", res.details[(shot.shot, 1)], prof, atom, mode="switch")    # D_ped cambia en el tiempo
f["params"], f["chi2"], f["metrics"]

Model

What How
Geometry No magnetic equilibrium (we have no geqdsk). Uses ρ_pol ≈ r_vol/r_vol,LCFS with r_vol,LCFS = 64 cm (AUG: V ≈ 13.5 m³) and R = 165 cm
Profiles IDA ne and Te from the -lbo file, constant in time
Atomic data ADF11 scd/acd (see atomic.md)
Source Aurora's synth_LBO: 1 ms rise and a t_src fall (fitted), 1 cm outside the LCFS
Transport D = D_core (ρ < 0.9), D_ped (0.9 to 1), 1 m²/s in the SOL; v = v_core·ρ/0.9 (core), v_ped (pedestal), 0 in the SOL
Signal Σ_ n_e n_q Δr: central chord, no PEC
Fit least_squares on the normalized curve (y − base)/A, with a free (linear) amplitude and a free time shift

Both modes fit six parameters: D_core, D_ped, v_core, v_ped, t_src and the
time shift. Switch mode adds two more, because D_ped changes to D_ped2 at
t_switch.

Each simulation takes ~1 s, and a fit takes ~2 min in static mode or ~5 min in
switch mode. Each aurora_sim stores ~200 MB of rates, so the fit keeps at
most 2 in memory.

Limitations

Technical details