Skip to content

Recompute Krook argument after interpolation#183

Open
krystophny wants to merge 1 commit into
feat/flux-pumping/wp5-collision-scalefrom
fix/flux-pumping/wp5-recompute-z0
Open

Recompute Krook argument after interpolation#183
krystophny wants to merge 1 commit into
feat/flux-pumping/wp5-collision-scalefrom
fix/flux-pumping/wp5-recompute-z0

Conversation

@krystophny

@krystophny krystophny commented Jul 13, 2026

Copy link
Copy Markdown
Member

Recomputes the derived Krook argument z0 from interpolated omega_E, k_parallel, collision frequency, and thermal velocity on the solver grid. Previously KIM interpolated z0 itself across the k_parallel=0 singularity; a four-point polynomial stencil could produce order-1e12 values where the defining formula gives order 1e-3.

The invariant is now z0 = -(omega_E - omega - i nu)/(|k_parallel| sqrt(2) v_T) at every solver-grid point. Primitive profile interpolation, collision formulas, units, resonance convention, and boundary conditions are unchanged.

Verification

Before: the synthetic coarse-to-solver-grid regression failed because interpolated z0 violated its defining formula.

After: the focused regression passes; the full CMake build and all 30 CTest tests pass; bare fo passes Static, Build, Tests, and Lint.

At omega=1e5 and collision scale 1, the fix removes the Krook overflow and reduces the 64-point hat peak from 1.9e10 to 7e-3 statV. A controlled refinement excludes an earlier nominal 128-point run that accidentally retained omega=0. The valid gauge-removed 64-to-128 profile change is 0.093, but 128-to-256 changes by 7.32 and the peak grows from 7.1e-3 to 1.15e-1 statV. The Krook hat basis is therefore not grid-convergent and is not promoted to CTest.

Relation to Markus's Fokker-Planck periodic branch

This PR fixes an independent hat-path correctness defect: interpolate primitive quantities and recompute the singular derived Krook argument z0. That invariant stands regardless of which periodic implementation survives. It may land independently when its own stack and CI are green; it does not count as FP validation.

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant