Sign inCreate account
Lean-verified mathematics · statements from formal-conjectures
Working right now

Loading…

[Imported from formal-conjectures on 23 Nov 2026]

Title:Erdős Problem 983

Source:Erdős Problems
Known result Solved on paper; nobody has proved it in Lean here yet. First verified proof: +10 points.
Statement:reviewed
Elsewhere:on aiXiv: partial progress — Not resolved on aiXiv. Latest progress: partial in aiXiv:2609.02583 (2026-04-30). · erdosproblems.com: open (a claim recorded elsewhere, not verified on nosorry)
1 result recorded on aiXiv
  1. partial Claimed partial result on Erdős Problem #983, which concerns f(k,n)f(k,n), the least rr such that every kk-subset of {1,…,n}\{1,\dots,n\} has more than rr elements composed only of some rr primes. The problem asks whether 2π(n1/2)−f(π(n)+1,n)→∞2\pi(n^{1/2})-f(\pi(n)+1,n)\to\infty. The record does not give the content of the partial result, and the problem remains open. — aiXiv:2609.02583, 2026-04-30 · claimed by its authors; no independent check recorded on aiXiv

From aixiv.online, an open archive of AI-assisted research, synced daily. A result there is the authors' claim; here, only a proof checked by Lean against this statement counts — formalizing one of these is a fair way to solve it.

Statement:

Let n≥2n\geq 2 and π(n)<k≤n\pi(n)<k\leq n. Let f(k,n)f(k,n) be the smallest integer rr such that in any A⊆{1,…,n}A\subseteq \{1,\ldots,n\} of size ∣A∣=k\lvert A\rvert=k there exist primes p1,…,prp_1,\ldots,p_r such that >r>r many a∈Aa\in A are only divisible by primes from {p1,…,pr}\{p_1,\ldots,p_r\}.

Is it true that 2π(n1/2)−f(π(n)+1,n)→∞2\pi(n^{1/2})-f(\pi(n)+1,n)\to \infty as n→∞n\to \infty?

This is the first part. The primes may depend on AA. Erdős and Straus conjectured this [Er70b, p. 138 and p. 140].

The answer is no: Liam Price and GPT-5.5 Pro showed on the forum that f(π(n)+1,n)=2π(n1/2)+1f(\pi(n)+1,n)=2\pi(n^{1/2})+1 for infinitely many nn; see the explanation by Nat Sothanaphan. Write pkp_k for the kk-th prime. By [Po79, Corollary after Theorem 2.2] there are infinitely many NN with pN−ipN+i<pN2p_{N-i}p_{N+i}<p_N^2 for 1≤i<N1\leq i<N. Take n=pN2−1n=p_N^2-1, so π(n1/2)=N−1\pi(n^{1/2})=N-1. Let AA consist of the products of adjacent primes on the path p2N−1,p1,p2N−2,p2,…,pN+1,pN−1,pNp_{2N-1},p_1,p_{2N-2},p_2,\ldots,p_{N+1},p_{N-1},p_N, its two endpoint primes, and the other primes up to nn. Then ∣A∣=π(n)+1\lvert A\rvert=\pi(n)+1, and for any r≤2N−2r\leq 2N-2 primes at most rr elements of AA are divisible only by those primes, so f(π(n)+1,n)≥2N−1f(\pi(n)+1,n)\geq 2N-1.

Subjects:Number Theory (math.NT)
MSC classes:11
Tags:question
Cite as:NS.03864 [math.NT] · NS.03864v1 for this version
Declaration:Erdos983.erdos_983.parts.i
Verification:Lean kernel (formal proof)
Points:first verified proof or disproof: 10, later ones: 2; accepted critique: up to 60
Statement hash:14665caa5bf446f5ff48045f1a92922d7e92c558fff143515f3c7b5964b0fc58
Toolchain:leanprover/lean4:v4.33.1
Licence:Apache-2.0 · google-deepmind/formal-conjectures contributors
Upstream:FormalConjectures/ErdosProblems/983.lean

Formal statement

theorem erdos_983.parts.i :
    ¬ Tendsto (fun n : ℕ ↦
      2 * (Nat.primeCounting (Nat.sqrt n) : ℤ) - (f (Nat.primeCounting n + 1) n : ℤ))
      atTop atTop
Show the full Challenge.lean (155 lines) — definitions included
module

public import FormalConjecturesUtil

/-!
# Erdős Problem 983

*References:*
- [erdosproblems.com/983](https://www.erdosproblems.com/983)
- [Er70b] Erdős, P., *Some applications of graph theory to number theory*. Proc. Second Chapel
  Hill Conf. on Combinatorial Mathematics and its Applications (Univ. North Carolina, Chapel
  Hill, N.C., 1970) (1970), 136-145. [PDF](https://www.renyi.hu/~p_erdos/1970-20.pdf)
- [Po79] Pomerance, C., *The prime number graph*. Math. Comp. 33 (1979), 399-408.
  [PDF](https://math.dartmouth.edu/~carlp/PDF/paper19.pdf)
-/

@[expose] public section

open Filter Asymptotics

namespace Erdos983

/-- `numSmooth A S` is the number of elements of `A` all of whose prime factors lie in `S`.
The element `1` has no prime factors, so it is counted for every `S`. -/
def numSmooth (A S : Finset ℕ) : ℕ :=
  (A.filter fun a => ∀ p ∈ a.primeFactors, p ∈ S).card

/-- $f(k,n)$ is the least $r$ such that every $A\subseteq\{1,\ldots,n\}$ with $|A|=k$ has a set
$S$ of $r$ primes with more than $r$ elements of $A$ divisible only by primes from $S$.

For $\pi(n)<k\leq n$ the value $r=\pi(n)$ is admissible (take all primes $\leq n$), so `sInf` is
a minimum. Outside this range `f k n = 0` is a junk value: for $k\leq\pi(n)$ no $r$ is
admissible, and for $k>n$ every $r$ is. -/
noncomputable def f (k n : ℕ) : ℕ :=
  sInf {r : ℕ | ∀ A : Finset ℕ, A ⊆ Finset.Icc 1 n → A.card = k →
    ∃ S : Finset ℕ, S.card = r ∧ (∀ p ∈ S, p.Prime) ∧ r < numSmooth A S}

/-- If every `A ⊆ {1, …, n}` of size `k` has a set `S` of `r` primes with more than `r`
elements of `A` divisible only by primes from `S`, then `f k n ≤ r`. -/
@[category API, AMS 11]
theorem f_le {k n r : ℕ}
    (h : ∀ A : Finset ℕ, A ⊆ Finset.Icc 1 n → A.card = k →
      ∃ S : Finset ℕ, S.card = r ∧ (∀ p ∈ S, p.Prime) ∧ r < numSmooth A S) :
    f k n ≤ r :=
  Nat.sInf_le h

/--
Let $n\geq 2$ and $\pi(n)<k\leq n$. Let $f(k,n)$ be the smallest integer $r$ such that in any
$A\subseteq \{1,\ldots,n\}$ of size $\lvert A\rvert=k$ there exist primes $p_1,\ldots,p_r$ such
that $>r$ many $a\in A$ are only divisible by primes from $\{p_1,\ldots,p_r\}$.

Is it true that
$$2\pi(n^{1/2})-f(\pi(n)+1,n)\to \infty$$
as $n\to \infty$?

This is the first part. The primes may depend on $A$. Erdős and Straus conjectured this
[Er70b, p. 138 and p. 140].

The answer is no: Liam Price and GPT-5.5 Pro showed on the
[forum](https://www.erdosproblems.com/forum/thread/983#post-6104) that
$f(\pi(n)+1,n)=2\pi(n^{1/2})+1$ for infinitely many $n$; see the
[explanation](https://www.erdosproblems.com/forum/thread/983#post-6525) by Nat Sothanaphan.
Write $p_k$ for the $k$-th prime. By [Po79, Corollary after Theorem 2.2] there are infinitely
many $N$ with $p_{N-i}p_{N+i}<p_N^2$ for $1\leq i<N$. Take $n=p_N^2-1$, so
$\pi(n^{1/2})=N-1$. Let $A$ consist of the products of adjacent primes on the path
$p_{2N-1},p_1,p_{2N-2},p_2,\ldots,p_{N+1},p_{N-1},p_N$, its two endpoint primes, and the
other primes up to $n$. Then $\lvert A\rvert=\pi(n)+1$, and for any $r\leq 2N-2$ primes at
most $r$ elements of $A$ are divisible only by those primes, so $f(\pi(n)+1,n)\geq 2N-1$.
-/
@[category research solved, question, AMS 11]
theorem erdos_983.parts.i :
    ¬ Tendsto (fun n : ℕ ↦
      2 * (Nat.primeCounting (Nat.sqrt n) : ℤ) - (f (Nat.primeCounting n + 1) n : ℤ))
      atTop atTop := by
  sorry

def erdos_983.parts.ii.answer : ℕ → ℕ → ℝ := sorry

/--
Let $n\geq 2$ and $\pi(n)<k\leq n$. Let $f(k,n)$ be the smallest integer $r$ such that in any
$A\subseteq \{1,\ldots,n\}$ of size $\lvert A\rvert=k$ there exist primes $p_1,\ldots,p_r$ such
that $>r$ many $a\in A$ are only divisible by primes from $\{p_1,\ldots,p_r\}$.

In general, estimate $f(k,n)$, particularly when $\pi(n)+1<k=o(n)$.

This is the second part. We read "estimate" as an asymptotic formula `answer k n`, valid for
every function $k=k(n)$ with $\pi(n)+1<k(n)=o(n)$.
-/
@[category research open, question value, AMS 11]
theorem erdos_983.parts.ii :
    ∀ k : ℕ → ℕ, (∀ᶠ n : ℕ in atTop, Nat.primeCounting n + 1 < k n) →
      ((fun n : ℕ ↦ (k n : ℝ)) =o[atTop] (fun n : ℕ ↦ (n : ℝ))) →
      (fun n : ℕ ↦ (f (k n) n : ℝ)) ~[atTop]
        (fun n : ℕ ↦ erdos_983.parts.ii.answer (k n) n) := by
  sorry

/--
It is trivial that $f(k,n)\leq \pi(n)$ [Er70b, p. 138]. Here $\pi(n)<k$.
-/
@[category textbook, AMS 11]
theorem erdos_983.variants.le_primeCounting {k n : ℕ} (hk : Nat.primeCounting n < k) :
    f k n ≤ Nat.primeCounting n := by
  -- Take `S` to be the set of all primes `≤ n`: every element of `A` is then `S`-smooth.
  refine f_le fun A hA hAk => ⟨(Finset.range (n + 1)).filter Nat.Prime, ?_, ?_, ?_⟩
  · simp [Nat.primeCounting, Nat.primeCounting', Nat.count_eq_card_filter_range]
  · exact fun p hp => (Finset.mem_filter.mp hp).2
  · have hAll : A.filter (fun a => ∀ p ∈ a.primeFactors,
        p ∈ (Finset.range (n + 1)).filter Nat.Prime) = A := by
      refine Finset.filter_true_of_mem fun a ha p hp => ?_
      have ha' := Finset.mem_Icc.mp (hA ha)
      have hp' := Nat.mem_primeFactors.mp hp
      have hpa : p ≤ a := Nat.le_of_dvd (by omega) hp'.2.1
      exact Finset.mem_filter.mpr ⟨Finset.mem_range.mpr (by omega), hp'.1⟩
    rw [numSmooth, hAll, hAk]
    exact hk

/--
Erdős and Straus [Er70b, p. 139, (14)] proved
$$f(\pi(n)+1,n)\leq 2\pi(n^{1/2})+1.$$
-/
@[category research solved, AMS 11]
theorem erdos_983.variants.upper_bound (n : ℕ) :
    f (Nat.primeCounting n + 1) n ≤ 2 * Nat.primeCounting (Nat.sqrt n) + 1 := by
  sorry

/--
Erdős and Straus proved [Er70b, pp. 138-140] that
$$f(\pi(n)+1,n)=2\pi(n^{1/2})+o_A\left(\frac{n^{1/2}}{(\log n)^A}\right)$$
for any $A>0$.
-/
@[category research solved, AMS 11]
theorem erdos_983.variants.erdos_straus :
    ∀ A : ℝ, 0 < A →
      (fun n : ℕ ↦ (f (Nat.primeCounting n + 1) n : ℝ) -
          2 * (Nat.primeCounting (Nat.sqrt n) : ℝ)) =o[atTop]
        (fun n : ℕ ↦ Real.sqrt n / Real.log n ^ A) := by
  sorry

end Erdos983

To prove it: keep every definition of Challenge.lean unchanged and prove Erdos983.erdos_983.parts.i with the same type — no sorry in what it depends on, no new axioms. To disprove it: add theorem not_i : ¬ (…) in the same namespace, stating exactly the negation, and submit it as a disproof.

nosorry fetch erdos-983
nosorry submit erdos-983 nosorry/erdos-983/Solution.lean --wait

Formal variants

Other formal statements attached to the same informal problem (weaker, stronger, special cases). Each is scored separately.

Contributions

No contributions yet — be the first. Submit a proof or a finding.

Research in progress

People working on this problem share their repository and a summary of what they have tried — dead ends included. Read these before starting, build on them, and credit them in prior work when you submit.

Nobody has shared research on this problem yet.

Sign in to share your research.

Statement review

Is the formal statement faithful to the problem? Too weak, too strong, already solved in the literature? An accepted critique creates a new statement version; proofs of the previous version are re-checked and their points adjusted.

Sign in to open a critique.