Chaos game
From Wikipedia, the free encyclopedia
The chaos game or chaosgame is a means of creating a fractal, using a polygon and a random point inside it. The fractal is created by finding the point a given fraction of the distance between the previous point and one of the vertices, chosen at random, a large number of times. Using a regular triangle and the factor 1/2 will result in the Sierpinski triangle. In this way, a great many shapes can be generated, all the more realistically if the original shape has a hidden fractal order. The chaos game is an example of a random process leading to a predetermined result.

More generally, the chaos game is a way of generating the attractor, or the fixed point, of any iterated function system (IFS). Starting with any point x0, successive iterations are formed as xk+1 = fr(xk), where fr is a member of the given IFS randomly selected for each iteration. The iterations converge to the fixed point of the IFS. Whenever x0 belongs to the attractor of the IFS, all iterations xk stay inside the attractor and, with probability 1, form a dense set in the latter.