Skip to content

Differentiable rotational transform from coil fields (weighted Birkhoff + SOLVAX axis) - #99

Open
gftd13 wants to merge 11 commits into
mainfrom
feat/rotational-transform-from-coils
Open

gftd13 wants to merge 11 commits into
mainfrom
feat/rotational-transform-from-coils

Conversation

@gftd13

@gftd13 gftd13 commented Sep 30, 2026 •

Copy link
Copy Markdown

Compute rotational transform directly from the coil field. Tests check the axis fixed point, angular convergence and coil derivatives against central differences.

The three rotational-transform tests check the axis fixed point to 1e-10, the VMEC transform range, convergence with resolution and derivatives with respect to all coil degrees of freedom to relative tolerance 1e-4.

convergence

Trace field lines in phi with fixed-step RK4 alongside the magnetic axis and
take a weighted Birkhoff average of the poloidal advance per field period.
The axis is the fixed point of the field-period map, solved with Newton
inside solvax.root_solve for implicit gradients. Includes tests (axis, VMEC
agreement, gradient vs finite differences) and a convergence example.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@codecov

codecov Bot commented Sep 30, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.

Files with missing lines Coverage Δ
essos/rotational_transform.py 100.00% <100.00%> (ø)

... and 1 file with indirect coverage changes

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants