Waves
Beats
Two close-frequency waves create rhythmic loud-soft pattern at the difference frequency
When two waves of slightly different frequencies superpose, the result alternates between constructive and destructive interference at the DIFFERENCE frequency — creating audible "beats." Sounds like a wavering loudness. Used by musicians for precise tuning, in radio (heterodyne detection), and in ultrasound mixing for various detection schemes.
- Beat frequencyf_beat = |f₁ − f₂|
- Carrier frequency(f₁ + f₂) / 2
- OriginSum-to-product trig identity → AM-like envelope
- Audible beatsf_beat < ~10 Hz (perceived as throbbing)
- Tuning useMatch instrument to reference until beats vanish
- HeterodyneSame physics — combine signals to get sum/difference frequencies
Interactive visualization
Press play, or step through manually. The visualization is yours to drive — try it before reading on.
Watch the 60-second explainer
A condensed visual walkthrough — narrated, captioned, under a minute.
The math
Two waves of frequencies f₁ and f₂ (close in value):
y₁ = A·cos(2π·f₁·t)
y₂ = A·cos(2π·f₂·t)
y_total = y₁ + y₂ = 2A · cos(2π · (f₁+f₂)/2 · t) · cos(2π · (f₁-f₂)/2 · t)
Interpretation:
- First factor — fast oscillation at average frequency.
- Second factor — slow envelope at half the difference frequency.
- Each cycle of envelope has two "loud" moments → beat frequency = |f₁ − f₂|.
Examples
| Setting | f₁, f₂ | Beat freq |
|---|---|---|
| Tuning fork at 440 Hz; instrument at 442 | 440, 442 Hz | 2 Hz (slow throbbing) |
| Two pianos playing same note slightly out | ~250-260 Hz | 5-10 Hz |
| Twin engines almost in sync | ~30 Hz, ~31 Hz | ~1 Hz |
| Heterodyne receiver | ~1 GHz, ~1.001 GHz | 1 MHz (intermediate) |
| Two violin strings tuning to A4 | ~440, ~439 | 1 Hz (slow → adjust pitch) |
JavaScript — beats
// Generate beat pattern
function beatPattern(f1, f2, t) {
return Math.cos(2 * Math.PI * f1 * t) + Math.cos(2 * Math.PI * f2 * t);
}
// Beat frequency
function beatFrequency(f1, f2) {
return Math.abs(f1 - f2);
}
// Tuning two strings: 440 and 442 Hz
console.log(`Beat: ${beatFrequency(440, 442)} Hz`); // 2 Hz
// Detect beats in waveform (find envelope maxima)
function findBeats(f1, f2, duration_s = 1, sampleRate = 8000) {
const samples = [];
const dt = 1 / sampleRate;
for (let t = 0; t < duration_s; t += dt) {
samples.push(beatPattern(f1, f2, t));
}
// Find envelope by checking absolute amplitude over short windows
// (For demo; would use FFT or hilbert in practice)
return samples;
}
// Tune by minimizing beats
function tuningProcess() {
const target = 440;
let current = 445;
while (Math.abs(current - target) > 0.5) {
const beats = beatFrequency(current, target);
console.log(`Current ${current.toFixed(1)} Hz, beats: ${beats.toFixed(1)} Hz`);
if (beats > 0.1) {
current -= 0.5; // tighten string slightly
}
}
console.log('Tuned!');
}
// Heterodyne: sum and difference
function heterodyne(f_signal, f_local) {
return {
sum: f_signal + f_local,
difference: Math.abs(f_signal - f_local)
};
}
console.log(heterodyne(1.001e9, 1e9)); // sum 2.001 GHz, difference 1 MHz
Where beats matter
- Music. Tuning instruments — listen for beats, tighten/loosen until they vanish.
- Radio. Heterodyne receivers — beat received signal against local oscillator for processing.
- Oscilloscope. Aliased waveforms produce beat-like patterns when measured rate close to signal rate.
- Optics. Interferometry detects path differences via beat patterns of recombined laser light.
- Sonar/radar. Doppler-shifted returns beat against transmitted signal — measure target velocity.
- Engineering. Vibration analysis — beats indicate component mismatches; useful for diagnostics.
- Education. Demonstrates wave superposition; auditory illustration of physics.
Common mistakes
- Confusing beat with combined frequency. Beat = difference. Combined oscillation has average frequency. Different things.
- Believing both frequencies must be equal. Beats happen because they're DIFFERENT (slightly). Equal frequencies → no beats (just steady amplification).
- Treating beat frequency as f_envelope. Envelope at (f₁-f₂)/2. But each envelope cycle has two loudness peaks → beat frequency = |f₁-f₂|.
- Forgetting nonlinear effects. Real systems may have intermodulation distortion — sum/difference frequencies created beyond simple beats. Important in audio amplifiers.
- Using beats for very different frequencies. If f₁ - f₂ > ~30 Hz, you don't hear beats — you hear separate notes plus a third "combination tone." Beats are for close frequencies.
- Confusing beats with interference patterns in space. Beats — temporal interference (single point, varying time). Interference fringes — spatial interference (single moment, varying position). Same superposition principle, different geometries.
Frequently asked questions
Why do beats happen?
Two close-frequency waves superpose. At some moments they're in phase (both peaks add), at others out of phase (cancel). The result mathematically: cos(2πf₁t) + cos(2πf₂t) = 2·cos(2π·(f₁+f₂)/2·t) · cos(2π·(f₁-f₂)/2·t). First factor — fast oscillation at average frequency; second — slow envelope at HALF the difference frequency. Listener hears one cycle per envelope max, so beat frequency = |f₁ − f₂|.
How are beats used to tune instruments?
Play one note alongside reference (tuning fork, electronic tuner). If notes are close but not equal, you'll hear beats. Adjust pitch to slow the beats — they vanish when frequencies match exactly. Pitch precision: 1 Hz beats means within 1 Hz of target. Skilled tuners can detect 0.1 Hz beats.
Why do you hear DIFFERENCE not the actual difference frequency?
Mathematically: f_beat = 2 × (f₁-f₂)/2 = (f₁-f₂)? Half-frequency envelope, but the loud-quiet cycle is twice per period. So you HEAR (f₁-f₂) Hz beats. (Confusing — exactly what's "perceived" depends on how you count cycles.)
What's heterodyne detection?
Mix incoming signal with local oscillator at slightly different frequency. Output: sum and difference. Difference is in audio range (or whatever's convenient). Used in: AM radio receivers (intermediate frequency), radar, optical interferometry, signal processing. Beat physics applied to electronics.
Can beats happen with any waves?
Yes — sound, light, radio, water waves, etc. Sound — most familiar (audible beats). Light — beats happen in laser physics; "optical heterodyne" detects tiny frequency differences. Radio — superheterodyne receivers use beats for tuning. Water waves — visible beats when two wave trains interfere.
What's the difference between beats and amplitude modulation?
Mathematically equivalent to AM. AM radio carrier (e.g., 1 MHz) modulated by audio (~kHz) — same as two close-frequency carriers (carrier ± modulation freq). Demodulating AM is essentially detecting beats. Different perspectives on same math.
How fast can beats become?
Below ~10 Hz, you hear distinct loud-quiet cycles ("throbbing"). Higher beat frequencies become "rough" then ill-defined. Above ~30 Hz, beats sound like a separate low pitch (combination tones). Brain integrates → different perception at different beat rates. Two sopranos singing close notes at 100 vs 105 Hz: 5 Hz beats. At 1000 vs 1100 Hz: 100 Hz beats — barely audible as separate.