Binary Structures and Algorithms in Music
I recently found myself going down a lovely rabbit hole in the course of reading Marcus Aurelius’ Meditations, and came across this quote:
If all things performed the same role, it would be like an orchestra where every instrument played the same note continuously—there would be no movement, no creation. When different instruments play separate but harmonious parts, the result is a symphony.
Now, we could spend plenty of time unpacking the substance of what Aurelius was saying here, and I probably will in a journaling session. But when I saw the word symphony in an ancient text that predates anything we think of as a symphony by more than a thousand years, I began researching just what that word would have meant to people of Aurelius’ time and region. I found this:
The ancients emphasized:
This re-triggered my pursuit of connections between math/engineering and music. I remember the Pythagorean Theorem from my high school Geometry classes (a fond memory as it was actually pretty easy to grasp). And here his name comes up again in a very useful context!
What Are Pythagorean Ratios?
The Pythagoreans discovered that musical intervals could be expressed as simple whole-number ratios between frequencies. When two tones are played together and their frequencies are in a simple ratio, the result is perceived as consonant (pleasing to the ear).
These relationships are still foundational in music theory, acoustics, and tuning systems.
Musical Significance
1. Tuning Systems
2. Dissonance vs. Consonance
Mathematical Connections
A. Number Theory
B. Modular Arithmetic
Recommended by LinkedIn
C. Logarithms
D. Group Theory
Cognitive & Aesthetic Insights
As a guitarist, it makes sense to me, as we find octave harmonics at the halfway point of a string, and more complex harmonics as we divide the string further.
Halving String Lengths = Harmonics = Log₂(n) Structure
When you divide a vibrating string in half, you get an octave above the fundamental:
This mirrors how binary search works:
Computer Science Concepts That Parallel Harmonics
1. Binary Search and Octave Halving
2. Binary Trees and Harmonic Overtones
3. Fourier Transforms and Frequency Domain Decomposition
4. Logarithmic Encoding and MIDI
Let’s continue this thought process in my next article, which will demonstrate this important connection see how the binary search algorithm is actually musical in nature, and how we apply that algorithm subconsciously when we listen to music!
Dude - you've reached "Plaid' speed here! LOL Loving your big brain 🤘🏻