Fix field_eq flux gauge and translated wall stretching - #403
Merged
Conversation
krystophny
commented
Jul 26, 2026
krystophny
left a comment
Member
Author
There was a problem hiding this comment.
Reviewed latest b5272f4d after merging current main. The shifted G cm^2/rad flux gauge is consistent at axis and LCFS, while wall stretching now derives both R and Z centers and is translation invariant. These are behavioral endpoint/translation oracles and do not infer COCOS or flip field components. Native suite: 95/95 passed. No blocking finding.
krystophny
marked this pull request as ready for review
July 26, 2026 17:46
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
field_eqpoloidal-flux state to one shifted gauge and one cgs unitRoot causes
field_eqconverted and shiftedpsifandpsi_septo G cm²/rad while leavingpsi_axisin the GEQDSK input unit and absolute gauge. Downstream normalized-flux expressions then subtracted incompatible quantities.Separately,
stretch_coordsinferred a radial wall center but hard-coded the vertical center toZ=0in its polar map. A vertically displaced equilibrium could therefore map interior points outside and change under a rigid Cartesian translation.Changes
psi_axis=0,psif=(PSIRZ-SIMAG)*1e8, andpsi_sep=(SIBRY-SIMAG)*1e8R0andZ0from the convex wall and consistently use local(R-R0,Z-Z0)coordinatesValidation
Z=0implementation and passes after the fixRelationships
Fixes #401.
Fixes #402.
This is a stacked dependency of itpplasma/NEO-RT#80. It changes flux metadata/state and translated-wall geometry; it does not infer COCOS, flip a field component, or fit a cross-code sign, phase, gain, or radius.