Repository navigation
STRIDE - BUGFIX - Split the axis interval into at least 8 pieces - #325
Merged
Merged
Conversation
ode_set_intervals spreads the spare intervals by estimated compute time, which rates the interval from the axis to the first singular surface as cheap: at the default nIntervalsTot = 33 it often stays whole (always when nIntervalsTot is forced up to its minimum), and then the innermost Delta' is wrong by up to 1e3 (DIII-D n = 2: -111 or 794 against -0.733 converged; n = 1: -1.09e5 against -635). The axis interval is now split into nAxisMin = 8 pieces once every inner region is split, and nIntervalsMin counts them. Converged at 8 pieces in every case tried; DIIID ideal/resistive, a10 and both resistive Solov'ev examples are bit-identical; the ideal Solov'ev ones move <= 4e-6 in Delta'. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
StuartBenjamin
added a commit
to StuartBenjamin/GPEC-1
that referenced
this pull request
Oct 18, 2026
StuartBenjamin
marked this pull request as draft
October 19, 2026 07:57
StuartBenjamin
marked this pull request as ready for review
October 23, 2026 02:12
matt-pharr
approved these changes
Oct 23, 2026
matt-pharr
left a comment
Collaborator
There was a problem hiding this comment.
Nice catch. Generalized to naive intervals also.
StuartBenjamin
pushed a commit
to StuartBenjamin/GPEC-1
that referenced
this pull request
Oct 23, 2026
PrincetonUniversity#327 PrincetonUniversity#328 PrincetonUniversity#329 PrincetonUniversity#335 merged upstream; + 63328e4 STRIDE naive packing within nIntervalsTot, 0d6b30f docs) into PSFC_dev
This was referenced Oct 23, 2026
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.
STRIDE's innermost Δ′ can be wrong by orders of magnitude when the interval from the axis to the first rational surface is not subdivided.
ode_set_intervalshands out the spare intervals by estimated compute time, and that estimate rates the axis interval as cheap. So at the defaultnIntervalsTot = 33it often stays whole, and it always does whennIntervalsTotis forced up to its minimum (n = 2 with 11 or more surfaces). This PR splits the axis interval into 8 pieces once every inner region has been split, and counts those pieces in the forced minimum.Diagonal Δ′ of the innermost surface, on three DIII-D equilibria (RDCON, develop + #300, on the same deck in the last column):
With the axis interval in 4 pieces the first case gives −1.29; from 8 pieces on, every case agrees with its 132-interval value to 4 digits. Run time is unchanged (20 s, 12 s and 7 s at 2 threads).
Examples:
DIIID_ideal,DIIID_resistive,a10_ideal,solovev_resistiveandregression_solovev_resistivegive bit-identicalstride_output_n1.nc.solovev_idealandregression_solovev_idealmove ≤ 4e-6 in Δ′ (the W eigenvectors by up to 2e-3).a5_tearing_examplestops with "Integration direction not reversed" on develop and on this branch alike.🤖 Generated with Claude Code