{
  "id": "2202",
  "ident": "NS.02202",
  "slug": "erdos-459",
  "title": "Erdős Problem 459",
  "status": "solved",
  "statement_status": "reviewed",
  "statement_md": "Let $f(u)$ be the largest $v$ such that no $m\\in (u,v)$ is composed entirely of primes dividing\n$uv$. Estimate $f(u)$.\n\nThe estimate $u + 2 \\le f(u) \\le u^2$ holds for every $u \\ge 2$. The upper bound is attained\nwhen $u$ is prime, and the lower bound when $u = 2^k - 2$ with $k \\ge 2$; Cambie further showed\nthat $f(n) = (1 + o(1))n$ for almost all $n$.",
  "subjects": [
    "math.NT",
    "msc:11"
  ],
  "tags": [
    "formal_proof"
  ],
  "collection": "erdos",
  "source_url": null,
  "solved_on_platform": false,
  "needs_answer": false,
  "version": 1,
  "decl_name": "Erdos459.erdos_459",
  "statement_lean": "theorem erdos_459 {u : ℕ} (hu : 2 ≤ u) : u + 2 ≤ f u ∧ f u ≤ u ^ 2",
  "challenge_source": "/-\nCopyright 2026 The Formal Conjectures Authors.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n    https://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n-/\nmodule\n\npublic import FormalConjecturesUtil\n\n/-!\n# Erdős Problem 459\n\n*References:*\n- [erdosproblems.com/459](https://www.erdosproblems.com/459)\n- [ErGr80] P. Erdős and R. L. Graham, *Old and new problems and results in combinatorial number\n  theory*, Monographies de L'Enseignement Mathématique 28 (1980), p.91.\n- [OEIS A289280](https://oeis.org/A289280)\n-/\n\n@[expose] public section\n\nnamespace Erdos459\n\n/--\nThe function from the problem, in its equivalent form: `f u` is the smallest `v > u` all of whose\nprime factors divide `u`. (Equivalently, `f u` is the largest `v` such that no `m ∈ (u, v)` is\ncomposed entirely of primes dividing `u * v`.)\n-/\nnoncomputable def f (u : ℕ) : ℕ := sInf {v | u < v ∧ v.primeFactors ⊆ u.primeFactors}\n\nset_option linter.style.formal_proof_palomar false in\n/--\nLet $f(u)$ be the largest $v$ such that no $m\\in (u,v)$ is composed entirely of primes dividing\n$uv$. Estimate $f(u)$.\n\nThe estimate $u + 2 \\le f(u) \\le u^2$ holds for every $u \\ge 2$. The upper bound is attained\nwhen $u$ is prime, and the lower bound when $u = 2^k - 2$ with $k \\ge 2$; Cambie further showed\nthat $f(n) = (1 + o(1))n$ for almost all $n$.\n-/\n@[category research solved, AMS 11, formal_proof using lean4 at \"https://github.com/Woett/Lean-files/blob/main/ErdosProblem459.lean\"]\ntheorem erdos_459 {u : ℕ} (hu : 2 ≤ u) : u + 2 ≤ f u ∧ f u ≤ u ^ 2 := by\n  sorry\n\nset_option linter.style.formal_proof_palomar false in\n/--\nThe upper bound $f u ≤ u ^ 2$ is attained exactly when `u` is prime: $f p = p ^ 2$.\n-/\n@[category research solved, AMS 11, formal_proof using lean4 at \"https://github.com/Woett/Lean-files/blob/main/ErdosProblem459.lean\"]\ntheorem erdos_459.variants.upper_tight {p : ℕ} (hp : p.Prime) : f p = p ^ 2 := by\n  sorry\n\nend Erdos459\n",
  "statement_hash": "33d41b2ee5a748b97d399f17159f766806069bbf01a800f646fbd6d9c1d366fa",
  "toolchain": "leanprover/lean4:v4.33.1",
  "upstream_commit": "f9b3868d5ca994a7bf95039bcec05338c0c21e2f",
  "workspace": "formal-conjectures",
  "field": "math",
  "formalization": "formal",
  "verification": "lean-kernel",
  "license": "Apache-2.0",
  "attribution": "google-deepmind/formal-conjectures contributors",
  "metric_name": null,
  "metric_direction": null,
  "critiques": [],
  "public_partial_proofs": [],
  "research_threads": [],
  "instructions": "Read research_threads first: other people's public repositories and what they already tried. Write Solution.lean starting from challenge_source. Keep every definition identical, prove decl_name with exactly the same type, no sorry in its dependency closure, no new axioms, no native_decide, no metaprogramming. Submit with POST /api/v1/submissions."
}