The 3D trackway simulator reconstructs speed with R. McNeill Alexander's (1976) empirical trackway equation — a dimensional power-law fitted to living animals, not derived from first principles:
v_Alexander = 0.25 · g^0.5 · SL^1.67 · h^-1.17
This 2D version computes speed a completely different way: it treats the swinging leg between footfalls as a real rigid physical pendulum pivoting at the hip, and integrates its exact nonlinear equation of motion —
φ'' = -(g/h)·sin(φ), φ(0) = -φ₀, φ'(0) = 0
sin(φ₀) = (SL/2) / (2h) (swing amplitude from stride geometry)
— which has no closed form in elementary functions, so the half-swing time is obtained from the complete elliptic integral of the first kind, computed here via the arithmetic-geometric-mean (AGM) algorithm:
t_swing = 2·sqrt(h/g)·K(sin(φ₀/2))
v_pendulum = SL / (2·t_swing) (one stride = two leg-swings)
Both numbers are genuine, independently computed physical models of the same trackway — not a re-skin of one formula. They agree best for a brisk, near-critical walk and diverge sharply as relative stride grows toward a running gait, because a free-swinging pendulum has no way to model the elastic tendon energy return and aerial phase that let a running animal cover far more ground per stride than gravity alone would allow. That divergence is itself real science: it is the same reason Alexander needed an empirical curve fit in the first place, rather than pure mechanics.
- SL/h < 2.0 — walk, both methods reasonably close.
- 2.0 ≤ SL/h < 2.9 — brisk walk / trot transition, methods start to diverge.
- SL/h ≥ 2.9 — running gait (aerial phase); the pendulum model is stretched past its assumptions and the two methods disagree the most.
- If the stride is so long that the leg's swing amplitude would have to exceed a right angle (SL > 4h), the pendulum-swing geometry itself breaks down — flagged below rather than silently extrapolated.
The verification numbers (RK4 integration of the ODE vs. the closed-form elliptic-integral formula, and the AGM elliptic integral vs. an independent numeric quadrature) agreed to 9–13 significant figures in a standalone Node.js check before this page was built.