Skip to content

ForceFreeStates - FEATURE - Resample ξ on a fixed ψ grid from the Euler-Lagrange dense output #502

Description

@jhalpern30

Summary

The forward Euler–Lagrange integration in ForceFreeStates (FFS) stores ξ only at accepted ODE steps (every save_interval-th step, plus near rational surfaces). PerturbedEquilibrium and KineticForces interpolate ξ(ψ) between those stored points, so their accuracy, NTV torque in particular, follows the step density chosen by the ODE error control rather than a resolution chosen for the downstream calculation.

Evidence

Proposal

Sample ξ on a fixed ψ grid owned by PerturbedEquilibrium, evaluated from the solver's dense output between accepted steps, so downstream accuracy is set by that grid and not by step control. save_interval would then only control what is written for diagnostics.

Split from #93, whose remaining items are tracked in #481, #464 and this issue.

Activity

  1. logan-nc commented on Oct 5, 2026

    @logan-nc
    Collaborator

    @jhalpern30 This has historically been put off because it's a kind of darned-if-you-dont-darned-if-you-do situation.
    You need the resolution where the solutions are sharp (i.e. near rationals) and the resolution you need to capture the sharp displacement behaviors is exactly what is being determined by the dynamic stepping - so yes, your grid changes with FFS tolerance but if you make up a grid beforehand you can easily miss fey features. The downsample was my attempt to find a middle ground. I'm happy to entertain other ideas, but would worry about any proposal to just ignore the FFS ODE dynamics.

  2. jhalpern30 commented on Oct 5, 2026

    @jhalpern30
    CollaboratorAuthor

    Well this is mildly annoying... I was working on the PR comments for #480 and my Claude decided that Daniel's Claude comments combined with my instructions meant I was asking for a new issue to be opened when I had already decided not to after it "flagged this" as a problem during that PR. I let it through because I thought it was committing the PR review changes, not opening a new issue. Closing this for your above reasoning, sorry about that

  3. logan-nc commented on Oct 5, 2026

    @logan-nc
    Collaborator

    🤦

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

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions