Deepwell

How the rules work

L-systems

Rewriting a word over and over, then letting a turtle draw it.

Rewrite

Start with a short word, like F--F--F. Each round, replace every letter by its rule. With F → F+F--F+F, every F becomes four F's with turns between them, so the word grows four times longer each round.

Draw

A turtle reads the final word: F means step forward drawing a line, + and − mean turn by a fixed angle, [ and ] mean remember this spot and return to it. With 60° turns, the word above draws the Koch snowflake. Each round replaces every straight edge with a bent one, and the perimeter grows by a third every time without the area ever escaping its box.

Plants

Brackets let one stem branch into many. Biologist Aristid Lindenmayer invented these systems in 1968 to describe how algae and plants grow, and a handful of rules is enough to draw convincing weeds and trees.

Write your own rules