KenSchutte.com
random pic random pic random pic random pic random pic
 

 

Fractals: The Mandelbrot Set

I wrote a Matlab program to generate images of the Mandelbrot set. Here are a couple of the images (and a movie). If you're looking for cool fractal images, you can find much better ones on the web then these. But, if you want to see a simple Matlab program to generate them, check out these m-files.

Images

Successive images zooming on the point -0.718630087378 + i 0.232496359354

Clicking thumbnails will show 800x600 version.

27 KB
fractal image
57 KB
fractal image
185 KB
fractal image
371 KB
fractal image
402 KB
fractal image
475 KB
fractal image
311 KB
fractal image
317 KB
fractal image

zoom-in movie: I was trying make a movie of zooming in and out at interesting points in the Mandelbrot Set. It didn't turn out that great though. Standard video codecs do a lousy job of compressing these kind of images and the uncompressed version was approaching half a gig.

Generating images

The amazing thing about fractals (and the Mandelbrot set in particular) is that such an incredible never-ending set of images can be created from a very simple and short program. The files used to create these images are listed below. They are written in MATLAB scripts, but even if you don't know what MATLAB is, you can probibly still get an idea of how it works. The most important one is mandelbrot.m. Note they're written with "for" loops instead of vectorized, so generally not very efficient in Matlab, but perhaps easier to see how the Mandelbrot set works.

  • createstills.m: Creates a series of images (.PNG files) of the Mandelbrot set of zooming in on a particular point in the complex plane. Sets up parameters and then calls mandelbrot.m for each frame (each image).
  • mandelbrot.m: This the script that actually creates a single grayscale fractal image. There are a bunch of sites out there explaining exactly how the Mandelbrot set is created (i.e. what this script does), so I won't go into the details here. But this short script gives an example of one possible implementation.
  • addColor.m: Called by createstills.m, this converts the grayscale image into a color image
  • createavi.m: Creats a video file (AVI format) from a collection of PNG iamges.

Download all: .zip or .tgz

Others

Here's a couple much cooler fractal images which I did not create: (I found these somewhere on the web, but now I don't know where they came from)

1024x768
799 KB
fractal image
1024x768
864 KB
fractal image

© 2008 Ken Schutte