MathorynMathematical Formula Database

Algebra

QM–AM–GM–HM Inequality

For positive numbers the quadratic, arithmetic, geometric and harmonic means always appear in this order, with equality only when the numbers are equal. It is used to bound expressions in optimisation problems and to compare different kinds of averages.

a2+b22≥a+b2≥ab≥2aba+b\sqrt{\frac{a^2+b^2}{2}}\ge\frac{a+b}{2}\ge\sqrt{ab}\ge\frac{2ab}{a+b}
LaTeX\sqrt{\frac{a^2+b^2}{2}}\ge\frac{a+b}{2}\ge\sqrt{ab}\ge\frac{2ab}{a+b}

Variables

a, ba,\ b
positive numbers

Example

Compare the four means of 11 and 44.

  1. QM: 17/2≈2.9155\sqrt{17/2}\approx2.9155.
  2. AM: 2.52.5; GM: 4=2\sqrt4=2.
  3. HM: 2⋅45=1.6\frac{2\cdot4}{5}=1.6.

Answer: 2.9155≥2.5≥2≥1.62.9155\ge2.5\ge2\ge1.6.

Related formulas