Every pixel's color is a mathematical answer: how long before this point escapes to infinity?
Open any fractal renderer and you'll see vivid rings of color radiating outward from a black center. The colors aren't artistic decoration — they're a direct visualization of a mathematical measurement: how fast does each point escape to infinity?
For each pixel, you pick the corresponding complex number and iterate the formula starting from . You keep iterating until either:
The escape iteration count for each pixel determines its color. Points that escape after 5 iterations get one color; points that escape after 50 iterations get another; points that escape after 500 get another still.
Each ring corresponds to a band of iteration counts before escape.
The raw escape time produces integer values: 1, 2, 3, 4… The color transitions between bands are sharp steps, creating ugly concentric rings. Real fractal images use a smarter approach.
The key insight is that even after escaping, you can extract more information about how far the orbit has traveled. The most common trick is to use the normalized iteration count:
smooth_n = n − log₂(log₂(|z|))
This formula uses the magnitude of at the escape step to interpolate between integer iteration counts. The result is a continuous real number, which produces a smooth gradient instead of a staircase.
Smooth coloring eliminates the harsh steps between iteration bands.
Once you have a smooth fractional iteration count, you map it onto a color palette. This is simply a 1D array of colors. The smooth count picks a position in the array; nearby positions get similar colors, producing the gradients you see.
You can cycle the palette — repeating the color array multiple times as the iteration count increases. This creates the characteristic concentric rings: each full cycle of the palette maps to one “band” of the fractal. Choosing a slower cycle rate gives smoother transitions; a faster cycle rate produces tighter, more vivid rings.
FractalSet supports several alternative coloring modes beyond the standard escape time:
Try it in the viewer
Open any location in the FractalSet viewer and click the shader selector. Switch between “smooth”, “rings”, “neon”, and “angle” to see how the same underlying math produces dramatically different visuals.