L‑systems playground ▾
What’s an L‑system? ▸

An L‑system (Lindenmayer system, 1968) grows a picture from a tiny recipe. You start with a short string of symbols (the axiom) and a set of rules that say how to rewrite each symbol.

Every generation, all symbols are replaced at the same time (in parallel). Do that a few times and a handful of characters explodes into thousands.

Then a turtle reads the final string like a tiny plotter: some letters draw a line, others turn or remember a branch point. That’s how a 20‑character rule becomes a fern.

Biologist Aristid Lindenmayer invented them to model how plants and algae grow — which is why the branching presets look so organic. Drag the angle slider on the fractal plant to watch it bend.

Rewriting, step by step ▸

Generations 0–3 of the current system. Highlighted spans in gen 1 show where a rule fired.

Turtle legend ▸
Fdraw forward one step (also G) fmove forward without drawing +turn by +angle −turn by −angle [push — remember this spot & heading ]pop — jump back to it (starts a branch)

Any other letter (like X, A) draws nothing — it only exists to drive the rewriting.

Drag to pan · pinch / scroll to zoom · double‑tap to reset