Averaging Speeds and Why the Simple Mean Fails
Average speed is total distance over total time. See why the midpoint of two speeds is often wrong and when it is right.
Key takeaways
- Average speed always equals total distance divided by total time.
- Equal times at speeds a and b give an average of (a + b)/2.
- Equal distances at speeds a and b give an average of 2ab/(a + b), which is never larger than the simple mean.
- The same trap appears with fuel economy, work rates and prices per unit.
Average speed is total distance divided by total time. If you drive 60 kilometers at 30 km/h and then 60 kilometers back at 60 km/h, your average is 40 km/h, not 45. The slow leg takes twice as long as the fast one, so the slow speed counts for more.
The simple mean of two speeds is correct only when you spend equal time at each. When you cover equal distances instead, a different formula applies, called the harmonic mean. This article derives both and shows how to handle any mix of legs.
The round trip that surprises people
Take the 60 kilometer example slowly. Use t = d/r on each leg.
out: t = 60/30 = 2 hours
back: t = 60/60 = 1 hour
total distance = 120 km
total time = 3 hours
average speed = 120/3 = 40 km/h Of the three hours, two were spent at 30 and only one at 60. If you could watch a clock at a random moment of the journey, you would be twice as likely to catch the slow leg.
The number 45, halfway between 30 and 60, ignores this. A car averaging 45 km/h for 3 hours would cover 135 kilometers, but the trip was only 120. Testing a proposed average against the real totals is the surest way to catch the error. If you need a refresher on the three forms of the formula, see distance, rate and time.
When the simple mean is right
Now change the story: drive for 1 hour at 30 km/h and for 1 hour at 60 km/h.
distance = 30(1) + 60(1) = 90 km
time = 2 hours
average = 90/2 = 45 km/h Here the simple mean works. In general, with equal times t at speeds a and b, the distance is at + bt and the time is 2t, so the average is (at + bt)/(2t) = (a + b)/2.
The difference between the two stories is what was held equal. Speed is a rate "per hour," so speeds average plainly when each gets the same number of hours. When each gets the same number of kilometers, the hours differ, and the weighting shifts.
Deriving the equal-distance formula
Let each leg have length d, with speeds a and b, both positive.
total distance = 2d
total time = d/a + d/b
= d(a + b)/(ab) (common denominator ab)
average = 2d ÷ [d(a + b)/(ab)]
= 2ab/(a + b) (d cancels; d ≠ 0) The distance d disappears. A round trip at 30 out and 60 back averages 40 km/h whether the destination is 1 kilometer or 500 kilometers away. With the numbers, 2 × 30 × 60/90 = 3600/90 = 40.
The quantity 2ab/(a + b) is the harmonic mean of a and b. Another way to say it: take the reciprocal of each speed, average those, and take the reciprocal of the result. The reciprocal of a speed is the time needed per kilometer, and times per kilometer can be averaged plainly when distances are equal.
Why the harmonic mean is never bigger
Subtract the two formulas and simplify.
(a + b)/2 - 2ab/(a + b)
= [(a + b)² - 4ab] / [2(a + b)]
= (a² - 2ab + b²) / [2(a + b)]
= (a - b)² / [2(a + b)] For positive speeds, the denominator is positive and the numerator is a square, so the difference is never negative. It is zero only when a = b. With 30 and 60, the difference is 900/180 = 5, matching 45 - 40.
The farther apart the speeds, the bigger the gap. For 50 and 60, the harmonic mean is about 54.5 compared with 55. For 10 and 90, it is 18 compared with 50.
The geometric mean, √(ab), sits between these two. Their ordering is a classic result, introduced for two numbers in the arithmetic and geometric mean inequality.
Unequal distances and many legs
Most real trips have legs of different lengths. No special formula is needed: add the distances, add the times and divide.
| Leg | Distance (km) | Speed (km/h) | Time (h) |
|---|---|---|---|
| Town | 10 | 20 | 1/2 |
| Highway | 30 | 90 | 1/3 |
| Total | 40 | 5/6 |
The average is 40 ÷ (5/6) = 48 km/h. The simple mean of 20 and 90 would claim 55.
Stops count too if the question is about the whole journey. Add a 10 minute stop, which is 1/6 hour, and the total time becomes 1 hour, so the overall average falls to 40 km/h. Say clearly whether your average includes stopped time.
With legs of distances d₁, d₂, d₃ at speeds v₁, v₂, v₃, the general form is:
average = (d₁ + d₂ + d₃) / (d₁/v₁ + d₂/v₂ + d₃/v₃) You can also view it as a weighted mean of the speeds in which each weight is the share of total time spent on that leg.
Solving backward for an unknown speed
You can rearrange the equal-distance formula to find one speed from the other and the average. Let M be the average, a the known speed and b the unknown one.
M = 2ab/(a + b)
M(a + b) = 2ab
Ma + Mb = 2ab
Ma = 2ab - Mb
Ma = b(2a - M) (factor out b)
b = Ma/(2a - M) (needs 2a > M) The letter b appeared twice after clearing the fraction, so factoring was needed, the technique described in solving for a variable that appears twice.
With a = 30 and M = 40, b = 1200/20 = 60, matching the round trip. With a = 30 and M = 50, b = 1500/10 = 150 km/h. As M approaches 2a = 60, the denominator shrinks toward zero and the required speed grows without bound.
That gives a general limit: over two equal distances, your average speed is always less than twice the slower speed. No amount of hurrying on the second half can reach it, because the first half alone has already used up the time that such an average would allow.
The impossible catch-up
Here is a puzzle that the simple mean gets badly wrong. You must travel 2 kilometers and want to average 60 km/h. You cover the first kilometer at only 30 km/h. How fast must you cover the second?
The guess of 90 comes from (30 + 90)/2 = 60. Check the time budget instead. Averaging 60 km/h over 2 km allows 2 minutes in total. The first kilometer at 30 km/h already took 2 minutes. No time remains, so no speed, however large, will do it.
In symbols, 2/(1/30 + 1/v) = 60 requires 1/30 + 1/v = 1/30, so 1/v = 0, which no number v satisfies.
A milder target works. To average 40 km/h you need 1/30 + 1/v = 1/20, so 1/v = 1/60 and v = 60 km/h. The puzzle is about arithmetic only; real speeds are set by the law and road conditions.
The same trap in other places
Fuel economy. Drive 100 miles at 20 miles per gallon and 100 miles at 30. You burn 5 gallons and then about 3.33, for 200 miles on about 8.33 gallons, which is 24 miles per gallon, not 25.
Buying with equal money. Spend 12 dollars on an item at 2 dollars each and 12 dollars on one at 3 dollars each. You get 6 + 4 = 10 items for 24 dollars, an average of 2.40 each. Buy equal numbers instead, and the average is 2.50.
Working rates. A machine that makes the first half of an order slowly and the second half quickly spends more time in the slow phase, just like the car.
The pattern is always the same. When a rate is "A per B" and each part has the same amount of A, you get a harmonic mean. When each part has the same amount of B, you get the ordinary mean. Further disguises are collected in harmonic mean problems.
A checklist for any average rate
- Write down what the rate means, such as kilometers per hour.
- Find the total of the top quantity across all parts.
- Find the total of the bottom quantity across all parts.
- Divide the first total by the second.
- Confirm the answer lies between the smallest and largest rates.
The last step is a useful screen but not a full test, since 45 also lies between 30 and 60. Only the totals settle it. A table with columns for distance, rate and time, as used in tables before equations, keeps those totals organized.
Common questions
Is the harmonic mean ever the wrong choice for distances?
It applies to equal distances. If the distances differ, use total distance over total time, which includes the equal case automatically. When in doubt, use the totals.
What if one speed is zero?
A leg with zero speed never covers a positive distance, so the equal-distance formula does not apply. A stop should be entered as time with no distance added.
Does a speedometer average work this way?
A device that records speed at equal time intervals and averages those readings is weighting by time, which matches total distance over total time reasonably well when the readings are frequent. Readings taken at equal distances and averaged plainly would tend to overstate the average speed.
How can I estimate the answer before calculating?
Ask which speed you spend more time at. On equal distances it is always the slower one, so the average must fall below the midpoint of the two speeds. If your result lands above the midpoint, you have probably weighted the legs the wrong way round, and a quick table of times will show where.