How the Algorithm Works

I have given considerable thought to finding a way for the viewer to see how the algorithm actually works without going to the effort of writing code. One way is to create a Powerpoint file with progressive stages in the construction of the fractal. By clicking from one image to another you can see successively smaller features appearing (or disappearing if you go the other way) in a sort of Powerpoint "movie". Each new set of smaller shapes is given a unique color to label it. The switch from one image to the next is not automatic, but requires a click for each advance.

The shapes are grouped according to the principle that the average size of a shape in one group should be a given fraction of the average size in the next-larger group. For the circles case the average radius changes by 61% from one group to another. What the careful viewer will see is that "on average" the placement of smaller shapes simply repeats the placement of the previous group on a smaller length scale. This property is called "statistical self-similarity" and each new group of shapes can be viewed (by analogy with recursive fractals) as a new "generation" of shapes.

It is inherent in this that the number of shapes in each group of smaller shapes grows rapidly.

It is emphasized that these "movies" all show the very same algorithm. For given parameters c and N the sequence of areas is always the same for any shape. The only things which need changing from one shape to another are (a) One must find a new formula relating area to linear dimensions (e.g., radius = square root of [area/pi] for a circle) and (b) one must write a routine which checks whether one such shape overlaps with another.

While they are all the same algorithm, the behavior you see in the "movies" seems quite different. The new circles show up in "holes", while the new squares tend to fall in rows. The rings show yet another pattern, with a more-or-less fixed fraction going inside previous rings, while another fraction goes into the holes between previously-placed rings. How the same algorithm produces such different apparent behavior is both its charm and its mystery.

In all cases (as shown elsewhere on this site) the algorithm is space-filling in the limit. If continued long enough it will achieve any assigned percentage fill. I have achieved >99.99% fill for 1D fractals.

For the "movie" of a circles fractal click here. (2.7 Mbyte)

For the "movie" of a squares fractal click here. (2.4 Mbyte)

For the "movie" of a rings fractal click here. (5.9 Mbyte)

For the "movie" of a foursquare fractal click here. (7.2 Mbyte)

John