Sierpinski triangle

A Sierpinski triangle is a fractal object, meaning that it has a fractal (non-integer) dimension and it is scale-invariant, i.e. if you zoom in on parts of the object, you see smaller and smaller copies of it with identical structures.

The method of construction applied here is the 'chaos game'. Starting with a randomly chosen point of the coordinate system as 'current point' and the initial 'outer' triangle (drawn in red), the following iteration is used:

  1. Choose one of the three corners of the 'outer' triangle at random.
  2. Take the point halfway from the current point to the chosen corner as the new current point.
  3. Mark the current point in your drawing color (green).
This iteration is processed for a specified number of times, e.g. 100000 times.

A Java applet appears here.


Peter Uelkes
Last modified: Sat Dec 30 16:39:27 CET 2000