HomePhysics › Wavelength & Frequency Calculator

Wavelength & Frequency Calculator

Converts between wavelength and frequency for a wave of known propagation speed (default: the speed of light in vacuum) and, for electromagnetic waves in vacuum, reports the photon energy E = h·f in joules and electronvolts.

When to use

You know either the wavelength or the frequency of a light, radio or sound wave and need the other, or you need the photon energy of light of a given wavelength.

Do not use when: The wave travels in a dispersive medium (glass, water) unless you supply the correct phase speed, or you need Doppler shifts or refraction.

Formula

wavelength_m = wave_speed_m_s / frequency_hz; frequency_hz = wave_speed_m_s / wavelength_m; photon_energy_j = h × frequency_hz with h = 6.62607015e-34 J·s; photon_energy_ev = photon_energy_j / 1.602176634e-19

Inputs

ParameterTypeUnitRequiredDescription
wavelength_mnumbermnoWavelength in metres (1 nm = 1e-9 m, so 500 nm = 5e-7). Give either wavelength_m or frequency_hz. Range: > 0
frequency_hznumberHznoFrequency in hertz (1 MHz = 1e6 Hz, 1 GHz = 1e9 Hz). Give either wavelength_m or frequency_hz. Range: > 0
wave_speed_m_snumberm/sdefault 299792458Propagation speed in the medium. Default c = 299,792,458 m/s (light in vacuum); use about 343 for sound in air at 20 °C, 1480 for sound in water. Range: > 0, ≤ 299792458

Outputs

OutputTypeUnitDescription
solved_forstringWhich quantity was computed: wavelength_m or frequency_hz.
wavelength_mnumbermλ = v / f.
wavelength_nmnumbernmWavelength in nanometres (visible light ≈ 380–750 nm).
frequency_hznumberHzf = v / λ.
wave_speed_m_snumberm/sPropagation speed used.
photon_energy_evnumbereVE = h × f in electronvolts (only for electromagnetic waves in vacuum, i.e. wave_speed_m_s = c).
photon_energy_jstringJPhoton energy in joules as a scientific-notation string with 5 significant figures, e.g. "3.9729e-19" (only when wave_speed_m_s = c).

Example

Green light, 500 nm in vacuum: {"wavelength_m":5e-7}{"solved_for":"frequency_hz","frequency_hz":599584916000000,"wavelength_nm":500,"photon_energy_ev":2.479684,"photon_energy_j":"3.9729e-19"}

440 Hz sound in air (343 m/s): {"frequency_hz":440,"wave_speed_m_s":343}{"solved_for":"wavelength_m","wavelength_m":0.779545,"wavelength_nm":779545454.5455}

GET https://tttkmbb.com/api/v1/calculate/wavelength-frequency?wavelength_m=5e-7

Machine access

Sources

FAQ

Why is there no photon energy for my sound wave?

Photon energy E = h·f applies to electromagnetic radiation only; it is reported when the wave speed equals c (vacuum). Sound is a mechanical wave.

What speed should I use for light in glass or water?

c divided by the refractive index (about 1.5 for glass, 1.33 for water); the frequency stays the same while the wavelength shortens.

Related calculators