Skip to content

KineticForces — dW_kinetic (imaginary NTV energy) ~17–19% off Fortran on DIIID benchmark #269

Description

@logan-nc

Summary

On the DIIID PENTRC benchmark (PR #112, "KineticForces Module"), the NTV torque metrics clear the 5 % acceptance bar against Fortran GPEC, but the imaginary energy-conversion-rate metrics — dW_kinetic — do not. They drift ~17–19 % from Fortran. This was flagged during PR review and explicitly accepted as a non-blocking follow-up; this issue tracks resolving it.

Evidence

Torque (headline result) — passing:

Metric Julia Fortran Error Status
T_total_fgar (N·m) 1.805189 1.780406 1.39 % ✅ < 5 %
T_total_tgar (N·m) 0.991272 0.948962 4.46 % ✅ < 5 %

Imaginary energy-conversion-rate dW_kinetic — out of band:

Metric Julia Fortran Error Status
dW_total_fgar 0.160012 0.136829 16.94 % ⚠️
dW_total_tgar 0.133295 0.112297 18.70 % ⚠️

This is a regression from PR #224's pre-merge values (dW_fgar = 2.68 %, dW_tgar = 4.81 %). An A/B test on merged HEAD with the pre-port energy integrator swapped back in gives identical numbers, so the energy-integrator port itself is ruled out as the cause.

Leading hypothesis

Develop commit 083b0cc0 ("EQUIL - BUG FIX - Snap periodic theta endpoint at 2D interpolant construction sites") changed how 2D equilibrium interpolants evaluate near the periodic-θ boundary. Bounce-data computation reads those interpolants, and the imaginary part of the kinetic resonance integral is far more sensitive to that boundary than the real (torque) part — consistent with T passing while dW shifts by ~12–13 % from #224's pre-merge value.

Proposed next steps

  1. A/B the bounce-data interpolant reads with the pre-083b0cc0 θ-endpoint handling to confirm or deny the hypothesis.
  2. Inspect the imaginary part of the kinetic resonance integral near the periodic-θ boundary for sensitivity to endpoint treatment.
  3. If confirmed, decide whether the fix belongs in the interpolant boundary handling or in how compute_bounce_data samples θ.

Reproducer

BENCHMARK_TGAR=1 julia --project=benchmarks/.benchmarks_env benchmarks/benchmark_diiid_kinetic.jl

References

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Fields

    No fields configured for issues without a type.

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions