| |
Flame Math
Scott Draves 3/6/2003
Iterated Function Systems
A kind of fractal.
Earliest example is Cantor's Dust (1882)
All base-3 numbers in [0,1] without a 1.
Sierpinski generalized to 2D set made of several copies of itself:
Used to model natural forms by Michael Barnsley (1980s)

Recursive Set Equations
S = U fi(S)
where
fi(x,y) = (ax+by+c, dx+ey+f)
where
fi are contractive.
How to Solve It?
If p is in S then fi(p) is in S.
And so is fj(fi(p)) and fk(fj(fi(p))).
And every point of S is arbitrarily
close to some sequence ijkl...
Algorithm I
draw point (x,y)
pick random i
(x,y) = fi(x,y)
iterate
Algorithm II
since maps are contractive,
any starting point moves toward
S exponentially. So just pick a
random start and drop the first
20 iterations
Flame
That was the state of the art in 1991.
I made three critical improvements:
- Generalized Functions
- Log Density Histogram
- Structural Coloring
Generalized Functions
fi(x,y) = V(ax+by+c, dx+ey+f)
V0(x,y) = (x,y)
linear
V1(x,y) = (sin x, sin y) sinusoidal
V2(r,h) = (1/r, h)
spherical
V3(r,h) = (r, 2h)
horseshoe
V4(r,h) = (r, r+h)
swirl
V5(x,y) = (h/pi, r-1)
polar
and V(x,y) = Sum wjVj(x,y)
where Sum wj = 1
The Genetic Code
up to 6 functions (xforms)
6 affine coefficients
7 variation coefficients
1 weight
6(6+7+1) = 84 dimensions
Log Density Histogram
Normal IFS algorithm: draw point, iterate.

The problem with that is there is information lost
every time you draw a point that has already been drawn.
The obvious solution is to increment a counter and
make the intensity of the image proportional to the
count. But this doesn't work!
Power Law
The problem is that the density distribution
follows the power law (frequency inversely
proportional to intensity): a few pixels are white
and the rest are left very dark, effectively black.
We want to visually distinguish 10 from 30 and
1000 from 3000 and 1000000 from 3000000.
So take a logarithm:

Color by Structure
We want continuous color gradation assigned structurally.
Naturally we want to use a color map, [0,1] -> (r,g,b)

Location in structure identified by our series
of choices for f: ijklmn, etc. Treat it as a
fractional binary number with most recent as high-order
bit. This is equivalent to adding a 3rd coordinate
to the fractal which is the color index.
|