Skip to content

sbeg radial meaning differs between Boozer (s) and scaled REFCOORDS (sqrt(s)) sampling paths #359

@krystophny

Description

@krystophny

Problem

sbeg is fed verbatim as the radial coordinate to whichever magfie is
active during init_starting_surf, so its physical meaning depends on the
sampling path:

  • VMEC equilibrium runs (any field type) sample via VMEC magfie, whose
    x(1) = s (normalized toroidal flux): sbeg = s.
  • Boozer runs sample via magfie_boozer, x(1) = s: sbeg = s.
  • The scaled REFCOORDS path samples at x(1) = rho (scaled_to_ref_coords:
    chartmap reference u_ref = x_scaled; VMEC reference u_ref = x_scaled**2,
    so the integration coordinate is sqrt(s)): sbeg = rho = sqrt(s).

So sbeg = 0.5 starts at s = 0.5 on the Boozer/VMEC path but at
s = 0.25 on the scaled REFCOORDS path. Comparing a VMEC run on one path
against a chartmap run on the other starts particles on different physical
surfaces. export_boozer_chartmap_tool also writes start points as
rho = sqrt(s), so a start.dat carries the reference convention of the
run that produced it.

Geometric/UNKNOWN (map2disc) references have no toroidal flux, so s is
undefined there.

Proposal

Anchor sbeg to normalized toroidal flux s wherever a toroidal flux is
defined: convert s to the active sampling coordinate (identity for
Boozer/VMEC, sqrt for the scaled REFCOORDS path) at the points that seed
start positions (init_starting_surf, sample_grid, volume-sampler
bounds). For geometric/UNKNOWN references keep sbeg as the reference
radial coordinate and state that at startup. Add a characterization test
asserting sbeg = s_target starts on the same physical surface for VMEC
and a rho_tor chartmap of the same equilibrium. Expect golden-record
movement on the REFCOORDS/RK45 path; regenerate with justification.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions