🔊 Doppler Effect

| | |
f₀ = 440 Hz  |  v_src = 30% v_sound  |  f′ ahead = 629 Hz  |  f′ behind = 327 Hz  |  Mach = 0.30

🔊 Doppler Effect Simulation

Interactive simulation of the Doppler effect. Watch wavefronts compress ahead of a moving source and stretch behind it. Cross the speed of sound to see a Mach cone form.

🔬 What It Demonstrates

A moving source emits wavefronts at equal intervals, but because the source moves between emissions, the fronts bunch up ahead (higher frequency) and spread out behind (lower frequency). At Mach 1, fronts pile into a shock wave — the sonic boom.

🎮 How to Use

Adjust source speed and wave frequency. Add a second stationary observer to compare received frequencies. Push the speed past Mach 1 to see the Mach cone angle decrease as speed increases.

💡 Did You Know?

The Doppler effect applies to all waves. Police radar uses it for speed measurement, astronomers use redshift to measure galaxy recession speeds, and medical ultrasound uses it to measure blood flow velocity.

About the Doppler Effect

This simulation visualises the acoustic Doppler effect for a sound source moving in a straight line. The source emits circular wavefronts at a fixed emission period T = 1/f₀, but each new front is launched from a slightly advanced position. The result is a classic interference pattern: fronts bunch up ahead of the source and spread out behind it, with the perceived frequency given by f′ = f₀ · v_sound / (v_sound ∓ v_src).

The top bar lets you set the source speed as a fraction of the speed of sound (0–95%) and the emitted frequency (100–1000 Hz). Preset buttons jump to Car (30%), Fast (80%) and Sonic (95%), and a live readout shows f′ ahead, f′ behind and the Mach number. The Doppler effect underpins police speed radar, weather radar, astronomical redshift and medical blood-flow ultrasound.

Frequently Asked Questions

What is the Doppler effect?

The Doppler effect is the change in observed frequency of a wave when the source and observer move relative to each other. As a source approaches, its wavefronts arrive more often, so the pitch sounds higher; as it recedes, the fronts arrive less often and the pitch drops. The familiar example is a passing siren or car horn.

What equation does this simulation use?

It uses the moving-source Doppler formula f′ = f₀ · v_sound / (v_sound ∓ v_src). The minus sign applies ahead of the source, raising the frequency, and the plus sign applies behind it, lowering the frequency. For example, at f₀ = 440 Hz and a source speed of 30% of the speed of sound, the front observer hears about 629 Hz and the rear observer about 327 Hz.

What do the speed and frequency sliders do?

The source-speed slider sets how fast the source travels as a percentage of the speed of sound, from 0% up to 95%, which also equals the Mach number shown in the readout. The frequency slider sets the emitted frequency f₀ between 100 and 1000 Hz, which controls how closely spaced the wavefronts are. Both update the visual pattern and the f′ values in real time.

Why do the wavefronts bunch up in front of the source?

Each wavefront expands outward at the speed of sound from the point where it was emitted. Because the source keeps moving forward between emissions, every new front starts ahead of the previous one, so the gaps between fronts shrink in the direction of travel. Compressed wavelength means a shorter period and therefore a higher received frequency.

What do the Car, Fast and Sonic preset buttons do?

The presets set the source-speed slider to fixed values: Car selects 30% of the speed of sound, Fast selects 80%, and Sonic selects 95%, which is just below the sound barrier. They are quick ways to compare a gentle Doppler shift against the dramatic compression you see as the source nears Mach 1.

What is the Mach cone shown at high speed?

When the source reaches or exceeds the speed of sound (Mach 1), the wavefronts can no longer outrun it and pile up into a cone-shaped shock front. The simulation draws this Mach cone with a half-angle of arcsin(1/Mach), so the cone narrows as the source goes faster. In air this shock front is heard on the ground as a sonic boom.

Is the simulation physically accurate?

It captures the correct physics qualitatively and uses the standard moving-source Doppler equation, so the frequency relationships and the Mach-cone geometry are sound. It is a simplified two-dimensional model: distances are normalised rather than in metres, the medium is treated as still and uniform, and effects such as attenuation, wind and reflections are omitted for clarity.

Does the observer also need to move for a Doppler shift?

No. A shift occurs whenever there is relative motion between source and observer. This simulation models a moving source with stationary observers, but a moving observer would produce a related shift with a slightly different formula. When both move, the two effects combine in the full Doppler equation.

How is the Doppler effect used in the real world?

Police and weather radar bounce waves off moving objects and measure the frequency shift to find speed. Astronomers use the redshift of light from distant galaxies to measure how fast they are receding, which is key evidence for the expanding universe. Medical Doppler ultrasound measures the shift from moving blood cells to assess blood flow.

Why does the pitch of a passing siren suddenly drop?

While the vehicle approaches, its wavefronts are compressed and you hear a raised pitch. The instant it passes and begins to recede, the wavefronts stretch out and the pitch falls. The change sounds abrupt because the shift flips from the front formula to the rear formula as the source goes by, even though the source frequency never actually changes.