Travelling waves
Textbook kinematics: a body coordinate s carries a travelling phase
θ = 2πs/λ + 2πft
y = A sin θ · z = B(1 + sin(θ + φ))/2
Textbook force balance: the model chooses body translation U so the summed local resistance is zero:
Σ [ζ∥(v·t)t + ζ⊥(v·n)n] Δs = 0
Here v = U + vdef; t and n are local tangent and normal directions. Contact segments contribute resistance, lifted segments do not; the control sets the ratio ζ⊥/ζ∥. Translation is integrated with fixed-step RK4.
Independent contact check
For a sinusoidal lift wave, the exact contact fraction is
F = ½ + asin(2h/B − 1)/π
The live audit compares this closed-form value with the sampled body segments.
What is simplified
This is a planar, quasi-static, linear anisotropic-resistance model. It illustrates how crosswise resistance can rectify lateral undulation into forward motion; it is not a full granular-contact simulation or a measured prediction for a particular snake. Body stiffness, three-dimensional curvature, variable loading and substrate grain dynamics are omitted. Body length (2.4 m) and wavelength (1.2 m) are illustrative model scales, not universal animal constants. The low-advance indicator at 0.015 m/s is an illustrative display threshold.
Keyboard: Space plays or pauses, the right arrow advances one step, and R resets time and position.
Illustrative educational model, not affiliated with any real institution or manufacturer.