Elsevier

Computers & Graphics

Volume 26, Issue 3, June 2002, Pages 505-510
Computers & Graphics

Technical Section
An elementary proof of correctness of the Chaos Game for IFS and its hierarchical and recurrent generalizations

https://doi.org/10.1016/S0097-8493(02)00092-4Get rights and content

Abstract

The objective of this paper is to explain the machinery of the Chaos Game used in the context of various types of iterated function system specifications. Although the discussion is kept in the framework of a mathematical proof, in contrast to the previous work, only the fundamentals of probability are employed. Moreover, unlike the known approaches, the way of reasoning presented in this paper is the same for all the discussed variants of the Chaos Game. As a result, the logical background of the algorithm can be followed by anyone who is interested in fractals and computer graphics.

Introduction

Iterated function systems (IFSs) and their generalizations in the forms of both recurrent and hierarchical IFSs are the most popular ways of describing fractal objects. There are a number of more or less efficient deterministic algorithms to approximate and visualize IFS fractals; among others one should mention Hutchinson's algorithm [1], the graph algorithm by Dubuc and Elqortobi [2], the adaptive cut and other methods by Hepting et al. [3], and the escape buffer by Hepting and Hart [4]. However, despite low efficiency, the most popular way of rendering such objects is still the probabilistic approach known as the Chaos Game. (See, e.g. [5] for an analysis of the Chaos Game from the point of view of the number of iteration steps required to reach a given approximation accuracy.) The main reason for such a situation is that the algorithm is very easy to implement, which makes it usually the best method to use if the figure of merit is “get something working quickly”. Starting with any point of space, the algorithm generates in a probabilistic manner a sequence of points that fills in the attractor at any accuracy measured with respect to the Hausdorff metric. The formal proofs of this fact usually engage various notions and theorems of the measure and ergodic theories for the case of the ordinary IFS [6], [7] and theory of Markov processes for the recurrent IFS [8], which is rather an esoteric matter for a nonmathematician. (The author has not found a proof concerning the case of the hierarchical IFS within the literature.)

Unlike the previous approaches, we introduce an elementary proof that comprises all the mentioned variants of the Chaos Game in a simple and uniform manner. According to the author's intention, the way of reasoning (or at least the corresponding intuition) discussed in this paper, when appropriately presented by a teacher, can be comprehensible for students of computer science. As a consequence, the Chaos Game can be presented along with the theoretical principles of its work in computer graphics classes.

Our proof uses a top–down approach; first we show why the algorithm works properly in its most general variant, namely, the hierarchical IFS, and then we demonstrate how to apply these observations to prove the correctness of the Chaos Game for the special cases, i.e., the recurrent and ordinary IFS. However, if it is necessary, our way of proving can be used for each type of the IFS specifications separately, taking no account of the others.

The roots of our approach can be found in Goodman's analysis of the Chaos Game in its original version for Sierpinski's Triangle [9]. In a sense, we generalize these ideas not only on the level of individual IFS attractors but first of all on the higher level of the types of the IFS specifications. As another source of the way of reasoning demonstrated in this paper, the book by Peitgen et al. [10] should be indicated. Although the explanation presented there is rather informal from the mathematical point of view, it appeals to intuition and can help to understand why the Chaos Game works in the case of the ordinary IFS, if the additional assumption is made that the initial point belongs to the attractor.

Section snippets

Hierarchical IFS and the Chaos Game

Let i=1,...,M, (Xi,di) be a compact metric space, and let (Hi,hi) be the corresponding space of the compact and nonempty subsets of Xi, where hi is the Hausdorff metric induced by di. Now we introduce a compact metric space (H,h), where H=H1×…×HM andh([A(1),…,A(M)]T,[B(1),…,B(M)]T):=maxi=1,…,M{hi(A(i),B(i))}.For a given i,k∈{1,…,M} we define a mapping Wik:HkHi byWik(B):=q=1N(i,k)wq(ik)(B),where wq(ik):XkXi, q=1,…,N(i,k), are contractive mappings, and N:{1,…,M}2N. Let for each i=1,…,M, I(i)

The hierarchical IFS attractor anatomy

Let A=[A(1),…,A(M)]T, A(i)Xi, be the attractor of a hierarchical IFS specified by an operator W:HH on the metric space (H,h), where H=H1×…×HM. On the basis of equalities (3) and (4), we haveA(i)=k∈I(i)Wik(A(k)),∀i∈{1,…,M},where Wik is a set mapping constructed from the contractions {w1(ik),…,wN(i,k)(ik)} according to principle (2), that isWik(A(k)):=q=1N(i,k)wq(ik)(A(k)).Hence, each set A(i) consists of k∈I(i)N(i,k) subsets wq(ik)(A(k)), kI(i), q=1,…,N(i,k), of diametersdiam(wq(ik)(A(k)

Correctness of the hierarchical Chaos Game

Our proof consists of two parts. In the first one, we assume that the initial point of the Chaos Game is in the attractor and we show that the algorithm generates with probability one a sequence, which fills the attractor in a dense manner. In the second part, we allow the starting point to be any point of the space and, using the result from the first part, we prove that, ignoring a finite number of initially generated points, the Chaos Game produces almost surely (i.e., with probability one)

IFS and recurrent IFS

Let us consider a special case of an operator W:HH in which each component mapping Wik:HkHi consists of a single contraction w(ik):XkXi, and for each i∈{1,…,M}, the set I(i) is {1,…,M}. In other words, we are concerned with operators W whose definition (3) can be rewritten to the formW([B(1),…,B(M)]T)=k=1Mw(1k)(B(k)),…,k=1Mw(Mk)(B(k))T.Obviously, such an operator possesses a unique fixed point, namely the attractor A=[A(1),…,A(M)]T of the hierarchical IFS, which can be approximated in the

Conclusions

Although the Chaos Game is the most popular algorithm to visualize IFS fractals, it seems that only few users understand the logical principles of the algorithm's work. This is due to the fact that former proofs of the correctness of the Chaos Game in its various forms were based on complex theories, which are not only difficult for non-mathematicians to follow, but also require a lot of time to complete all the necessary details when taught. In contrast, the proof presented in this paper

Acknowledgements

The author would like to thank Prof. Jan Zabrodzki at Computer Graphics Laboratory of Warsaw University of Technology for reading this paper and valuable comments and suggestions. Special thanks are due to Prof. Władysław Skarbek for fruitful discussions on the Chaos Game and other things connected with fractals.

References (11)

  • S. Dubuc et al.

    Approximation of fractal sets

    J Comput Appl Math

    (1990)
  • J.E. Hutchinson

    Fractals and self-similarity

    Indiana Univ J Math

    (1981)
  • Hepting D, Prusinkiewicz P, Saupe D. Rendering methods for iterated function systems. Proceedings of Fractals ’90,...
  • Hepting DH, Hart JC. The escape buffer: efficient computation of escape time for linear fractals. Graphics Interface...
  • Martyn T. On approximation accuracy of the Chaos Game's finite time activity. Comput Graphics, accepted for...
There are more references available in the full text version of this article.

Cited by (3)

  • A new approach to morphing 2D affine IFS fractals

    2004, Computers and Graphics (Pergamon)
  • Golden section in 3D plants IFS reconstruction

    2008, Proceedings of the 9th International Conference for Young Computer Scientists, ICYCS 2008
View full text