Andrica's inequality for
ProvedAndricaConjecture.andrica_up_to_one_millionnumber-theoryprimes
Let denote the th prime, indexed from zero, so , , . For every with ,
where is the nonnegative real square root.
This is Andrica's conjecture restricted to primes up to ; the conjecture for all is open. The inequality is equivalent to the gap bound . The statement is a subrange of the mission milestone AndricaConjecture.andrica_up_to_maximal_gap_80, which asks for the same inequality whenever .
Formalization Note The prime is Nat.nth Nat.Prime n. The hypothesis bounds the prime , not the index . Both primes are cast to before Real.sqrt is applied.
Preamble
import Mathlib
Formal statement
namespace AndricaConjecture
theorem andrica_up_to_one_million (n : Nat)
(hn : Nat.nth Nat.Prime n ≤ 1000000) :
Real.sqrt (Nat.nth Nat.Prime (n + 1) : Real) -
Real.sqrt (Nat.nth Nat.Prime n : Real) < 1 := by sorry
end AndricaConjecture
Source
Dorin Andrica, Note on a conjecture in prime number theory, Studia Univ. Babeș-Bolyai Math. 31 (1986), no. 4, 44–48, https://zbmath.org/0623.10030 ; finite range of mission milestone AndricaConjecture.andrica_up_to_maximal_gap_80