Bumping FastInterpolations from v0.4.15 to v0.4.17 — with no other change — moves the resonant area-weighted field b_res by ~25% and flips the sign of the perturbed-equilibrium toroidal torque.
This is very likely an error in FastInterpolations.
Reproduction
Single-variable test: Pkg.add(name="FastInterpolations", version="0.4.15") against an otherwise-current environment (DiffEqCallbacks 4.19.0, DoubleFloats 1.11.2, LinearAlgebra/SparseArrays 1.12.0, Julia 1.12.6). Case is examples/DIIID-like_ideal_example, n=1, run through the regression harness against the same GPEC commit on both sides.
Fixed grid (grid_type = "ldp", mpsi = 256)
| quantity |
0.4.17 |
0.4.15 |
diff |
resonant area-weighted field b^r |
[5 elem] |
[5 elem] |
24.62% |
||resonant area-weighted field|| |
4.382144e-04 |
3.918227e-04 |
10.59% |
Chirikov parameter |
[5 elem] |
[5 elem] |
8.81% |
island half-widths |
[5 elem] |
[5 elem] |
3.94% |
ODE steps (saved) |
1481 |
1466 |
1.01% |
PE toroidal torque |
-5.060621e-02 |
-5.060621e-02 |
1.3e-11 |
The equilibrium is untouched here: q profile and pressure profile checksums are identical, and plasma volume, li1/2/3, beta_t, beta_n agree to 1e-15..1e-16. Only quantities downstream of the ODE integration move.
Auto grid (grid_type = "auto", mpsi = 0)
| quantity |
0.4.17 |
0.4.15 |
diff |
PE toroidal torque |
-5.034315e-02 |
+5.057643e-02 |
sign flip |
q profile (checksum) |
0fead70cb422… |
71b97936ef0b… |
different |
pressure profile (checksum) |
d553d38a470b… |
958ae8fd02b7… |
different |
resonant area-weighted field b^r |
[5 elem] |
[5 elem] |
4.45% |
ODE steps (total) |
2002 |
1933 |
3.45% |
On the auto grid the two-pass measured-curvature knot placement itself changes, so the q and pressure profiles differ — the same equilibrium sampled on a different grid (plasma volume still agrees to 4e-11, singular ψ locations to 2e-14).
Notes
- Both effects are reproduced by pinning FastInterpolations alone; DiffEqCallbacks, DoubleFloats and the stdlib versions were held fixed and are not implicated.
delta prime from the Riccati BVP path (asymptotic Frobenius basis) is unaffected (~1e-8 relative). The affected quantities — b^r, Chirikov, island half-widths — are all scalar multiples of the same resonant-surface jump computed in SingularCoupling.jl, which obtains ξ′ from a chord slope across saved ODE nodes. A shift in node placement therefore propagates into all of them.
- Numbers above are from the regression harness; the auto-grid and ldp runs used the same GPEC commit on both sides, so the only difference is the package version.
Bumping FastInterpolations from v0.4.15 to v0.4.17 — with no other change — moves the resonant area-weighted field
b_resby ~25% and flips the sign of the perturbed-equilibrium toroidal torque.This is very likely an error in FastInterpolations.
Reproduction
Single-variable test:
Pkg.add(name="FastInterpolations", version="0.4.15")against an otherwise-current environment (DiffEqCallbacks 4.19.0, DoubleFloats 1.11.2, LinearAlgebra/SparseArrays 1.12.0, Julia 1.12.6). Case isexamples/DIIID-like_ideal_example, n=1, run through the regression harness against the same GPEC commit on both sides.Fixed grid (
grid_type = "ldp",mpsi = 256)resonant area-weighted field b^r||resonant area-weighted field||Chirikov parameterisland half-widthsODE steps (saved)PE toroidal torqueThe equilibrium is untouched here:
q profileandpressure profilechecksums are identical, andplasma volume,li1/2/3,beta_t,beta_nagree to 1e-15..1e-16. Only quantities downstream of the ODE integration move.Auto grid (
grid_type = "auto",mpsi = 0)PE toroidal torqueq profile (checksum)pressure profile (checksum)resonant area-weighted field b^rODE steps (total)On the auto grid the two-pass measured-curvature knot placement itself changes, so the q and pressure profiles differ — the same equilibrium sampled on a different grid (
plasma volumestill agrees to 4e-11, singular ψ locations to 2e-14).Notes
delta primefrom the Riccati BVP path (asymptotic Frobenius basis) is unaffected (~1e-8 relative). The affected quantities —b^r,Chirikov,island half-widths— are all scalar multiples of the same resonant-surface jump computed inSingularCoupling.jl, which obtains ξ′ from a chord slope across saved ODE nodes. A shift in node placement therefore propagates into all of them.