Skip to main content

Harmonic Mean Calculator – Speeds & Fuel

Quick answer

Harmonic mean H=n/Σ(1/xᵢ) blends rates over equal distance: 30 and 20 mpg combine to 24 mpg, not 25.

  • Reciprocal work shown line by line.

Figures are estimates from this calculator’s standard formula — adjust the inputs in the tool below for your exact number.

How the Harmonic Mean Calculator Works

H = n / (1/x₁ + 1/x₂ + … + 1/xₙ)

The harmonic mean is built for rates that alternate over equal stretches. If a car does one lap at 30 mpg and the next at 20 mpg over the same distance, the combined fuel economy is H = 2/(1/30 + 1/20) = 2/(0.08333) = 24 mpg — not the arithmetic 25, because the thirsty lap consumes more fuel per mile. The calculator prints each reciprocal (1/30 ≈ 0.0333, 1/20 = 0.05), sums them, divides n by the total, and shows the arithmetic mean beside it for contrast. Data validation blocks zeros and negatives since 1/x must exist, and the result always lands between the smallest and largest inputs, skewed toward the low end — one slow leg dominates blended averages. Multiperiod examples like 60, 40 and 30 mph over equal legs produce H = 3/(1/60+1/40+1/30) = 40 mph, well below the arithmetic 43.3.

  1. 1

    Enter your rates

    Two or more positive values — speeds, mpg, prices per unit

  2. 2

    Invert each one

    Every 1/x is computed and displayed

  3. 3

    Average the reciprocals

    Sum them, divide by n, then flip the result

  4. 4

    Compare with the arithmetic mean

    The gap explains why blending matters

Use Cases

Fuel Economy Blending

EPA combines city 25 and highway 40 mpg harmonically to 30.8

Round-Trip Speed

60 mph out and 40 mph back average 48 mph over equal legs

Server Throughput

Blending 100 and 200 req/s tiers over equal work gives 133.3 req/s

Tips

  • 1

    Equal distances or amounts → harmonic; equal times → arithmetic

  • 2

    H is pinned near the minimum: one slow rate drags the blend

  • 3

    Never average a rate over its own denominator arithmetically

Common Mistakes

  • Averaging 30 and 20 mpg to 25; the true blend is 24

  • Including a zero rate, which makes 1/x undefined

  • Using the harmonic mean for amounts (distances, prices totals) instead of rates

  • Forgetting the final reciprocal — leaving the answer as Σ(1/x)/n

FAQs

What is the blended mpg of 30 city and 20 highway?

H = 2/(1/30+1/20) = 24 mpg, not the arithmetic 25.

Round trip at 60 and 40 mph — average speed?

2/(1/60+1/40) = 48 mph because more time is spent at 40.

How does one slow rate affect the blend?

H sits between min and max but skews low: for 60, 40 and 30 mph over equal legs, H = 40 mph, well below the arithmetic 43.3.

When is the arithmetic mean correct instead?

When legs carry equal time, not equal distance — e.g. driving each speed for one hour.

What inputs are invalid?

Zero and negative rates: 1/0 is undefined and negative rates break the reciprocal sum.