Play two notes that are almost the same pitch and something strange happens: the combined sound doesn't just blur together — it pulses, swelling loud and fading soft, loud and soft, a slow wah‑wah throb. That throb is a beat, and its rate is exactly the difference between the two frequencies. Bring the pitches together and the beats slow to a halt — that silence-of-throbbing is what "in tune" sounds like.
Two pure tones at f1 and f2 are drawn below, and beneath them their sum. Where the two waves momentarily line up the sum is loud; where they fall out of step they cancel. That rise-and-fall is the beat envelope, and it repeats |f1 − f2| times a second. Press play and listen.
This is exactly how a piano tuner works. A fixed reference tone sounds against a string you adjust. When they're close you hear beats; tune the string until the beats vanish and you're dead on. The fewer beats per second, the closer you are — counting beats lets you tune far more precisely than judging pitch directly.
Add two sines of nearly equal frequency and trigonometry splits the result into two factors: a fast carrier at the average frequency, multiplied by a slow envelope at half the difference. The carrier is the pitch you hear; the envelope is the swelling loudness.
The envelope itself wobbles at |f1−f2|⁄2 Hz — but loudness peaks at both the positive and negative bulges of that cosine, so the ear hears twice as many swells: a beat rate of exactly |f1−f2|. The animation below shows the carrier (fast) riding inside the envelope (the glowing outline).