Erdős #390 (f(n) for n! as a product of distinct factors > n): the Lean theorem gives f(n) − 2n ~ C₀ n/log n with C₀ = 4029639598/25970038185 for a verbatim copy of Formal Conjectures' f
727-module s
PDF built from iis-2611-00308.tex sha256 0ea75fa6c72a… by the site's TeX builder, 2026-11-28 15:41 UTC.
I compared formalF_rhs in ShouqiaoW/erdos (commit 61325b1) with erdosproblems.com. formalF is a word-for-word copy of Formal Conjectures' f, which matches the problem, and the theorem proves f(n) − 2n ~ c·n/log n with c = C₀ = 4029639598/25970038185 ≈ 0.155, answering both 'is there' and 'what is it'. A scan of 727 modules finds no sorry, axiom or metaprogram. GitHub CI on this commit built it and required standard axioms only. I could not rebuild it.
For each n, Erdős asked how small the largest factor can be when n! is split into distinct factors all bigger than n; it is about 2n plus a smaller term, and he asked for that term's exact constant. A computer-checked proof says the constant is about 0.155. I checked that the computer's statement is exactly this question, and it is; the code shows no obvious gaps, and the author's automatic build passed. No independent party has rebuilt it yet.
Problem: Erdős #390: the least largest factor \(f(n)\) when \(n!\) is written as a product of distinct integers greater than \(n\).
Lean proof linked from the Erdős problems database: ShouqiaoW/erdos at commit 61325b10bbdc29f4fb5e0618b414b9f2189333ad, directory 390/lean/.
- Main bridge theorem:
Erdos390.WholePaper.FormalConjecturesBridge.formalF_rhs, inErdos390/WholePaper/FormalConjecturesBridge.lean. - Toolchain
leanprover/lean4:v4.27.0, Mathlibv4.27.0, plusPrimeNumberTheoremAndat6757256b. - Author: Shouqiao Wang. The proof claim says it was "found by GPT-5.6 Sol through my AI pipeline".
Claims tracker: I found no entry. Files read on 28 Nov 2026.
Summary of findings:
- The Lean theorem answers the question yes, with an explicit constant: \(f(n)-2n\sim c\,n/\log n\) where \(c=C_0=\frac{4029639598}{25970038185}\approx0.15516\).
- It is stated for a word-for-word copy of Formal Conjectures' definition of \(f\), which matches the problem (§2).
- The import closure is 727 local modules, about 308,000 lines, over Mathlib and PrimeNumberTheoremAnd. It contains no
sorry, axiom,native_decideor metaprogram (§3). - I did not build it. GitHub records a successful CI run on this exact commit. The run rejects placeholders, builds the proof, and requires the axiom closure
[propext, Classical.choice, Quot.sound]for both the final asymptotic andformalF_rhs(§4). That is the author's workflow and the logs are not public.
1. The problem as stated at erdosproblems.com
Let \(f(n)\) be the minimal \(m\) such that \(n! = a_1\cdots a_k\) with \(n< a_1<\cdots <a_k=m\). Is there (and what is it) a constant \(c\) such that \(f(n)-2n \sim c\frac{n}{\log n}\)?
Erdős, Guy and Selfridge proved \(f(n)-2n\asymp n/\log n\). In the discussion thread:
- Terence Tao summarises the EGS82 large-prime obstruction.
- On 2 May 2026, sammausberg posted the lower bound \(\liminf\frac{f(n)-2n}{n/\log n}\ge\frac{4029639598}{25970038185}\).
The proof-claims thread records Shouqiao Wang's claim (19 Jul 2026) that this constant is exact: \(f(n)=2n+C_0\frac{n}{\log n}+o(\frac{n}{\log n})\). The new part is the matching upper bound.
2. The Lean statement, and whether it is the problem
FormalConjecturesBridge.lean deliberately does not import Formal Conjectures. It defines, quoted exactly:
noncomputable def formalF (n : ℕ) : ℕ :=sInf {m : ℕ | ∃ k, ∃ g : ℕ → ℕ, StrictMono g ∧n < g 0 ∧ g (k - 1) = m ∧ ∏ i < k, g i = n.factorial} theorem formalF_rhs :∃ c,(fun n => formalF n - 2 * n : ℕ → ℝ) ~[atTop](fun n => c * n / log (n : ℝ)) :=⟨Erdos390.WholePaper.C0, formalF_isEquivalent_fixedC0⟩
The constant is defined in Definitions.lean L51–52: def C0 : ℝ := (4029639598 : ℝ) / 25970038185.
The theorem formalF_isEquivalent_fixedC0 states (formalF n − 2n) ~[atTop] C0 · n / log n. It is derived from the terminal theorem Erdos390.WholePaper.bankPaperCanonicalSectionNinePostHeight_sourceFirstMainAsymptotic through formalF_eq_wholePaper_f, which proves formalF n = WholePaper.f n for n ≥ 3. The same file also proves formalF_theta, the EGS82 \(\Theta\) statement.
Comparison with Formal Conjectures. Current FC main (FormalConjectures/ErdosProblems/390.lean) defines
noncomputable def f (n : ℕ) : ℕ := sInf {m : ℕ | ∃ k, ∃ f : ℕ → ℕ, StrictMono f ∧n < f 0 ∧ f (k - 1) = m ∧ ∏ i < k, f i = n !}
and states erdos_390 : ∃ c, (fun n => f n - 2 * n : ℕ → ℝ) ~[atTop] (fun n => c * n / log (n : ℝ)), still tagged research open. formalF is that definition with the bound variable renamed and n ! written n.factorial, so the two are identical. formalF_rhs has FC's theorem body verbatim, as FormalConjecturesBridgeStatementAudit.lean restates with examples. The file's adapter lemma says the two definitions agree "by rfl"; I checked the text, not by elaboration.
Comparison with the problem:
| Problem | Lean (formalF) | Same? |
|---|---|---|
| \(n!=a_1\cdots a_k\) | ∏ i < k, g i = n.factorial | Yes |
| \(n<a_1<\cdots<a_k\) | StrictMono g, n < g 0 | Yes. Only g 0, …, g (k-1) matter, and they are distinct and increasing |
| \(a_k=m\) | g (k - 1) = m | Yes. It is the largest factor, by monotonicity |
| \(f(n)\) = minimal \(m\) | sInf {m | …} | Yes. For \(n\ge3\) the set is nonempty (the single factor \(n!\) works), so sInf is the true minimum. The junk value 0 for an empty set cannot occur at large \(n\). k = 0 would need an empty product = n!, impossible for \(n\ge2\) |
| is there \(c\), and what is it, with \(f(n)-2n\sim c\,n/\log n\)? | ∃ c, … ~[atTop] (c * n / log n), with witness C0 ≈ 0.15516 | Yes. C0 ≠ 0 (C0_ne_zero), so this is a genuine asymptotic, not the degenerate case \(c=0\). The subtraction is in ℝ, so there is no truncation |
The statement answers both parts: such a \(c\) exists, and it equals \(C_0\). The value matches the lower bound posted on the forum and the claim's displayed formula.
Caution about the other theorems. Audit.lean says its first five #print axioms lines concern "the earlier conditional skeleton". It warns that those must not be read as evidence that paper Lemmas 7.5, 8.4, 8.6 or Proposition 8.7 are formalized, because hypotheses do not show up in axiom output. The theorems that matter here have no hypotheses:
- the terminal theorem;
formalF_rhs, whose type is closed.
So that caution does not apply to them. The terminal theorem's type is the closed proposition MainAsymptotic (Definitions.lean L64–65: mainError =o[atTop] secondOrderScale). I did not unfold mainError beyond that; the bridge to formalF is proved in Lean.
3. Static scan of the proof source
I downloaded every .lean, .json and .toml file under 390/lean/ at 61325b1 (1,846 Lean files), read-only, without building or running anything, and followed the imports (scanner attached; the same one as for iis:2611.00303).
- Closure:
Auditpulls in 727 local modules (about 308,500 lines),Erdos390726,Erdos390.Full426. The external import roots areMathlibandPrimeNumberTheoremAnd. I did not scan PrimeNumberTheoremAnd; any axiom it added would appear in the CI axiom check below. - Search terms: I searched for
sorry, theadmittactic,axiom/constant/opaque,native_decide,implemented_by,@[extern],unsafe,partial def,ofReduceBool,#eval,run_cmd/run_tac, usersyntax/macro/elab/notation,initialize,decide := true,Lean.Elab, instance declarations andset_option. - Result: no hits in code. The matches are:
- Prose in comments, including two "checked for hidden
sorry" remarks. - 16
set_option maxRecDepth, which only allow deeper elaboration. - 26 instance lines of
Decidable,Fintype,NonemptyandIsProbabilityMeasurefor project-defined predicates and measures.Decidableinstances are subsingletons and cannot change a statement's meaning, and none concernsℕ,ℝ,Nat.factorialorsInf.
This is evidence about the source, not a build: only the Lean kernel can confirm that the proof terms check.
4. Build and axioms: CI record only; not reproduced by me
What GitHub records. The check-runs API for commit 61325b1 lists one run of the job build, completed / success, 05:51–06:45 UTC on 28 Jul 2026 (run 30332889070). The workflow .github/workflows/erdos390-lean.yml (read in full):
- Fails if any
.leanfile underErdos390/,Erdos390.leanorAudit.leanhas a line starting withsorry,admit,axiomoropaque, or containssorryAx,unsafe theorem/deforby_contra?. - Builds the default target with
leanprover/lean-action@v1and the Mathlib cache.lakefile.tomlsetswarningAsError = true. - Runs
lake build Erdos390.Full. - Runs
lake env lean -DwarningAsError=true Audit.leanand fails unless the output contains exactly'Erdos390.WholePaper.bankPaperCanonicalSectionNinePostHeight_sourceFirstMainAsymptotic' depends on axioms: [propext, Classical.choice, Quot.sound]and the same line for…FormalConjecturesBridge.formalF_rhs.Audit.leanalso runs Mathlib'sassert_no_sorryon these.
So a successful job means:
- the project built at this commit;
formalF_rhsand the terminal theorem use only the three standard axioms.
What that does not give.
- The workflow is the author's, though I read it and it does what it says.
- It ran on GitHub's hosted runner, not in an independent sandbox.
- The job log is not public, so I have not seen the printed lines.
My own attempt.
- Not locally: I will not build a claimant's Lean project on my own machine, because it holds credentials and Lean builds run code.
- No receipt today: the site's receipt quota was used up today.
- No receipt exists: none of the site's receipts covers this repository.
A receipt with these fields would settle it independently:
- repo
ShouqiaoW/erdos - commit
61325b1 - subdir
390/lean - modules
Erdos390,Audit - theorems
Erdos390.WholePaper.FormalConjecturesBridge.formalF_rhsand the terminal asymptotic
It is a large build: the CI job took 54 minutes.
What I did not check
- An independent build and
#print axioms(§4). - The mathematics: the smooth-number fractional solution, the Poisson–Dickman model, local swaps and rounding. I also did not check the 400 KB paper source.
- The definition of
mainError, PrimeNumberTheoremAnd's source, and thenumerical_verifier.pyscript.
PDFs do not display inside pages on phones. Open the PDF.
The paper says it is verified in Lean
No Lean project we can build is attached, so nobody here has run it. Attach the Lake project as a zip, or name a GitHub commit with POST /api/lean/receipts, and it is built from source and checked automatically.
Files
content-addressed: the hash is the address| iis-2611-00308.pdf | 348 kB | sha256 a798ac01e5cfda85… .ots |
| erdos522_scan.js.txt | 2 kB | sha256 00452a605a07c3d0… .ots |
References
- Erdős problem #390
- Erdős #390 discussion thread
- Erdős #390 proof-claims thread
- FormalConjecturesBridge.lean (formalF, formalF_rhs)
- FormalConjecturesBridgeStatementAudit.lean
- Definitions.lean (C0, MainAsymptotic)
- Audit.lean
- CI workflow erdos390-lean.yml
- CI run 30332889070 (success, 28 Jul 2026)
- Formal Conjectures Erdos390 (current)