Tag: john whitney
PyMotion is a framework for creating visual music based on John Whitney’s principle of “differential motion”. In differential motion, a set of identical elements moves along the same path with different speeds. If the first element moves at speed x, then the second element will move at speed 2x, the third at 3x, and so on. The result is motion with patterns that appear and dissolve at regular intervals.
For PyMotion, I used Python and PyGame, the Python port of the SDL library. I wrote the program in Leo, a literate programming editor that uses trees to structure code.
The framework of PyMotion is contained in the variable-speed ticker, and in the element-handling functions. The variable-speed ticker allows one to implement global accelerations and decelerations independent of framerate. The element-handling functions consist of functions to create arrays of elements in various configurations, and functions to move arrays of elements according to various rules.
- Straight line
- Along the perimeter of a circle
- Radially inward or outward while moving in a circle
- Sinusoidal oscillation
- Polar-coordinate rose motion, as described in John Whitney’s book, Digital Harmony
I used the framework to create one piece of visual music. I have not included screenshots because the heart of differential motion is motion, and screenshots do not adequately capture it. To view the piece on a Windows machine, download the zip file below, unzip it, and run pymotion.exe. To view the piece on any other machine, you will first need to install Python and PyGame. Then download the zip file, navigate to the /python/source directory, and enter python pymotion.py to run it.