The areas / V12. Number theory
Mathlib.NumberTheory.SumPrimeReciprocals
11 declarations. Mathlib docs · Source
The sum of the reciprocals of the primes diverges
We show that the sum of 1/p, where p runs through the prime numbers, diverges.
We follow the elementary proof by Erdős that is reproduced in "Proofs from THE BOOK".
There are two versions of the main result: not_summable_one_div_on_primes, which
expresses the sum as a sub-sum of the harmonic series, and Nat.Primes.not_summable_one_div,
which writes it as a sum over Nat.Primes. We also show that the sum of p^r for r : ℝ
converges if and only if r < -1; see Nat.Primes.summable_rpow.
References
See the sixth proof for the infinity of primes in Chapter 1 of [aigner1999proofs]. The proof is due to Erdős.
theorem Nat.Primes.tprod_eq_tprod_ite E1 #
∀ {M : Type u_1} [inst : CommMonoid M] [inst_1 : TopologicalSpace M] (f : ℕ → M),
∏' (p : Nat.Primes), f ↑p = ∏' (n : ℕ), if Nat.Prime n then f n else 1
Reindex a product over Nat.Primes as a product over ℕ, extending f by 1.
theorem Nat.Primes.tsum_eq_tsum_ite E1 #
∀ {M : Type u_1} [inst : AddCommMonoid M] [inst_1 : TopologicalSpace M] (f : ℕ → M),
∑' (p : Nat.Primes), f ↑p = ∑' (n : ℕ), if Nat.Prime n then f n else 0
Reindex a sum over Nat.Primes as a sum over ℕ, extending f by 0.
theorem Nat.Primes.multipliable_iff_multipliable_ite E1 #
∀ {M : Type u_1} [inst : CommMonoid M] [inst_1 : TopologicalSpace M] (f : ℕ → M),
(Multipliable fun p ↦ f ↑p) ↔ Multipliable fun n ↦ if Nat.Prime n then f n else 1
Multipliable over Nat.Primes iff over ℕ extending f by 1.
theorem Nat.Primes.summable_iff_summable_ite E1 #
∀ {M : Type u_1} [inst : AddCommMonoid M] [inst_1 : TopologicalSpace M] (f : ℕ → M),
(Summable fun p ↦ f ↑p) ↔ Summable fun n ↦ if Nat.Prime n then f n else 0
Summable over Nat.Primes iff over ℕ extending f by 0.
theorem Nat.Primes.hasProd_iff_hasProd_ite E1 #
∀ {M : Type u_1} [inst : CommMonoid M] [inst_1 : TopologicalSpace M] (f : ℕ → M) {a : M},
HasProd (fun p ↦ f ↑p) a ↔ HasProd (fun n ↦ if Nat.Prime n then f n else 1) a
HasProd over Nat.Primes iff over ℕ extending f by 1.
theorem Nat.Primes.hasSum_iff_hasSum_ite E1 #
∀ {M : Type u_1} [inst : AddCommMonoid M] [inst_1 : TopologicalSpace M] (f : ℕ → M) {a : M},
HasSum (fun p ↦ f ↑p) a ↔ HasSum (fun n ↦ if Nat.Prime n then f n else 0) a
HasSum over Nat.Primes iff over ℕ extending f by 0.
theorem Nat.roughNumbersUpTo_card_le' E1 #
∀ (N k : ℕ), ↑(N.roughNumbersUpTo k).card ≤ ↑N * ∑ p ∈ N.succ.primesBelow \ k.primesBelow, 1 / ↑p
The cardinality of the set of k-rough numbers ≤ N is bounded by N times the sum
of 1/p over the primes k ≤ p ≤ N.
theorem one_half_le_sum_primes_ge_one_div E1 #
∀ (k : ℕ), 1 / 2 ≤ ∑ p ∈ (4 ^ (k.primesBelow.card + 1)).succ.primesBelow \ k.primesBelow, 1 / ↑p
The sum over primes k ≤ p ≤ 4^(π(k-1)+1) over 1/p (as a real number) is at least 1/2.
theorem not_summable_one_div_on_primes E3 #
¬Summable ({p | Nat.Prime p}.indicator fun n ↦ 1 / ↑n)
The sum over the reciprocals of the primes diverges.
theorem Nat.Primes.not_summable_one_div E1 #
¬Summable fun p ↦ 1 / ↑↑p
The sum over the reciprocals of the primes diverges.
theorem Nat.Primes.summable_rpow E1 #
∀ {r : ℝ}, (Summable fun p ↦ ↑↑p ^ r) ↔ r < -1
The series over p^r for primes p converges if and only if r < -1.