Late in May of the year I was in forth grade we were given a map of the United States and Canada with outlines of the states and provinces. Our task was was to correctly label it with capital names and rough locations along with the names of states and provinces. We had a few for practice and the shapes caused my mind to wander.

States like Kansas, Colorado and Wyoming, were boring rectangles. Or were they? The supposedly parallel lines on the East and West would converge on the North Pole. My Dad had had this neat little mechanical map measuring tool. You'd zero it and then mechanically trace out a path and write down how many millimeters it had gone (his was German and labeled in millimeters). Then you'd look up the scale on your map and convert to miles or kilometers. I quickly learned the school maps weren't very good and started playing with road maps from the gas station. In the day you'd pull up and have someone pump your gas, clean your windows, check your oil and water and tire pressure and then pay about thirty cents a gallon for the gasoline. They had a pile of maps for the asking. I had a nice collection.

These were better, but didn't answer my basic question. I was starting to wonder what represented ground truth. If you're admiring the Slartibartfast's crinkly edges of Norway you have to wonder about scale. From space there may not be as much detail as from an airplane and you will get somewhat different results. Down to ground level, where you can easily measure in centimeters rather than meters, it's much more complicated and is now dynamic with forces like the tides, continental drift, erosion and so on. Where you do draw the line, so to speak?

At about the same time I was getting boggled, Benoit Mandelbrot was investigating fractal geometries. He was something of a polymath and the only person I've met whose personal style included a piece of fresh broccoli in his suit pocket. He loved self similar shapes.. A lot of math is just drawing things to see what's going on - a neat little example is the Koch curve. Draw an equilateral triangle and the add three a smaller triangle with a sides a third the length of the original. Now place each midway on the original triangle with so they're pointing out and just keep the shape along the outside boundary (you may want to think of cutting them out of paper and just using the outer edge.) Now it looks like a Star a David, but you've just started. Add new even smaller triangle along each of the edges of the Star of David and you start to get a snow flake. Keep going. (a computer may be useful:-)

The edges are much more complex that anything smooth like a line or a circle. Mandelbrot and others came up with a way to assign a dimension to any shape. A line has one dimension, a plane has two, the space we're used to has three and math is just getting warmed up. The Koch curve has a dimension of 1.2619. The definition give 1.0 for lines and 2.0 for planes, but is also a way to talk about complexity and repeating complexity.

Just in case someone asks, the dimensionality of the Southern Norwegian coastline is about 1.3. The Southwestern coast of Britain is very close to 1.25.

Drawing these curves by hand or computer could and should be taught in middle and high school because it's playful. Understanding how to calculate dimensionality of these shapes would take too long for me to describe, but I think it could be done as part of a high school calculus class. Playing with these concepts builds your tool kit. A tool kit that allows you to stitch seemingly unrelated concepts together.

Our brains are remarkably "plastic." If you push them with new mental activities they rewire so as to become more efficient. Profoundly deaf people use some of the brain normally associated with sound to increase their visual acuity. Musicians enhance regions of their brains and the mental component of many sports leads to very measurable changes. If you work at several different things your wiring may become uniquely creative - I suspect some of the most creative athletes spent a lot of time studying an instrument at some point. These enhancements are readily seen in brain scans even in people in their sixties. It's easy to measure the changes even in people who are in their sixties. You can teach old dogs new tricks. (this is such a rich area, but back to the equally rich math)

What if you wanted to help a blind person by encoding the information from a camera in sound? How would you approach the prolbem?

To get an idea of what's going on I take a very simple picture.. in this case 256 pixels on a side. I start with my avatar. (pretend it's 256 x 256... this one is twice as large) I make it black and white.. 256 grey levels in this case. I don't know what to do with more detailed information... I'm just dinking around a bit with the problem.

How to present this to the brain? Don't worry if this would actually work - just consider it a little thought experiment. We could associated each pixel had a frequency? The loudness could be associated with the brightness. In this case white could be very quite and black the loudest. You might play them all at once, but it might be too confusing.. Try adding a bit of order. The question is what kind of order? (again. . there are smarter ways to do this - you may be thinking of some now, but let's work on this one)

It could be some randomly chosen ordering. After all, the brain is good at finding order in a mess.. as long as we use the same random ordering. But that presents a problem.. what if we use a better camera.. like 3000 x 4000 pixels? Then we need a new random ordering and the brain has to start all over again.,

There is raster scanning .. like an old CRT ... you move back and forth t across the image starting at the bottom and shifting up a pixel each time you reach an edge reading the brightness of each pixel you encounter until you've scanned the whole image. Simple but it throws away some good intuition. An image tends to have a lot of neighboring similarity. It would be nice to make use of that. Hang onto that thought for awhile.

A mathematician might suggest you consider a Hilbert curve - more specifically a Pseudo-Hilbert curve. Rather than get impressed by the fancy name we'll drop the pseudo and just play around. Take out a sheet of paper and draw a square. (line 1 in the figure) Now divide the square into equal quadrants. Starting in the lower left quadrant, draw a line up to the upper left quadrant, continue to the upper right quadrant and then down to the lower right quadrant. This upside down U is an Order One Hilbert curve. Now it's time to make it work. (line 2) Draw another square with four quadrants. Now draw an Order One curve in each of the quadrants. Start traveling from the lower left and you find yourself making some unfortunate traverses. Is there any way to rearrange these Order One curves to get something that doesn't intersect itself?

It turns out there is. (line 3). Rotate the curve in the lower left quadrant 90° counter clockwise and it's neighbor in the lower right quadrant 90* counter clockwise. Now you can connect all four Order One curves into something that doesn't cross itself - an Order Two Hilbert curve. You can probably guess the algorithm from here. To draw the next order draw your current order Hilbert curve in each of four quadrants of a square. Rotate the bottom left curve 90° clockwise and the bottom right 90° counter clockwise. Connect them and you're done.

Now that you've got the recipe you can draw Hilbert Curves of any order your patience allows.. Past four and it's best to use a computers. Here are Orders One through Five

There are two things to notice:

First the curve is covering more points of the square as the order increases. We can talk about it's dimension. As the order goes to infinity, the curve's dimension is 2.0 ... in other words the curve hits every point inside the square. How sweet - an infinite one dimensional object that covers two dimensions. Our job is much easier - we're using pixels and only require the line to go through a pixel.

Second, the curve preserves localized information as the order of the curve goes up. Look at the nose of my ferret. If I stretch out the curve the points associated with the nose are roughly in the same region of the line. This is useful if our blind person is listening to the string of notes coming out. Most of them around the nose have a similar value and are played at nearly the same time. If we use a camera with more pixels that local nature is still preserved. The raster scan that snakes up the image don't preserve locality.

There are many uses for these locality preserving mappings (as they're called) and space filling curves like the Hilbert Curve are just what the doctor ordered. And you don't have to stop with one dimension. They may get hard to visualize, but the technique works with as many dimensions as your heart desires.

Math is useful for calculating, but more important is the fact it's a playground that offers insight and new ways of thinking. It is one of the glues of creativity.

## Comments

You can follow this conversation by subscribing to the comment feed for this post.