Guide // Fractals

What is a fractal flame?

A fractal flame is a picture made by a single point jumping millions of times between a few simple rules picked at random. Where it lands most often, the image glows. Here is how a handful of rules turns into smoke, feathers and petals.

  1. 01The chaos game
  2. 02Iterated function systems
  3. 03From fern to flame
  4. 04Brightness on a log scale
  5. 05Colour from history
  6. 06Symmetry
  7. 07How our flame posters are made

01The chaos game

Draw three corners of a triangle and put a point anywhere. Now pick one corner at random and move the point halfway towards it. Repeat. After a few thousand jumps the points form the Sierpinski triangle, a fractal of triangles inside triangles, even though every single jump was random.

This is the chaos game, popularised by the mathematician Michael Barnsley. The randomness only decides the order of the jumps. The shape itself is fixed by the rules.

xₙ₊₁ = Fᵢ(xₙ),   i chosen at random

02Iterated function systems

Each rule in the chaos game is a function that shrinks, turns and shifts the plane. A set of such rules is called an iterated function system, or IFS, described by John Hutchinson in 1981. Its fractal is the one shape that every rule maps back onto part of itself.

In 1988 Barnsley showed in his book Fractals Everywhere that just four of these rules draw a fern, down to the smallest leaflet. This is the Barnsley fern, and it made the idea famous.

A(x, y) = (a·x + b·y + c,  d·x + e·y + f)

03From fern to flame

Plain IFS rules only use straight-line maps, so their fractals look crisp and geometric. In 1992 the programmer Scott Draves added a bend: after the straight-line step, each rule passes the point through a non-linear function called a variation, such as sine, sphere, swirl, spiral or horseshoe.

The variations curve the plane, and the result no longer looks like geometry. It looks like smoke, silk and fire, which is where the name comes from. Draves later used flames in Electric Sheep, a screensaver started in 1999 that shares flames between thousands of computers.

F(x) = Σ wⱼ·Vⱼ(A·x)
Smoke - fractal flame poster
Smoke: a few rules with threefold symmetry, about 10 million points.See the poster →

04Brightness on a log scale

A flame is a histogram: the program counts how many times the point lands on each pixel. Some pixels are hit millions of times and others only a few, so a straight count would show a bright blob and nothing else.

Flames use the logarithm of the count instead. That compresses the range, so the dense core still glows while the faintest wisps stay visible. It is the same trick the eye uses to see both a bright window and a dark room.

L = log(1 + n) / log(1 + nₘₐₓ)

05Colour from history

Each rule carries its own colour value. Every time the point jumps, its colour moves halfway towards the colour of the rule it just used. A pixel's colour is then the average of the colours of all the points that landed on it.

So the colour records where the point has been, not just where it is. Regions built mostly by one rule take its colour, and regions where several rules meet blend them.

Feathers - fractal flame poster
Feathers: colour follows which rules each point came through.See the poster →

06Symmetry

Add one more rule that simply rotates the point by a fixed angle, and the whole flame gains rotational symmetry. With a rotation of a fifth of a turn, every feature repeats five times around the centre, like the petals of a flower.

Rose - fractal flame poster
Rose: fivefold symmetry around a warm core.See the poster →

07How our flame posters are made

For each piece the program chooses two to four rules, each with its own straight-line map and one or two variations from a set of twelve, and sometimes a rotational symmetry. It tests many candidate sets of rules and keeps one whose flame fills the page well, neither collapsed to a dot nor scattered into dust.

It then runs the chaos game for about ten million points, builds the log-density image and maps the colour history to the palette. The rules are fixed by the piece's number, so the same piece always comes out the same.

FAQQuestions

What is a fractal flame?

A fractal flame is an image made by the chaos game with non-linear rules: a point jumps millions of times between a few functions picked at random, and the picture shows how often it lands on each pixel, on a log scale, coloured by the rules it passed through.

Who invented fractal flames?

Scott Draves devised the fractal flame algorithm in 1992, building on iterated function systems (John Hutchinson, 1981) and the chaos game popularised by Michael Barnsley.

What is the difference between a fractal flame and an IFS fractal?

A classic IFS fractal like the Barnsley fern uses only straight-line maps and draws points as on or off. A flame adds non-linear variations, log-density brightness and colour from the rules, which gives its soft, smoky look.

Are fractal flames really fractals?

Yes. Each is the attractor of an iterated function system: the shape that the rules map back onto itself, with detail repeating at smaller and smaller scales.

SERIES I // FRACTAL FLAME

Fractal flame posters

All Flame (4) →
Flame - Feathers Feathers Flame from €39 Flame - Smoke Smoke Flame from €39 Flame - Rose Rose Flame from €39 Flame - Pinwheel Pinwheel Flame from €39

More guides: What is a strange attractor?The Mandelbrot set explainedThe Hopf fibration explainedMath gifts for people who love equationsPerlin noise explainedFractal art: what it is and how it is made