Repository navigation
Equilibrium solve on a canvas of dual numbers - #53
Merged
Merged
Conversation
… on dual numbers Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
…mber type, element-type generic defaults Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
…fferences Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
Conflict in flux_bounds!: master removed the try/catch with the diagnostic plot, so the guard that skipped that plot for dual numbers is dropped. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Dual-number support in the coil and control routines is available from that release. Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
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.
Equilibrium solve on a canvas of dual numbers, so that FRESCO can sit inside a forward-mode AD chain (ForwardDiff). The Picard iterations carry the derivatives directly.
Dependencies: requires IMAS 7.5 and VacuumFields 6.3 (both released). The new test uses
IMAS.retype/IMAS.seedand the element-type generic control matrices from VacuumFields.Changes
Canvastakes the grid-range type as a parameter (RG<:AbstractRange{T}). Float64 grids stayStepRangeLen; a canvas of dual numbers uses whateverrangereturns. TheCanvas(dd, Rs, Zs, ...)constructors accept anyAbstractRange.PprimeFFprime,PressureJtoRandPressureJtget a type parameterSforffp_scale/J_scale(wasFloat64). The default scale is one in the number type that the interpolant returns.λ_regularizeand the control offset vector follow the element type of the canvas.Compatibility
Adding type parameters to
Canvasand the three profile types breaks code that spells out their full parameter list. I found none in FUSE or IMAS. Constructors and field access are unchanged, and Float64 results are unchanged. A minor release (0.8) seems appropriate.Note on the version
The branch starts from the
v0.7.4release commit (3fecc21), which is not on master. Master has its own 0.7.4 bump, so after merging master the version is unchanged.Tests
New
test/runtests_dual.jl: an equilibrium solve on a canvas of dual numbers against finite differences.Pkg.test()passes in CI (Julia 1.x) against the registered releases.Part of a set with ProjectTorreyPines/FUSE.jl#1226, which tests the whole stack in its CI.
🤖 Generated with Claude Code