Lesson goal: Acoustic beats and wave interference

Previous: Play a chirp | Home | Next: Harmonics and timbre

When two sound waves of almost the same frequency are played at the same time, a fascinating phenomenon occurs: you hear a single pitch whose loudness rhythmically pulses and throbs. This effect is known as acoustic beats.

Beats are caused by wave interference. As the two sound waves travel through the air together:
  • At certain moments, the high-pressure crests of both waves arrive at your ear simultaneously. They reinforce each other (constructive interference), creating a loud sound.
  • A fraction of a second later, the crest of one wave aligns with the low-pressure trough of the other wave. They cancel each other out (destructive interference), creating silence or near-silence.
Mathematically, the sum of two sine waves of equal amplitude can be rewritten using the trigonometric product-to-sum identity: $$\sin(2\pi f_1 t) + \sin(2\pi f_2 t) = 2 \cos\left(2\pi \frac{f_1 - f_2}{2} t\right) \sin\left(2\pi \frac{f_1 + f_2}{2} t\right)$$ This formula tells us two key things about what your ear perceives:
  1. The rapid oscillation occurs at the average pitch: $$f_{\text{pitch}} = \frac{f_1 + f_2}{2}$$
  2. The volume envelope pulses at the beat frequency: $$f_{\text{beat}} = |f_1 - f_2|$$
For example, if you play $440\text{ Hz}$ and $444\text{ Hz}$ together, you hear an average pitch of $442\text{ Hz}$ pulsating $4$ times every second ($|440 - 444| = 4\text{ Hz}$).

Musicians rely on this physical effect to tune instruments. As a guitar string or piano wire is adjusted closer to a reference pitch, the beat frequency slows down ($4\text{ Hz} \to 2\text{ Hz} \to 1\text{ Hz} \to 0\text{ Hz}$). When the throbbing stops completely, the instrument is perfectly in tune!
f1 = 440
f2 = 443

f_beat = math.abs(f1 - f2)

play_sines({
0.5, f1, 0.5, f2}, 4)
Move the mouse over a dotted box for more information.

  • Counting Beats: When the frequency difference $|f_1 - f_2|$ is between 1 and 10 Hz, your ear can easily count the distinct volume swells ("wah-wah-wah").
  • In Tune: When $f_1 = f_2$, the beat frequency is 0 Hz, resulting in a steady, smooth unison tone.
  • From Throbbing to Dissonance: When $|f_1 - f_2|$ exceeds roughly 15 to 20 Hz, the throbbing becomes too rapid for the ear to track as separate pulses, transforming into acoustic "roughness" and dissonance.

Now you try. Set f_string to 444, 442, 441, and 440 to hear the beats slow down and disappear as you come into tune.

Type your code here:


See your results here: