Box Counting Approximation Algorithm
When I initially decided to examine EEG’s of the brain, I designed
a box-counting approximation algorithm to see if I could get the same results
as the authors, but I was unable to find suitable images to test it on.
Nevertheless, here is the algorithm. It counts the number of q*q
boxes that are needed to cover the set, and compares that to 1*1 boxes
(pixels), using the formula ln(N(boxes of size 1)/N(boxes of size q))/ln(q).
Black pixels were taken to be in the set, and pixels of all other colours
were classed as not being in the set. The algorithm was tested by
creating two iterated function systems that displayed the Sierpinski Gasket
and the Sierpinski Carpet. These have known box-capacity dimensions
of ln(3)/ln(2)=1.585 and ln(8)/ln(3)=1.893 respectively. I found
that taking q to be 2, so that boxes of size 2*2 and comparing those to
the number of actual pixels in the set gave the best approximation.
This gave dimensions of 1.564 and 1.855 respectively. Strangely enough,
though, when I tested it with the standard Mandelbrot Set and the Mandelbrot
Set of f(z) = c*z*(1-z) where z is iterated on 1/2 (that we plotted for
assignment 4), these sets resulted in box-counting dimensions of 1.95 and
1.96, implying that they did not have fractional dimension, and that they
have a dimension of 2 (taking into consideration that the values are not
exact). Yet zooming in on the standard Mandelbrot set resulted in
great variety in the box-counting dimension: whether this is from
the inaccuracy of my program or whether it is a property of the Mandelbrot
set itself is unknown.
To view corresponding images, click here.
Go Back