Music, Mathematics, the Brain, and the Universe

未分類

Music, Mathematics, the Brain, and the Universe

Introduction

To enrich my life after retirement, I began practicing the piano seriously with a teacher about three years ago. In the process, I realized that music and mathematics are closely related and became fascinated by their depth. Furthermore, I have been deeply surprised to find that they are closely connected to my interests: neuroscience and cosmology.

In this essay, I attempt to share this wonder with all of you. It was sparked by the book “The Brain and Music” (by Kosuke Itoh), but I deepened my thoughts through deep dialogues with AI about the questions I had while reading.

I hope this sense of mystery and fascination reaches you.

Why are there 12 keys in one octave?

Generated piano concept

The piano keyboard we see every day—why is one octave divided into 12 keys, “7 white + 5 black”? The reason it’s “12” and not 10 or 15 is not merely tradition; it is a “coincidence” and “luck” of remarkable physical laws and number theory, and the “necessity” derived from them.

Let’s explore together the mathematical and physical principles of how scales are created.

The frequency doubles in one octave

The physical pitch of a sound is determined by the vibration frequency of the air. When the frequency doubles, the human ear hears it as “the same note, one octave higher.” Humans have likely known this since ancient times from the experience that halving the length of a string produces a note one octave higher.

Overtones also ring simultaneously when a string is plucked

Furthermore, when a single string is plucked, sounds with double, triple, quadruple frequency, and so on, ring simultaneously. These are called overtones.

A pure wave (sine wave) would not produce overtones. However, plucking a string deforms it into a triangular shape, which contains sounds of various frequencies besides the fundamental tone. But since both ends of the string are fixed, sounds cannot exist as standing waves unless their frequencies are integer multiples of the fundamental frequency. Therefore, overtones ring simultaneously.

Illustration of string overtones (internal labels)

The figure shows the fundamental vibration mode of a string and the 2nd, 3rd, and 4th harmonics.

When two notes ring simultaneously, beats occur at a frequency equal to the difference between their frequencies. These beats are the cause of dissonance. If the frequencies of two notes are sufficiently far apart, the direct beats are not audible, but the difference in frequency between overtones becomes smaller, and those beats can be heard.

However, if the frequencies of the two notes are in a clean integer ratio, the least common multiple is small, and the overtones overlap, so no beats occur and they sound harmonious. This is the principle of chords.

After 1:2, the simplest ratio is 2:3

A sound with the simplest frequency ratio of 1:2, twice the frequency, is one octave higher. The next simplest ratio is 2:3, or 1.5 times the frequency. This is called the “perfect fifth” and forms the basis of chords, sounding harmonious for the reasons mentioned above.

A perfect fifth above the note “C” (Do) is “G” (So). The frequency of G is 1.5 times that of C. Now, the question is how to create the other notes in the scale from there.

Pythagorean Tuning

Concept of Pythagorean tuning

The history of scales dates back to B.C. The ancient Greek mathematician Pythagoras investigated the relationship between music and mathematics and thought as follows:

“All things in the universe are numbers, and music is that numerical order made audible.”

Then, he created a scale that sounds mathematically beautiful. This is the “Pythagorean scale.” Mathematically, it’s a very simple principle.

  1. Determine a sound with 1.5 times the frequency of the fundamental note.
  2. Next, determine a sound with 1.5 times the frequency of *that* sound. That would be $1.5 \times 1.5 = 2.25$ times the frequency. Since an octave higher is 2 times the frequency, this exceeds one octave. So, halve the frequency to drop it down one octave. This gives $2.25 \div 2 = 1.125$ times the frequency.
  3. Repeating this process creates one new note after another.

Listing their frequency ratios in a table looks like this:

OrderNoteCalculationRatio
0CReference Note$1.0000$
1G$1 \times 1.5$$1.5000$
2D$1.5 \times 1.5 \div 2$$1.1250$
3A$1.125 \times 1.5$$1.6875$
4E$1.6875 \times 1.5 \div 2$$1.2656$
5B$1.2656 \times 1.5$$1.8984$
6F#$1.8984 \times 1.5 \div 2$$1.4238$
7C#$1.4238 \times 1.5$$1.0679$
8G#$1.0679 \times 1.5$$1.6018$
9D#$1.6018 \times 1.5 \div 2$$1.2014$
10A#$1.2014 \times 1.5$$1.8020$
11F$1.8020 \times 1.5 \div 2$$1.3515$
12High C$1.3515 \times 1.5$2.0273

Repeating this operation of creating notes in skips 12 times produces, amazingly, a note about twice the pitch of the starting note (frequency ratio approx. 2.0273), which almost matches the “C” one octave higher!!

This does not happen by necessity, but is a mathematical coincidence!

A remarkable mathematical coincidence

Why does taking a note and making it 1.5 times the frequency 12 times result in almost the same note as the starting one?

If we did not drop the note an octave every time it crossed the threshold, the frequency would become $1.5^{12}$ times. That value is $1.5^{12} ≒ 129.746$.

And since one octave is 2x, a note seven octaves up would be $2^7 = 128$.

These two numbers differ by only a factor of 1.0136.

$1.5^{12} ≒ 2^7$

This remarkable mathematical coincidence is what made 12-tone music possible!

Why are the 12 notes of the Pythagorean scale almost evenly spaced?

Let’s rearrange the notes of the Pythagorean scale in ascending order and list their frequency ratios and the ratio between adjacent notes.

NoteFreq. Ratio (Fract)Decimal Approx.Adjacent Ratio
C$1/1$$1.0000$
C#$2187/2048$$1.0679$$1.0679$
D$9/8$$1.1250$$1.0535$
D#$19683/16384$$1.2014$$1.0679$
E$81/64$$1.2656$$1.0679$
F$177147/131072$$1.3515$$1.0535$
F#$729/512$$1.4238$$1.0679$
G$3/2$$1.5000$$1.0535$
G#$6561/4096$$1.6018$$1.0679$
A$27/16$$1.6875$$1.0535$
A#$59049/32768$$1.8020$$1.0679$
B$243/128$$1.8984$$1.0535$
High C$2/1$2.00001.0535

The “High C” (C’) shown at the end of this table is mathematically $2.0273$, but it is treated as exactly twice the frequency to close the scale. Even so, the adjacent ratio of 1.0535 doesn’t show any major breakdown compared to the others.

Looking at this table, it’s surprising that by simply creating notes in skips of 1.5x frequency, the resulting scale is almost evenly spaced!

While the fact that 12 operations lead to almost the same note 7 octaves up is a coincidence, the fact that the 12 created notes are evenly spaced is a mathematical necessity.

Let’s consider why this is.

Visualizing with Geometry

As we’ll discuss later, it doesn’t return *perfectly* to the original note in 12 steps; there’s a slight error (the Pythagorean comma). However, let’s close our eyes to that for a moment and assume it returns perfectly after 12 steps.

The remarkable coincidence we mentioned earlier:

$1.5^{12} ≒ 2^7$

means that repeating the operation of making the frequency 1.5x for 12 times results in a note 7 octaves higher.

Let’s visualize that geometrically as follows:

Spiral structure of music: pitch height and pitch class

As shown in the diagram:

  1. Assume one rotation of the circle represents one octave.
  2. A note one octave higher is recognized as the “same note,” but its frequency is doubled, so it’s vertically higher in a spiral.
  3. Let’s apply the process of “multiplying the frequency by 1.5 (creating a perfect fifth above) 12 times” to this diagram. Since $1.5^{12} ≒ 2^7$, we will rotate exactly 7 times around the spiral and return to almost the same vertical point directly above C (Do).

Looking from directly above, we rotate 7 times around the circle in 12 operations, so each operation moves $7/12$ of the circumference. Each time we move $7/12$, we plot a point. The fact that the Pythagorean scale is evenly spaced means that from above, these 12 points are equidistant on the circumference. It’s easier if you imagine moving the hour hand of a clock forward by 7 hours each time.

Why Jumping in Fifths Creates an “Equidistant Staircase”

Repeating 1.5x for 12 times results in almost $2^7$. The mathematical secret of the evenly spaced scale lies in the fact that 12 and 7 are coprime (having no common divisor other than 1).

Imagine a circle. Plot a point at the starting position.

What happens if you repeat the action of “moving clockwise by 7/12 of the circumference and plotting a point” 12 times?

1. The circle “closes perfectly” on the 12th step

Adding $7/12$ twelve times results in exactly 7.

This means “completing exactly 7 revolutions and returning to the starting point without the slightest deviation.”

2. “Coprime” ensures unique visits

What’s important here are these two points:

  1. The points plotted by moving $7/12$ are, by definition, at one of the 12 evenly spaced locations on the circle.
  2. 7 and 12 are coprime (no common divisors other than 1).

Because of this, you will never land on a point you’ve already plotted until you return to the starting position on the 12th step.

3. Why does it end up being “equidistant”?

We didn’t deliberately plot points on a circle divided into 12. We simply plotted points every 7 steps on a circle of 12.

However, when you look at the whole circle after you’re done, all the points are equidistant. Why do points plotted in skips end up even?

Conclusion: Filling “Equidistant Seats” in Random Order

The principle is that if there are 12 seats and 12 people sit without sharing a seat, everyone will end up with exactly one of the 12 seats.

The “7/12 step” was just a rule to reserve the 12 equidistant seats in a seemingly random order. Since 7 and 12 are coprime, all 12 seats were filled without duplication after 12 steps.

Thus, as a result of repeating “big jumps” of fifths, we are left with a beautifully aligned equidistant ring of “Do, Re, Mi…”.

This geometric image of “returning to the original position after 7 revolutions” is the essence of the mathematical beauty of the 12-tone scale being both closed and equidistant.

Actually, this isn’t limited to 7/12; moving by any irreducible fraction of the circumference will return you to the origin after the number of steps equal to the denominator, and the points will be equidistant.

The Circle That Never Closes

The Unavoidable “Pythagorean Comma”

However, there is a cruel mathematical fact. We have ignored it so far, but in reality, no amount of multiplying by $1.5$ will ever perfectly match a power of $2$ (octave).

As $1.5^{12} ≒ 2^7$ shows, it’s only $≒$ (approximately equal), not $=$ (strictly equal).

The world of sound is, strictly speaking, a “non-closing circle” that never returns home no matter how far you go. By turning a blind eye to this slight error (the Pythagorean Comma), we defined the scale as a circle with “$12$ nodes.”

Accumulated Error Explosion: The Wolf’s Fifth

If you strictly follow Pythagorean math, the accumulated error explodes at the $12$th “fifth.” A specific fifth interval produces an unpleasant beating. People of the time called it the “Wolf’s Howl (Wolf’s Fifth)” and dreaded it.

Concept of Wolf's Fifth

It’s no exaggeration to say that the history of music is a history of how to handle this Wolf’s Howl.

Where Does the Wolf Lurk?

If you repeat the operation of multiplying the frequency by $1.5$ and then multiplying by $1/2$ to bring it back into the octave if it exceeds it, after $12$ times, the frequency ratio becomes $2.0273$ times. We must force this to be exactly $2$. Therefore, only this final step fails to reach a ratio of $1.5$ and becomes $1.4798$ instead. This is the Wolf’s Howl.

Pairs of $1.5x$ JumpLower Note (Ratio)Higher Note (Ratio)Actual Ratio
C → G$1.0000$$1.5000$$1.5000$
G → D$1.5000$$1.1250$$1.5000$
D → A$1.1250$$1.6875$$1.5000$
A → E$1.6875$$1.2656$$1.5000$
E → B$1.2656$$1.8984$$1.5000$
B → F#$1.8984$$1.4238$$1.5000$
F# → C#$1.4238$$1.0679$$1.5000$
C# → G#$1.0679$$1.6018$$1.5000$
G# → D#$1.6018$$1.2014$$1.5000$
D# → A#$1.2014$$1.8020$$1.5000$
A# → F$1.8020$$1.3515$$1.5000$
F → C$1.3333$$2$$1.4798$

The problem is that the notes of this final step are F and C. F and C are extremely frequently used notes. If the Wolf’s Howl occurs here, the most common basic keys like F major or C major would become unbearable to listen to, which is a disastrous situation where the entire system becomes useless.

Therefore, historically, instead of simply proceeding up the spiral staircase of the scale $12$ times, humans used a clever trick: spreading the tuning in both directions from the reference C and the upper C.

Starting from the top of the table below, up to the $5$th step are only white keys. F# and C# appearing in the $6$th and $7$th steps were often used in Baroque music, so we want the scale to be perfect around here. On the other hand, coming up from the bottom of the table, the $12$th step is a white key, and it becomes a black key from the $11$th step. Thus, the idea was to make the $8$th or $9$th step, where both directions meet, the seam. Consequently, the Wolf’s Howl was moved to the gap between G# ($9$th) and Eb ($10$th).

No.Pair of 5thsDirection of GenerationRatio
1C → GUpward from Ref. C$1.5000$
2G → DUpward$1.5000$
3D → AUpward$1.5000$
4A → EUpward$1.5000$
5E → BUpward$1.5000$
6B → F#Upward$1.5000$
7F# → C#Upward$1.5000$
8C# → G#Upward$1.5000$
9G# ↔ EbClose the circle here1.4798 (Wolf)
10Eb ← BbDownward$1.5000$
11Bb ← FDownward$1.5000$
12F ← High CDownward from High C$1.5000$

🐺 Wolf’s Fifth Experience Simulator

Let’s compare how the Wolf’s Howl sounds using the simulator below. If you’re used to music that intentionally uses dissonance as an accent, like jazz, it might sound surprisingly “cool.”

Left is a pure perfect fifth ($3:2$), right is the final gap when closing the circle in Pythagorean tuning.
Compare the difference in the “beat” (interference).
If no sound plays on your smartphone, please disable silent mode.

Normal Perfect Fifth (Pure)
G# ↔ Eb
A perfectly harmonious ratio of $3:2$. Because the wavelengths match exactly, it results in a clear and beautiful resonance without stagnation. Ratio: 1.5000
Wolf’s Fifth (Pythagorean)
G# ↔ Eb
Significantly deviated from the original $1.5x$, it produces a violent “wah-wah” beating sound like a wolf’s howl. Ratio: 1.4798

Bach’s Temperament — Engineering that Turns Error into Beauty

No matter how much you push the Wolf to the outskirts, playing in certain keys where the Wolf lurks (such as E-flat major) would result in unbearable dissonance. In other words, there were physical “prohibitions” stating, “This piece must not be played in this key.” How to handle this was the greatest engineering challenge in music history.

The one who accomplished this was J.S. Bach!!

Mandala symbolizing J.S. Bach and temperament

He was not only a great composer but also, surprisingly, well-versed in harpsichord tuning. Relying on his own ears and musicality, he smoothed out the “Wolf’s Howl” across the entire scale so that every perfect fifth chord would sound equally beautiful. The scale created this way is known as “Well Temperament.”

Bach discarded the extreme Pythagorean system of “11 notes at 100 points, 1 note at 0 points,” and performed an optimization to “make everything 90 points (or change the character slightly depending on the key).”

What he practiced was not the perfectly uniform “Modern Equal Temperament,” but an exquisite tuning that “enabled playability in all 24 keys while preserving the individual character of each key.”

  • C Major: Minimal error, resulting in a crystal-clear resonance.
  • F# Major: Errors intertwine complexly, creating a tingling, tense resonance.

For Bach, “Well Temperament” was not about erasing individuality, but “a passport for traveling freely through the universe of all keys.”

Bach didn’t just invent Well Temperament; he created “The Well-Tempered Clavier” to demonstrate its brilliance. He personally composed 24 pieces (in two volumes) to prove that “if you use an instrument with Well Temperament, you can create music in all 24 types of keys without any bugs!” This collection, known to every piano student, carries such immense historical significance.

Listen to “Prelude No. 1” from The Well-Tempered Clavier!

A Composition that “Touches” All 12 Semitones

This piece primarily journeys through the related keys of C major and returns. What is noteworthy is that within this short two-minute piece, broken chords (arpeggios) based on all 12 semitones within an octave as the root (root note) appear one after another.

  • In Pythagorean Tuning: When reaching chords involving black keys (such as F# or Ab), the Wolf’s Howl would mix in, making the resonance “dirty.”
  • Bach’s Intention: By intentionally sequencing complex chords that frequently use black keys, he is proving to the ear, “See, with Well Temperament, no matter what note you use as the root, it sounds this smooth and clear.”

Passing Through the Dangerous Wilderness Where the Wolf Once Lived

This Prelude No. 1 consists entirely of arpeggios. There is no melody line; the resonance of the chords themselves is the protagonist.

While seemingly simple, very complex resonances enter in the middle, deviating significantly from the world of C major. By intentionally passing through these “unstable places” (the dangerous regions where the Wolf once lived) and brilliantly returning to C major at the end, the listener is given a sense of having “traveled the universe and returned.”

Bach is truly amazing!!

Modern Equal Temperament: Perfectly Smoothing the Wolf

So, how are modern instruments tuned?

Thanks to scientific progress, we no longer need to tune by ear and intuition like Bach did. Using a tuner, we can perfectly match the frequency ratios of all 12 scales. This is Modern Equal Temperament.

In Modern Equal Temperament, one octave (a frequency ratio of 2) is divided into 12 exactly equal parts, so the frequency ratio of each scale is exactly $\sqrt[12]{2} \approx 1.059$.

Why Does it Sound Beautiful Despite Non-Integer Ratios?

In Modern Equal Temperament, the frequency ratio becomes an irrational number $\sqrt[12]{2}$, so no chords can ever result in clean integer ratios. Therefore, technically, not only perfect fifths but *all* chords should not sound perfectly beautiful. Yet, they do. Why is that?

The brain has the ability of “Pattern Recognition,” where it compensates for incomplete information based on past experience. When the brain hears the slightly deviated perfect fifths of Modern Equal Temperament, it interprets them as “the ideal perfect fifth resonance” and corrects them internally. It can be said that we are not listening to music with our ears, but reconstructing and enjoying it within our brains.

Come to think of it, I’ve had many experiences playing the piano where certain chords I initially thought sounded strange began to sound beautifully harmonious after a while. There are also many cases, like in jazz, where dissonance is used intentionally as an accent.

Is it the same sensation as how coffee, which felt so bitter as a child, or beer, which was too bitter to drink when I first started, now tastes delicious?

Oops, I shouldn’t be talking about beer to high school students, should I? 😀

The Anthropic Principle and Music — A Brain that Loves Cosmic Distortion

Music became possible because $1.5^{12} ≒ 2^7$ holds true, and that slight error was within a range the brain could tolerate and even accept as an appropriate accent. It was an exquisite balance.

And because the number $12$ was just easy enough to handle (easy to divide and a manageable size), the white and black keys of the piano could be arranged beautifully, and one octave fits within the reach of a hand.

As I wrote before: “The amazing mathematical coincidence of $1.5^{12} ≒ 2^7$ is what made 12-tone music possible!!”

But is this really a coincidence? Don’t you think it’s almost too convenient to be true?

I felt a deep connection here with modern cosmology.

The “Anthropic Principle” in Cosmology

In cosmology, there is an intriguing concept called the “Anthropic Principle.” It’s a philosophical idea focusing on the fact that “the physical laws of the universe (such as the strength of gravity and the mass of elementary particles) are almost too convenient for the birth of life.”

There are two primary interpretations of this principle:

  • Weak Anthropic Principle: Countless universes exist (the multiverse), and only in a universe where conditions happened to be right for intelligent life to emerge can beings like us exist to “observe” it. It’s a pragmatic approach suggesting that because we are here to observe, it’s natural that conditions look favorable.
  • Strong Anthropic Principle: A more profound idea suggesting that the universe was “designed to give birth to intelligent life.” This approach often assumes a god or a creator.

The Musical Anthropic Principle

Looking back at our discussion, don’t you feel as though mathematics was designed such that beautiful music could be born? If $1.5^{12} ≒ 2^7$ weren’t true, beautiful music might never have existed.

And even that “slight error (the Pythagorean Comma)” was at an exquisite balance where the brain, through centuries of effort and correction, could complement it as “pleasant tension and release.”

The “near-perfect harmony” within music and mathematics, the epic 2000-year human endeavor to smooth over that slight gap, and the brain’s activity to interpret that remaining gap as an accent of beauty—all of these are connected.

Behind the true beauty of music lies a grand “Musical Anthropic Principle” and the history of human endeavor.

Conclusion

Conceptual diagram showing the connection between music, mathematics, the brain, and the universe

“Music, Mathematics, the Brain, and the Universe” — seemingly unrelated, yet actually linked in a deep and incredibly grand story. Did I manage to convey this to you? By organizing this essay, I was able to clearly verbalize things I had only vaguely understood and resolve my own questions.

This essay was born from my deep dialogue with Gemini (an AI), based on the book “The Brain and Music” (by Kosuke Itoh). Furthermore, I utilized Antigravity, Google’s AI agent, for the actual writing process. The beautiful illustrations throughout the text were also drawn by AI (Gemini/Nano Banana).

The English translation was completed by Antigravity in about 10 minutes.

Music, Mathematics, the Brain, and the Universe are all amazing, but AI is pretty amazing too!

Recommended Reading:
“The Brain and Music” by Kosuke Itoh (published by Kinokuniya Shoten)

Reference: Original Japanese Article

[my_youtube_embed url=”https://www.youtube.com/watch?v=MsuvL-EghX4″]

コメント