OpenWorldLab

Loading interactive view…

Mathematics

Newton Fractal Explorer: Basins of Attraction

Newton’s method finds the roots of a polynomial, the values of z where it equals zero. Here each pixel starts the method from a different guess and takes the colour of the root it reaches. Drag the roots to reshape the coloured regions, called basins of attraction.

zn+1=zn−p(zn)p′(zn)z_{n+1}=z_n-\frac{p(z_n)}{p'(z_n)}

What is a Newton fractal?

Newton’s method improves a guess for a root using the polynomial p and its derivative p′, the rate at which p changes. The explorer repeats that step from every pixel. The starting points that settle on the same root form that root’s basin of attraction, and each root has its own colour.

Within a basin, the shading shows how many steps the guess took to settle. Near a boundary, a tiny change in the starting point can send the calculation to a different root, so the colours interleave in fine detail.

Drag roots or enter your own polynomial

Move the root handles to change the polynomial and its basins. You can also type a polynomial of degree 2 to 8, such as z^5 − 1, in Controls.

In the Cycle preset, some starting points never reach a root: they fall into a loop of values that repeats. Those points stay dark. Zoom into a basin boundary to see neighbouring guesses head for different roots.

Explore and keep a view

Scroll or pinch to zoom, drag to pan, and double-click to centre a detail. With the picture focused, use the arrow keys to pan, plus and minus to zoom, Space to pause Auto zoom and R to reset. Open Controls to choose a preset, palette or iteration limit.

Share view copies a link containing the fractal, exact coordinates and rendering settings. Export image saves the current framing as PNG, JPEG or WebP, with resolutions up to 16K. For more detail, zoom into the picture before exporting.

Compare the fractals

The Mandelbrot explorer also explains escape-time colouring, iteration limits and how deep zoom works.