A magnetic spectrometer like AMS-02 (mounted on the ISS since 2011) never "sees" a charge — it infers it from geometry. A charged particle of momentum p crossing a field B curves with radius:
r [m] = p [GeV/c] / (0.3 · Z · B [T])
Rigidity R = pc / (Ze) ≈ E for ultra-relativistic leptons
The permanent magnet's field direction is fixed and known, so the sign of the curvature (up vs down in this side view) directly reads off the sign of the charge — silicon tracker planes (the dashed verticals) on either side of the magnet measure the trajectory precisely enough to separate positrons (e⁺) from the ~1000× more common electrons (e⁻) and cosmic-ray protons.
Doing this for millions of particles gives the positron fraction f(E) = Φe⁺ / (Φe⁺ + Φe⁻). Ordinary "secondary" positrons, knocked loose when cosmic-ray protons hit interstellar gas, predict a fraction that falls smoothly with energy. Instead, AMS-02 (confirming an earlier PAMELA result) measured f(E) turning around and rising from about 8 GeV up to roughly 200–300 GeV before flattening — an excess with no confirmed source, debated between dark-matter annihilation and nearby pulsars such as Geminga.
- Particle energy — sets the rigidity of injected particles and where they land on the graph below.
- Field B — a stronger field tightens the curvature radius (visually exaggerated here for clarity; the readouts use the real formula).
- Field polarity — flips the direction of B; every track's bend flips with it, but the sign-vs-charge relationship (and hence the measured fraction) is unchanged — only which side is "up" for a positron changes.
- Inject / Stream — fires particles whose e⁺:e⁻ mix is drawn from the real AMS-02 fit at that energy; watch the orange Monte Carlo dots converge onto the blue measured curve as more particles accumulate in each bin.
- Zoom / drag — the beam-line view can be dragged to pan and zoomed to inspect the curvature near the magnet up close.