Layer multiple sine waves together and observe superposition, interference, beats, and harmonics in real-time with optional audio output.
Layer up to 3 sine waves and watch them combine in real-time. See constructive interference, beats, harmonics, and standing waves come to life. You can even hear them!
Superposition: When waves overlap, they add together. This is the fundamental principle behind sound, music, radio, and quantum mechanics. The red "Combined" line shows the sum of all active waves — this is what you'd hear or measure in real life.
A sine wave is the most fundamental waveform in mathematics and physics. Described by the function y = A sin(fx + φ), it represents smooth, periodic oscillation. Every sine wave is defined by three parameters: amplitude (A), which controls the height of the peaks; frequency (f), which determines how many cycles occur per unit of time or distance; and phase (φ), which shifts the wave left or right along the x-axis.
Sine waves are not just mathematical abstractions. They appear naturally everywhere: in the vibrations of a guitar string, the oscillation of a pendulum, the alternating current in household wiring, and even the electromagnetic waves that carry light and radio signals. Understanding how sine waves behave and combine is essential for physics, engineering, music theory, and signal processing.
When two or more waves exist in the same medium, they combine according to the principle of superposition: at every point, the total displacement equals the sum of the individual displacements. This simple rule produces rich and complex behavior.
When two waves of the same frequency are in phase (their peaks align), they produce constructive interference: the combined wave has double the amplitude. When they are exactly out of phase (one peaks while the other troughs), destructive interference occurs and the waves cancel. Try the "Destructive Cancel" preset above to see this in action.
When two waves have slightly different frequencies, they produce beats: a periodic pulsing in amplitude. The beat frequency equals the difference between the two wave frequencies. Musicians use this phenomenon to tune instruments by listening for the beats to slow down and disappear as two notes approach the same pitch. Use the "Beats" preset to hear and visualize this effect.
One of the most profound results in mathematics is Fourier's theorem: any periodic wave can be decomposed into a sum of sine waves of different frequencies (harmonics). A square wave, for example, is built from odd harmonics: the fundamental frequency plus the 3rd, 5th, 7th harmonics and so on, each with decreasing amplitude. The "Odd Harmonics" preset demonstrates the beginning of this construction.
Consider two waves: y₁ = sin(x) and y₂ = 0.5 sin(2x). At x = π/2:
At x = π/4: y₁ = sin(π/4) ≈ 0.707 and y₂ = 0.5 sin(π/2) = 0.5, giving y_total ≈ 1.207. The combined wave is richer and more complex than either individual wave.