Pan and zoom to frame your area of interest. The visible bounds become the FABDEM extent. Stay under 50 MB (cell count × 4 bytes) — the button below disables itself when you exceed it.
Tweak the visualization stretch and the energy-field physics that drive the toxic cloud and the collection routes. Visualization changes take effect immediately; physics changes apply on the next Run.
Stretch the cmocean.phase palette to the central pmax−pmin%
of cells; outliers saturate at the ends. Slope strength is the maximum
darkening factor of the multiply blend at the steepest slope.
Step cost: α·dist + β·max(0,Δh) uphill,
max(0, α·dist − η·β·|Δh|) downhill (clamped at zero).
Higher β → ridges block more dramatically. Higher η → cloud pools
deeper in valleys and runs farther downslope.
Same cost shape as the cloud, but with truck physics: cheap flat cost, modest uphill penalty, slight recovery downhill. Mirrors the sampasimu energy model defaults.
Annual simulation of three actors from Spec.md: a
Garbage Collector, a Landfill Operator,
and a Waste Regulator. The simulation runs entirely
in the browser — no server, no Python.
Monthly: Regulator issues fresh pickup locations (default 10 / month) and the Collector plans the route through the elevation grid. Daily: Collector follows the planned route, picks up at every location, then delivers to the landfill. Weekly: Landfill disposes the accumulated payload, emits a toxic cloud, and reports KPIs to the Regulator.
Each segment of the daily route (depot → stop1, stop1 → stop2, …,
stopN → landfill) is a Dijkstra-shortest path on the elevation
grid under truck physics: α=0.008 per metre flat,
β=1.0 per metre uphill, η=0.1 downhill
recovery — same asymmetric energy model as the sister sampasimu
app. The visit ORDER is itself nearest-neighbour on cost-distance
(not Euclidean), so a stop on the wrong side of a ridge gets
visited later in favour of a flatter "farther" one. Routing runs
on a downsampled (~250-cell) version of the DEM to keep the
per-month plan under ~150 ms.
Each weekly disposal seeds a plume of nominal radius
r₀ = 5·(mass/1000). Per-day area decay is
r(t) = r₀·(½)^(t/2); multiple events superpose by area
to give the day's budget, r_iso (the dashed
circle on the map).
The plume itself is a cost-distance flood from the landfill on the
elevation grid, with an asymmetric step cost:
α·dist + β·Δh uphill, max(0, α·dist − η·β·|Δh|)
downhill (clamped at zero so Dijkstra stays well-defined). Defaults:
α=1, β=8 (steep uphill cost — ridges
substantially block the spread), η=0.4 (downhill
recovery — heavy gas pools in valleys and runs farther downslope).
The cloud is rendered as filled contours at six iso-cost bands plus
thin contour lines at every band boundary. On flat terrain the
plume collapses back to a circle of radius r_iso.
Elevation uses cmocean.phase — a
cyclic palette better at separating subtle terrain bands than a
sequential ramp. Slope shading sits on top with
multiply blend mode: flat areas pass white through
(no change), steep areas darken whatever is underneath, giving a
shaded-relief look. Each layer has independent visibility +
opacity. The day slider scrubs through the year; autoplay loops
at ~6 fps.
The same seed gives the same hill arrangement, the same monthly
location sets, and the same per-day payload masses. The numerics use
a Mulberry32 PRNG — not bit-identical to Python's random,
but seeded the same way for reproducibility within the JS port.