Although the chaos game guarantees that fractal
will be
filled out provided
is described by an IFS where each
transformation is a contraction and the probabilities associated with
each are nonzero, there are some practical considerations.
The first is that on a computer a ``random'' sequence usually means a
pseudo-random sequence with a finite (though large) period. Thus,
you'd better be sure that the number of points required to fill out
to the desired resolution is substantially smaller than
your pseudo-random number generator's period.
Another consideration becomes obvious when you play with the
probabilities associated with the IFS for
. Some choices
fill out certain addresses much more quickly than others. Indeed, the
choice of probabilities adds some extra structure to
:
the density or measure associated with subsets of
.
Barnsley (Fractals Everywhere) describes one implementation
of this measure, defined for a grid containing
: for each
grid point
in the grid the density is the fraction of total game points
generated by the chaos game that land on
. This measure combines
both the size of
's intersection with
and how
efficiently the chosen probabilities fill in
.
I have chosen a slightly different approach. For each sub-square of a
grid containing a fractal-like object
, I first
approximate the size (``area'') of its intersection with
by counting the number of addresses of
to an arbitrary
depth (
for example). I then divide the number of ``hits''
generated by the chaos game on this sub-square by the ``area'' of its
intersection with
to determine a density. I re-colour
to indicate the relative density of various sub-squares,
the densest coloured white, the sparsest red. The size of the
sub-squares is user-selectable (by selecting address length). I think
this approach gives a good qualitative description of how efficiently
is being filled out.