Heronian Mean Calculator
Average two numbers using both their arithmetic and geometric means.
What it does
The Heronian mean is a way to average two non-negative numbers that blends their arithmetic and geometric means. It is named for Heron of Alexandria and appears in both number theory and elementary geometry.
This tool applies the formula directly and shows the two familiar means beside the result. That makes the ordering easy to verify: the geometric mean is never larger than the Heronian mean, which is never larger than the arithmetic mean.
The same value has a geometric interpretation. In a trapezoid with parallel bases of lengths a and b, a segment one third of the way from the arithmetic mean level to the geometric mean level has length equal to the Heronian mean.
Like any mean it is symmetric, so swapping the inputs changes nothing, and it is idempotent, so averaging a number with itself returns that number. It accepts zero, where the geometric mean is zero and the Heronian mean is one third of the other value.
How to use
- Enter the first non-negative number.
- Enter the second non-negative number.
- Read the Heronian mean in the main result.
- Check that it falls between the geometric and arithmetic means.
- Try equal inputs to confirm the result is that value.
- Try a zero input to see how the geometric term disappears.
Formula
- a, b
- Two non-negative real numbers.
- sqrt(ab)
- The geometric mean of the pair.
- H
- The Heronian mean of the pair.
The formula can also be written as two thirds of the arithmetic mean plus one third of the geometric mean, which shows why the result sits between them. It is symmetric and idempotent. Negative inputs are not accepted because the square root would not be real. Very large inputs are capped to keep the multiplication and square root stable.
Worked example
Example: Heronian mean of 1 and 4
Inputs a = 1 and b = 4.
- Geometric mean: sqrt(1 x 4) = sqrt(4) = 2.
- Arithmetic mean: (1 + 4) / 2 = 2.5.
- Heronian mean: (1 + 2 + 4) / 3 = 7 / 3.
- As a decimal that is 2.333333.
- Ordering check: 2 < 2.333333 < 2.5.
- Tool shows 2.333333 with both bounding means.
Reference table
| a | b | Geometric | Arithmetic | Heronian |
|---|---|---|---|---|
| 1 | 1 | 1 | 1 | 1 |
| 1 | 4 | 2 | 2.5 | 2.333333 |
| 0 | 9 | 0 | 4.5 | 3 |
| 4 | 9 | 6 | 6.5 | 6.333333 |
| 9 | 16 | 12 | 12.5 | 12.333333 |
Limits
- Negative inputs are not supported.
- The result is a mean, not a geometric length unless inputs are lengths.
- Very large values are capped to protect the square root.
- It assumes both inputs use the same scale and units.
Common mistakes
- Confusing the Heronian mean with Heron's formula for triangle area.
- Averaging the two numbers and stopping there.
- Including the square root twice in the numerator.
- Entering a negative number and expecting a real result.
- Assuming it always equals the arithmetic mean.
Try it yourself
Quick checks. Answers sit tucked under each question.
Heronian mean of 1 and 4?
(1 + 2 + 4) / 3 = 2.333333.
Heronian mean of a number with itself?
That same number.
Which mean is larger, geometric or Heronian?
The Heronian mean, for any unequal positive pair.
Questions
What is the Heronian mean?
One third of the sum of two numbers and their geometric mean.
Why is it named that?
It is named for Heron of Alexandria.
Where does it appear?
In inequalities between means and in trapezoid geometry.
Does it work with zero?
Yes. If one input is zero the result is one third of the other.
Can it handle negatives?
No, because the geometric mean would not be real.
How is it related to the arithmetic mean?
It is two thirds arithmetic mean plus one third geometric mean.