A Python project I did while bored one day.

The original intent was to have the output be the final animated gif file, but I never finished that aspect and just used GIMP to compile the stills.

The idea was just to have sine waves that emanated from given points and be able to accurately display the waves and in the case of multiple origins, the interference patterns.

Just think of them as being seen from above, white being crests and black being troughs. Now, this was around the same time as the Voronoi images so no surprise that different metrics where on my mind. I did the normal Euclidean distance but also threw in my favourite alternate metric, Manhattan distance.

So, some typical examples follow. These are the same sine waves, same amplitude, frequency and velocity, just different metrics.

So, there are nine rectangles in that last image. Look at the centre one and compare it to the same region on the Euclidean distance version just above it. The upper right and lower left corners of that middle rectangle are the origin points of our waves.

So, consider the upper right corner of that centre rectangle. A horizontal line through that point right across the image and also a vertical line through that point divide the image into locale regions of behaviour.

We have the grey, never too dark never too light diagonal line group extending off to the upper right. Also a checkerboard pattern of squares with fuzzy edges extending away to the lower right and upper left of that point. Finally, as far as that point is concerned, we see the rectangle with the two wave origin points describing two opposite corners has an interference pattern of diagonal lines between which are a set of linear standing waves.

There are also the upper left and lower right regions, which have no edges that touch a wave origin point. Neat features there to notice are how the dark bands and light bands match with the checkerboard regions. Thinking about the math here it’s not surprising. In fact none of the behaviour of this image is surprising after looking at it and thinking about it for a bit. In advance though, I had no idea what to expect.

I first produced still images, and found them intriguing enough to make a first animation. Looking at it at first I found it neat and strange. Thinking about it for a bit it started to make a lot of sense. I was able to notice all sorts of features, including many that I haven’t mentioned above at all. A simple change and suddenly I could look back at the standard circular interference patterns above and see those had corresponding regions, but they didn’t jump out visually like they do here. You can now look back at the circular versions above and notice that yes, there are sub-regions of behaviour that do map up, but they transition so slowly you probably missed them before.

I was just playing around when I made these, but I ended up learning a bit more about waves as a result. It shows how math is like drawing or painting. Sometimes when you draw or paint you should rotate your canvas 90 degrees then look at it. Little mistakes or areas that need attention suddenly jump out from this changed perspective. You end up with a far better final work for having taken just those few minutes to change your perspective. It’s true in art, in math, and just in life in general.

There, you even got a greeting card sentiment at the end.