About Fractal Garden
Pick a plant or a curve and it appears on the sheet, finished. Press GROW (or G, or Space) to watch it drawn again one stroke at a time, at the speed you pick. FINISH (F) draws the rest at once. Change the angle, the generations, the wind and the rest and the specimen changes with you. + and − add or take away a generation, N picks a new seed for the random parts.
Every picture comes from a few lines of rules, shown in the RULES folder. Edit them and see what grows: the drawing fits itself to the sheet. Click a preset again to get its rules back.
THE STORY
In 1968 the Hungarian biologist Aristid Lindenmayer described a way to model how simple many-celled organisms such as algae grow: every cell is a symbol, and at each step every symbol is rewritten at the same time by a rule. These became known as L-systems. In the 1980s the computer scientist Przemysław Prusinkiewicz joined the rewriting to turtle graphics, and the two wrote The Algorithmic Beauty of Plants (1990), where most of the plants here come from. Lindenmayer died in 1989, before it came out.
The turtle comes from Logo, the teaching language created in 1967 by Wally Feurzeig, Seymour Papert and Cynthia Solomon: a pen you steer with "forward", "left" and "right", the same turtle Python still ships with. The curves are older than any computer. Helge von Koch drew his snowflake in 1904, David Hilbert his square-filling curve in 1891, and Wacław Sierpiński his triangle in 1915. The dragon curve was found by the NASA physicists John Heighway, Bruce Banks and William Harter in the 1960s, and made famous by Martin Gardner in Scientific American in 1967. Bill Gosper found his "flowsnake" in the 1970s, and Paul Lévy studied his C curve in 1938.
A herbarium is a library of pressed plants, each glued or taped to a sheet with a label saying what it is and where it was found. The Italian botanist Luca Ghini is usually credited with starting the idea in the first half of the 1500s. The Latin names on these labels are made up for fun.
HOW IT WORKS
Start with the axiom. Each generation, replace every symbol that has a rule with the rule's right-hand side, all at once. Then a turtle reads the result: F (or any symbol in "Draw with") moves forward one stroke and draws it, f moves without drawing, + and − turn left and right by the angle, | turns round, [ remembers where the turtle is and ] jumps back there, which is how branches work. Other letters, like X, draw nothing: they only steer the rewriting. Give a symbol two or more rules and each copy picks one at random, which is how the Wild tree grows a little differently with every seed.
The string grows fast: the Koch snowflake has 4 times as many strokes each generation and the Bush 8 times. So the generations stop before 250,000 strokes or 2 million symbols, and nothing you type can freeze the page. Branches shrink makes each level of branching shorter, Wind bends thin branches more than thick ones, and Wobble adds small random turns. Ink coloured by depth runs from bark to leaf as the branches go deeper; by path it changes along the line, so you can see the order a curve is drawn in.
The Fern here is an L-system plant. Michael Barnsley's famous fern (1988) is made a different way, by jumping a dot at random, like the Chaos Game.
FURTHER WATCHING AND READING