Chasing the Hare in the Mandelbrot Set
Binary Grain and Numeric Precision

Images from the outer limits of numeric precision.

Take any numeric renderer which allows you to zoom in repeatedly. For instance a Mandelbrot set renderer, because, Mandelbrot sets are always fun. For instance this one (by yours truely). As you keep zooming in and zooming in, and, after a while, eventually, the rendered image will suddenly show pixelation. And as you are zooming in again, the pixels will just increase in size. However, this is not a fault of the visualization layer, it’s just that you hit the mathematical barrier of numeric precision. The grain in binary computers…

Binary grain to du numeric precision
A rendering of the Mandelbrot set. Left: total aspect, right extreme zoom.
Pixelation is due to lack of numeric precision.

The Mandelbrot Set

Trying to educate anyone on the Mandelbrot set is quite a vain endeavor, nowadays. However, for completeness’ sake, here you are: The Mandelbrot set describes the limits of a growth function ( zn+1 = zn2 + x(r,i) ) of a set of complex numbers, usually visualized as a plane described by a real axis (r) and an imaginary axis (i). A test iterates over the numeric set, testing, if the growth function will stay inside a specific, absolute bound (m, usually set to 4) for a given maximum of iterations (c), or, if it will break the bound previously (tending towards infinity). If we break out, we visualize the number of iterations (n < c) this took as a color or a shade of gray in front of a black background where the growth function didn’t break the limit (m).

Mandelbrot set
Mandelbrot set, total aspect (r: -2.15 … 1.15, i: -1.10 … 1.10, c: 31, m: 4).
(Select aspect ratio “1 : 1.125” for this configuration.)

Since visualizations of the Mandelbrot set are well known for their fractal beauty and self-similarity, playing around with it by trying various ranges for r and i, and values for c is certainly fun. Even more so, if you can just click to zoom or select a new aspect in the rendered image, thus adding yourself to a virtually never ending loop of recursions.

Some Aspects of Beauty

Here are some of the sights which are to be found on the way…

Mandelbrot set
Mandelbrot set
Mandelbrot set

Down the Rabbit Hole…

So what happens, if we keep zooming in?

Mandelbrot set
Our particular rabbit hole, where we start our journey.
Mandelbrot set
Mandelbrot set
Mandelbrot set
Mandelbrot set
Mandelbrot set

Eventually…

Mandelbrot set
The hare at the bottom of the Mandelbrot set: Binary grain due to lack of precision.

At this point, we hit a resolution barrier, which is caused by the numeric precision, the way numbers are stored in a binary computer. As our humble renderer happens to be in JavaScript, fractional numbers are represented in floating point format of 64 bits, according to the IEEE 754 standard (52 bit mantissa, 11 bits exponent and a sign bit). We just hit the limits of precisions and factors are so small that they can’t be represented anymore (therefore effectively zero), because we ran out of bits for both the mantissa and the exponent. If we keep zooming in further, the “pixels” will only increase in size, without revealing any more information. What you’re looking at is the absolute information barrier of binary mathematics, the grain of binary computers.