A wind of a few metres per second is as fast as the butterfly. Which heading rule gets the flock to the wintering forest with fuel left?
Runs all three strategies on the same wind and nectar patches (fast-forward, no 3D) and draws their tracks on the map.
The science
Wind triangle. Ground velocity = air velocity + wind: g = va ĥ + W. To hold a track d̂ the cross-wind component Wn must be cancelled by pointing the nose upwind by the crab angle δ = asin(Wn/va); the speed made good is va cos δ + W∥. When |Wn| ≥ va no heading can hold the track. A fixed heading simply drifts sideways at Wn: 3 m/s is 10.8 km every hour.
Energy. Metabolic power while flapping is modelled as P = p0 m + c v³ (a mass-specific baseline for muscle and wing work plus parasite drag; p0 = 45 W/kg and c = 7×10-5 W s³ m-3 are illustrative round numbers, not measurements). Gliding and thermal soaring cost a fraction (7 W/kg) at a lower airspeed; the glide share slider is the fraction of time spent soaring. Fuel is lipid at 39.3 MJ/kg, so the reserve falls by P·dt/E and the body gets lighter.
Best-range airspeed. Maximising (v + W∥)/P(v) has the closed form v = (p0 m / 2c)1/3 in still air; a headwind raises it and a tailwind lowers it. The page checks the numerical optimum against the closed form.
Nectar stops, roosting and the sea. Flowers sit in patches every patch spacing km on land; the butterfly stops at a patch when its lipid is below the chosen fraction and feeds at the nectar rate until the target fraction. Roosting on land also gives a small roadside nectar share. Over the sea there is nothing to land on and no night roost, so a swept-off butterfly flies on until the fuel runs out. Wind speed, direction, the front swing and the glide share are scenario inputs: real monarchs also use thermals, ridge lift, temperature and daylight cues that are not modelled. Typical values only; verify any species number before quoting it.
The delta coast is stylised, distances are generic and the 3D scene is a close-up loop over the delta while the physics runs on the whole route. Models built with Blender (butterfly, delta terrain, trees, flower patches) and rendered with Three.js.