Educational radiation physics: how strong a magnetic shield must be to turn charged space particles away from a spacecraft, and what happens when the particle energy overloads it.
...
running...
The science
A charged particle of charge q and momentum p in a uniform magnetic field B moves on a circle (Lorentz force, F = q v × B), with Larmor (gyro) radius
r = p / (|q| B), p c = sqrt(T² + 2 T m c²)
A particle that enters the slab of thickness L perpendicular to its face is turned around if r < L and exits on the far side (reaching the hull) if r > L. The critical (overload) energy at fixed B and L is where r = L, i.e. p = |q| B L. The page integrates every particle with the relativistic Boris pusher (exact rotation, speed conserved) and shows the Larmor-radius criterion next to the simulated outcome.
Honest simplifications. 2D motion, a sharp-edged uniform field (a real magnetosphere or a spacecraft coil has a dipole fall-off), no secondary radiation (bremsstrahlung, nuclear spallation), no uncharged radiation (gamma, neutrons), no shield mass or power budget. Real proposed active shields need fields of order a tesla over metres and enormous currents; this is a teaching model of the principle only. Inanimate particles only; nothing here is a weapon model.