Introduction to relativistic redshift and blueshift
The relativistic Doppler shift describes how motion changes the wavelength and frequency of light measured by an observer. When a source travels toward the observer, successive wavefronts arrive more closely spaced and the observed wavelength becomes shorter. This is a blueshift. When the source travels away, the wavefront spacing grows and the measured wavelength becomes longer, producing a redshift.
This calculator turns an emitted rest wavelength, a source speed, and a direction into a one-dimensional relativistic Doppler result. It also supplies a wavefront animation for visual comparison. The numerical prediction comes from the special-relativistic wavelength formula, while the animation illustrates the basic idea that source motion changes the spacing between arriving signals.
Relativistic treatment matters because the familiar low-speed Doppler approximation is not sufficient when the source speed is a meaningful fraction of the speed of light. Time dilation contributes to the measured shift, making the result different from a classical calculation. The effect is central to astronomy, spectroscopy, accelerator experiments, and any situation in which electromagnetic radiation is measured across rapidly moving reference frames.
How to use the relativistic Doppler shift controls
To use the relativistic Doppler calculator, begin with the wavelength emitted in the source’s own rest frame. Enter that wavelength in nanometres, then provide the magnitude of the source’s velocity in metres per second. The direction selector determines whether the entered speed represents motion toward or away from the observer.
- Enter the rest wavelength λ₀ in nanometres. Visible light is roughly 380–750 nm, although the formula also applies outside the visible spectrum.
- Enter the source’s speed v in metres per second. Use a nonnegative magnitude; the direction control applies the appropriate sign.
- Select Approaching for a blueshift or Receding for a redshift.
- Set Δt between 0.001 and 0.1 seconds. This controls the animation step and does not change the analytic wavelength.
- Select Play to begin, Pause to freeze the view, or Reset to rebuild the animation from the current inputs.
- Use Download CSV if you want a record of values generated during the animated run.
A physically valid source speed must remain below c, approximately 299,792,458 m/s. The calculator rejects zero or negative wavelengths and speeds whose magnitude reaches or exceeds the speed of light. For a controlled comparison, change only one input at a time. Holding λ₀ constant while varying speed makes the nonlinear relativistic effect especially clear.
The formula for the observed relativistic wavelength
The relativistic Doppler formula uses the dimensionless speed ratio β = v/c. In this page’s sign convention, positive β represents recession and negative β represents approach. The observed wavelength is calculated as follows:
Here, λ₀ is the wavelength emitted in the source’s rest frame, λobs is the wavelength measured by the observer, v is the signed relative velocity, and c is the speed of light in vacuum. Because β is a ratio of two speeds, it has no unit. The square-root term is the relativistic Doppler factor for direct line-of-sight motion.
For recession, β is positive, so the numerator grows while the denominator shrinks. The factor is greater than one and λobs is longer than λ₀. For approach, β is negative and the factor is less than one, yielding a shorter observed wavelength. At zero relative speed, β is zero, the square-root factor equals one, and the observed wavelength equals the emitted wavelength.
Worked example: shifting 500 nm light at one-tenth of light speed
Consider a source that emits green light with a rest wavelength of 500 nm and recedes at 0.1c. The speed is about 29,979,246 m/s, giving β = 0.1. Substituting that value into the formula produces a Doppler factor of approximately 1.1055. The observed wavelength is therefore about 552.8 nm. The light has shifted toward the longer-wavelength, redder part of the visible spectrum.
If the same source approaches at the same speed, β becomes −0.1. The factor is then approximately 0.9045, and the observer measures about 452.3 nm. Notice that the approaching and receding wavelength changes are not simple equal offsets around 500 nm. The relativistic formula is multiplicative, and the two factors are reciprocals.
The page defaults use 500 nm and 100,000 m/s, which is only about 0.000334c. That produces a much smaller shift. The default is useful for checking direction and controls, but a speed such as 0.1c makes the relativistic behavior easier to see numerically.
How wavelength, speed, direction, and Δt affect the result
The rest wavelength sets the scale of the answer. If two sources have different rest wavelengths but the same β and direction, both wavelengths are multiplied by exactly the same Doppler factor. Doubling λ₀ therefore doubles λobs, but it does not change the percentage shift.
Speed determines the strength of the shift. At ordinary terrestrial speeds, β is tiny and the wavelength change may be difficult to see after rounding. As the magnitude of β increases, the square-root factor changes increasingly quickly. Close to the speed of light, the receding wavelength rises sharply, while the approaching wavelength falls toward zero. The calculator does not allow |v| ≥ c because that lies outside the physical domain of this source model.
Direction determines the sign of β rather than the magnitude of the entered speed. Approaching motion compresses the observed wavelength, while receding motion stretches it. The Δt field is different: it belongs to the visualization. A smaller timestep can make the animated progression smoother, while a larger one advances simulated time more quickly. Changing Δt should not alter the analytic Doppler factor.
How to interpret the wavelength readout and animation
Interpret the result by first comparing the analytic wavelength with λ₀. An analytic value below λ₀ confirms a blueshift, and a value above λ₀ confirms a redshift. The ratio λobs/λ₀ is the Doppler factor, so it is often more informative than the absolute difference when comparing light from different parts of the spectrum.
The canvas places the source near its central reference position and draws expanding wavefronts. Color indicates the selected direction: blue is used for approach and red for recession. The graphic is an illustrative, rescaled view rather than a literal drawing of nanometre-scale waves traveling hundreds of millions of metres per second. Its purpose is to connect source motion with changing wavefront spacing.
The summary compares a wavelength inferred during the animation with the analytic prediction. Numerical stepping, rendering scale, frame timing, and display rounding can make the visual estimate less stable than the closed-form result. Use the analytic wavelength as the authoritative calculator output and the canvas as a conceptual aid. CSV output is most useful for exploring the sequence generated by the animation rather than replacing a high-precision scientific computation.
Limitations of this one-dimensional Doppler estimate
The limitations of this relativistic Doppler estimate begin with geometry. The formula assumes that source motion is directly along the observer’s line of sight. It does not calculate the transverse Doppler effect for sideways motion or a general viewing angle. If the velocity has both radial and transverse components, a more complete four-vector or angular treatment is required.
The model also assumes flat spacetime, inertial motion, vacuum propagation, and a clearly defined rest-frame wavelength. It does not include acceleration, gravitational redshift, cosmological expansion, refraction, dispersion in a medium, scattering, source rotation, or instrumental calibration. In astronomy, several of those effects may contribute to the same measured spectral-line displacement.
- Units: wavelength must be entered in nm and speed in m/s. Convert kilometres per second or other units before calculation.
- Velocity domain: the magnitude of source speed must be less than 299,792,458 m/s.
- Direction: the selector describes source motion relative to the observer, not the direction in which a photon is drawn on the screen.
- Precision: displayed values are rounded for readability, and JavaScript floating-point arithmetic has finite precision.
- Visualization: the wavefront canvas is deliberately rescaled and should not be interpreted as a spatially exact laboratory simulation.
For coursework, the calculator is useful for checking sign conventions and order of magnitude. For observational astronomy, laboratory spectroscopy, navigation, or safety-critical analysis, verify the result with documented measurement procedures and a model that includes the relevant geometry and environmental effects.
Observed wavelength and analytic check will appear here after you start the animation.