O'Reilly logo

Tkinter GUI Application Development Blueprints - Second Edition by Bhaskar Chaudhary

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Drawing fractals

A fractal is a never-ending pattern that repeats itself at all scales. Fractals are found everywhere in nature. We find them in our blood vessels, branches of trees, and in the structure of our galaxies, and the beauty of them lies in the fact that they are made out of simple formulas. 

We will demonstrate the simplicity of these seemingly complex-looking phenomena by drawing a fractal named a Mandelbrot set. We assume a basic knowledge of set theory and complex numbers in this section.  Our code produces a Mandelbrot set that looks like the following diagram:

The Mandelbrot set  is defined as a set of complex numbers, c

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required