ALGEBRASequencesMathematics Calculator

Harmonic Numbers

Harmonic numbers H(n) = 1 + 1/2 + 1/3 + … + 1/n represent the sum of reciprocals. Despite terms tending to zero, the series diverges slowly—like ln(n)—and is approximated by ln(n) + γ where γ is the Euler-Mascheroni constant.

Concept Fundamentals
≈ 0.5772
Euler-Mascheroni γ
O(ln n)
Growth rate
Yes (slowly)
Diverges
n·H(n) trials
Coupon collector

Did our AI summary help? Let us know.

Nicole Oresme proved divergence in the 14th century by grouping terms. The Euler-Mascheroni constant γ is irrational and its exact value is unknown. H(n) is never an integer for n > 1 (proved by Tao, 2012).

Key quantities
≈ 0.5772
Euler-Mascheroni γ
Key relation
O(ln n)
Growth rate
Key relation
Yes (slowly)
Diverges
Key relation
n·H(n) trials
Coupon collector
Key relation

Ready to run the numbers?

Why: Harmonic numbers appear in algorithm analysis (quicksort), probability (coupon collector), and number theory (prime counting).

How: Compute H(n) by summing 1/k or use the approximation ln(n)+γ for large n.

Nicole Oresme proved divergence in the 14th century by grouping terms.The Euler-Mascheroni constant γ is irrational and its exact value is unknown.

Run the calculator when you are ready.

The Harmonic SeriesFrom Oresme to Euler—a slowly diverging mystery

Harmonic Numbers — The Slowly Diverging Series

H(n) = 1 + 1/2 + 1/3 + … + 1/n. Diverges like ln(n), approximated by ln(n) + γ.

Examples — Click to Load

For educational and informational purposes only. Verify with a qualified professional.

🧮 Fascinating Math Facts

γ

γ ≈ 0.5772 appears in harmonic numbers, prime counting, and the Riemann zeta function.

🎵

Harmonic overtones in music follow the same 1, 1/2, 1/3 pattern as the harmonic series.

Key Takeaways

  • Hn = 1 + 1/2 + 1/3 + … + 1/n — the sum of reciprocals of the first n positive integers
  • • The harmonic series diverges but extremely slowly — Hn grows without bound
  • ln(n) + γ approximates Hn well for large n
  • γ ≈ 0.5772 (Euler-Mascheroni constant) — one of mathematics's most mysterious numbers

Did You Know?

γThe Euler-Mascheroni constant γ is irrational and its exact value is unknown — it appears in harmonic numbers, prime counting, and the Riemann zeta functionSource: Wolfram MathWorld
🔢Harmonic numbers connect to prime numbers: the sum of reciprocals of primes diverges, and H_n relates to the prime-counting functionSource: Number Theory
🎵In music theory, harmonic overtones are integer multiples of a fundamental frequency — the same 1, 1/2, 1/3 pattern as the harmonic seriesSource: Acoustics
📜Nicole Oresme proved in the 14th century that the harmonic series diverges by grouping terms to show the sum exceeds any boundSource: History of Mathematics
🎫The coupon collector problem: expected trials to collect n distinct coupons is n·H_n — harmonic numbers appear naturally in probabilitySource: Probability Theory
ζThe Riemann zeta function ζ(s) extends harmonic numbers: ζ(1) would equal the limit of H_n, but the series diverges at s=1Source: Analytic Number Theory

How Harmonic Numbers Work

The nth harmonic number Hn is defined as the sum of the reciprocals of the first n positive integers. As n grows, each new term 1/n becomes smaller, but the sum still increases without bound.

Definition

Hn = 1 + 1/2 + 1/3 + … + 1/n = Σk=1n 1/k

Asymptotic Approximation

For large n: Hn ≈ ln(n) + γ, where γ ≈ 0.5772156649. The error tends to 1/(2n) as n → ∞.

Divergence

Oresme's proof: group terms as 1, (1/2), (1/3+1/4), (1/5+…+1/8), … Each group is ≥ 1/2, so the sum exceeds any multiple of 1/2.

Expert Tips

ln(n) + γ Approximation

For n > 10, the approximation is accurate to within 1%. For n = 1000, the relative error is under 0.05%.

Coupon Collector

Expected trials to collect all n coupons is n·H_n. For n=20, that's about 72 trials on average.

Prime Counting

The sum of 1/p over primes p ≤ n is approximately ln(ln(n)) + M, where M is Meissel-Mertens constant.

Integral Comparison

H_n lies between ∫₁ⁿ⁺¹ (1/x) dx = ln(n+1) and 1 + ∫₁ⁿ (1/x) dx = 1 + ln(n).

Comparison: Manual vs Programming vs Lookup Table

FeatureThis CalculatorManual SumProgrammingLookup Table
Exact H(n) for any n ≤ 1000❌ Impractical⚠️ Limited n
ln(n)+γ approximation
Error analysis⚠️ Manual
Charts & visualization
Educational content
Copy & share results

Frequently Asked Questions

What is a harmonic number?

The nth harmonic number H_n is the sum 1 + 1/2 + 1/3 + … + 1/n. It represents the sum of reciprocals of the first n positive integers.

Does the harmonic series converge?

No. The harmonic series diverges — the sum grows without bound as n increases, though very slowly (like ln(n)).

What is the Euler-Mascheroni constant?

γ ≈ 0.5772 is the limit of (H_n - ln(n)) as n → ∞. It appears in many areas of mathematics including number theory and analysis.

How accurate is the ln(n) + γ approximation?

For large n, the error is approximately 1/(2n). For n=100, the error is about 0.005; for n=1000, about 0.0005.

Where do harmonic numbers appear in real life?

In the coupon collector problem (expected trials to collect all coupons), algorithm analysis (quicksort average case), and music (harmonic overtones).

Can H_n ever be an integer?

No. For n > 1, H_n is never an integer. This was proved by Tao in 2012 (and earlier by others).

What is the growth rate of H_n?

H_n grows like O(ln n). More precisely, H_n = ln(n) + γ + 1/(2n) - 1/(12n²) + …

Who first proved the harmonic series diverges?

Nicole Oresme (c. 1323–1382) gave the first known proof by grouping terms to show the sum exceeds any finite bound.

Infographic Stats

γ ≈ 0.5772
Euler-Mascheroni
Diverges
Yes (slowly)
O(ln n)
Growth rate
14th c.
Known since (Oresme)

Disclaimer: This calculator is for educational purposes. Harmonic numbers have applications in mathematics, computer science, and physics. Results are exact for n ≤ 1000. The ln(n)+γ approximation is asymptotic; accuracy improves with larger n.

👈 START HERE
⬅️Jump in and explore the concept!
AI

Related Calculators