How the Speed of Sound Is Calculated
The speed of sound in air is set almost entirely by temperature — not by pitch, loudness, or (directly) air pressure. For dry air it follows from the ideal gas law: c = √(γRT/M), where γ ≈ 1.4 is the adiabatic index of air, R = 8.314 J/(mol·K) is the universal gas constant, T is the absolute temperature in kelvins, and M ≈ 0.0289645 kg/mol is the molar mass of dry air. Plugging in those constants and switching to Celsius gives the simplified form this calculator uses: c = 331.3 × √(1 + T/273.15) m/s, which returns 331.3 m/s at 0°C and about 343 m/s at 20°C — the commonly quoted "room temperature" value.
How the calculation works
Enter the air temperature and pick its unit — Celsius, Fahrenheit, or Kelvin. The calculator converts your value to Celsius (°F: (T − 32) × 5/9; K: T − 273.15), applies c = 331.3 × √(1 + T/273.15) to get the speed in meters per second, then converts that into kilometers per hour (× 3.6), miles per hour (× 2.2369), and feet per second (× 3.2808). If you also enter a sound frequency, it divides the speed by that frequency (λ = c / f) to report the wavelength — useful for spacing microphones, sizing room dimensions, or laying out ducts.
Why temperature matters more than pressure or humidity
A common misconception is that thinner (lower-pressure) air carries sound faster or slower. In an ideal gas, pressure and density scale together, so pressure cancels out of the formula — altitude and weather-driven pressure changes have essentially no direct effect on the speed of sound by themselves. Humidity has a small, separate effect: water vapor is lighter than the nitrogen and oxygen it displaces, so moist air is very slightly less dense and sound travels about 0.1-0.6% faster in it. This calculator assumes dry air at typical sea-level composition, which is accurate to within a few tenths of a percent for most everyday conditions.
Real-world applications
- Estimating lightning distance: count the seconds between a flash and its thunder and multiply by the speed of sound (roughly 343 m/s, or about 1 km per 3 seconds) to estimate how far away the storm is.
- Audio and room acoustics: wavelength at a given frequency determines speaker placement, room-mode spacing, and whether a room's dimensions reinforce or cancel a particular bass note.
- Sonar and echolocation: ranging systems that use sound (or ultrasound) in air need an accurate speed-of-sound value to convert echo delay into distance.
- Aviation and ballistics: Mach number — the ratio of an aircraft's or projectile's speed to the local speed of sound — depends directly on air temperature at altitude, which is colder and therefore has a lower local speed of sound than at sea level.