harmonograph in processing

In resuming this blog, I’ve discovered a few draft posts that I first wrote a couple of years ago. Here’s the first in a series on harmonographs:

My first memory of harmonographs, although I didn’t realise at the time that that’s what they were called, is of watching Tony Hart on Vision On, using cones filled with either paint or sand and suspended from a pendulum that he would set swinging in two dimensions. (Unfortunately, I can’t find any video of that on the internet to show you what I mean.)

I was reminded of this a couple of years ago when I followed a link from William Latham‘s website to Karl Sims (though the link now seems to have changed to a visual effects software site), who has instructions on how to build a harmongraph. It’s a more complicated version than Tony Hart’s, but the principle is the same, and the sample images he provides are similar.

That got me wondering how to simulate a harmongraph in Processing. There are lots of simulations available on the net, but I wanted to create my own. I found the formula for one version at Paul Bourke’s amazing website, which has lots of information on things like Lorenz Attractors, which I’ve created here and here.

Here are a couple of images from my first attempt. I like the nearly-but-not-quite symmetry:

harmonograph002a harmonoharmonoharmonograph004aharmonograph004a

harmonograph004a

The concentration of lines towards the centre is the result of damping, which is a simulation of the pendulum gradually slowing down.

The main difference between virtual and physical harmomographs, of course, is that in the former you can note the values of variables that lead to particularly interesting results, and if desired repeat them. In contrast, the latter is completely hit-and-miss. Whether you think that’s a disadvantage or not depends on your point of view.

In my simulation, despite tweaking the values of the various parameters, I can’t find a set that results in anything wildly different. Strangely though, when I used very small values, I came up with this next image, which appears to have a wobbly, hand-drawn feel to it. I suspect this is the result of the relatively low resolution of the work, so that the plotted points are forced steps from one whole number to the next.

Tags: ,

Friday, November 15th, 2013 coding

Leave a Reply