Newton Fractals

Where does Newton's method send you, for every starting point?

Newton Fractals

Newton's method finds a root of a function by repeatedly applying $z_{n+1} = z_n - \dfrac{f(z_n)}{f'(z_n)}$. On the real line, this is the familiar tangent-line method from calculus. Applied over the complex plane instead, every point is a starting guess $z_0$, and every point eventually converges to one of the polynomial's roots — usually the nearest one, but not always. Color each starting point by which root it converges to, and shade by how many iterations it took, and the boundaries between "which root wins" turn out to be fractal: infinitely detailed, and nowhere near as simple as "whichever root is closest."

Drag to pan · scroll to zoom
center = (0, 0)
zoom = 1.0×

Reading the Picture

Each of the $n$ roots of $z^n - 1$ gets its own color — these are exactly the $n$-th roots of unity, evenly spaced around the unit circle: $z_k = e^{2\pi i k/n}$. A pixel at complex coordinate $c$ is colored according to which root Newton's method reaches when started at $z_0 = c$. The brightness encodes how many iterations it took to get there — bright means fast convergence, dark means the starting point was near a boundary and took its time deciding.

Why the Boundary Is a Fractal

Near the middle of each root's basin of attraction, Newton's method behaves exactly as you'd expect: nearby points converge to the nearby root, quickly. But along the boundary between two basins, arbitrarily small perturbations can send you to a completely different root — and zooming into that boundary reveals the same tangled structure again, at every scale, with tendrils of every other basin's color woven in. This sensitivity is a real, well-studied phenomenon (it's a classic example of chaotic behavior in a purely deterministic root-finding method), not a rendering artifact.

What to Try

  • Switch polynomials: higher degree means more roots, more colors, and more intricate boundaries.
  • Zoom into a boundary between two colors and watch the same tangled pattern reappear at the new scale.
  • Raise the iteration count to resolve finer boundary detail (at the cost of a slightly slower render).