The anteater must decide how long to feed at each mound before walking to the next. Move the sliders and watch the tangent construction find the best leaving time.
-mean travel time per leg
-optimal feeding time t*
-live intake rate (measured)
-predicted rate g(t)/(tau+t)
-mounds visited
-projected insects/day (12 h)
-tongue peak speed
-patch left on leaving
The science
Patch model. Feeding on one mound has diminishing returns. With a fresh patch holding G grams of termites and a depletion time constant T = G / r0, the cumulative catch is g(t) = G (1 - e^(-t/T)). The initial rate is r0 = f m: tongue flicks per second times grams per flick.
Marginal value theorem. Over a long run the intake rate is R(t) = g(t) / (tau + t), where tau is the mean walking time between mounds. R is largest when g'(t*) = g(t*) / (tau + t*), which is the tangent from the point (-tau, 0) to the gain curve. For this patch it reduces to (tau + t*)/T = e^(t*/T) - 1, solved here by bisection and compared with a brute-force maximum.
Tongue. The tongue is treated as a sinusoidal out-and-back swing x(t) = (L/2)(1 - cos(2 pi t / P)) with length L = 0.6 m and period P = 60 / flicks-per-minute. Its peak speed is pi L / P.
Honest simplifications. All mounds are identical and fully recover between visits, the next mound is chosen at random, the walk is a straight line at constant speed, and the numbers are plausible orders of magnitude rather than field measurements. Real anteaters feed for roughly a minute per mound and eat tens of thousands of insects a day.