/- Copyright 2026 The Formal Conjectures Authors. Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at https://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License. -/ module public import FormalConjecturesUtil /-! # Erdős Problem 445 *References:* - [erdosproblems.com/445](https://www.erdosproblems.com/445) - [He00] Heath-Brown, D. R., Arithmetic applications of {K}loosterman sums. Nieuw Arch. Wiskd. (5) (2000), 380--384. - [MathOverflow](https://mathoverflow.net/questions/69509/small-residue-classes-with-small-reciprocal) -/ @[expose] public section open Filter namespace Erdos445 /-- The property that there exist $a,b\in(n,n+p^c)$ such that $ab\equiv 1\pmod{p}$. -/ def Erdos445Prop (c : ℝ) (p n : ℕ) : Prop := ∃ a b : ℕ, n < a ∧ (a : ℝ) < (n : ℝ) + (p : ℝ) ^ c ∧ n < b ∧ (b : ℝ) < (n : ℝ) + (p : ℝ) ^ c ∧ a * b ≡ 1 [MOD p] /-- Is it true that, for any $c>1/2$, if $p$ is a sufficiently large prime then, for any $n\geq 0$, there exist $a,b\in(n,n+p^c)$ such that $ab\equiv 1\pmod{p}$? This is discussed in this MathOverflow question [MathOverflow]. -/ @[category research open, question, AMS 11] theorem erdos_445 : ∀ c : ℝ, c > 1 / 2 → ∀ᶠ p : ℕ in atTop, p.Prime → ∀ n : ℕ, Erdos445Prop c p n := by sorry /-- Heilbronn (unpublished) proved this for $c$ sufficiently close to $1$. -/ @[category research solved, AMS 11] theorem erdos_445.variants.heilbronn : ∃ c₀ < 1, ∀ c : ℝ, c > c₀ → ∀ᶠ p : ℕ in atTop, p.Prime → ∀ n : ℕ, Erdos445Prop c p n := by sorry /-- Heath-Brown [He00] used Kloosterman sums to prove this for all $c>3/4$. -/ @[category research solved, AMS 11] theorem erdos_445.variants.heath_brown : ∀ c : ℝ, c > 3 / 4 → ∀ᶠ p : ℕ in atTop, p.Prime → ∀ n : ℕ, Erdos445Prop c p n := by sorry /-- Small example: for $p=5$, $c=1$, $n=0$, the pair $(2,3) \in (0,5)$ satisfies $2 \cdot 3 = 6 \equiv 1 \pmod{5}$. -/ @[category test, AMS 11] theorem erdos_445.test.small_example : Erdos445Prop 1 5 1 := by refine ⟨2, 3, by omega, ?_, by omega, ?_, by decide⟩ all_goals simp only [Real.rpow_one]; norm_num end Erdos445