{
  "id": "3608",
  "ident": "NS.03608",
  "slug": "erdos-913",
  "title": "Erdős Problem 913",
  "status": "open",
  "statement_status": "reviewed",
  "statement_md": "Are there infinitely many $n$ such that if\n$$\n  n(n + 1) = \\prod_i p_i^{k_i}\n$$\nis the factorisation into distinct primes then all exponents $k_i$ are distinct?",
  "subjects": [
    "math.NT",
    "msc:11"
  ],
  "tags": [
    "question"
  ],
  "collection": "erdos",
  "source_url": "https://www.erdosproblems.com/913",
  "solved_on_platform": false,
  "needs_answer": false,
  "version": 1,
  "decl_name": "Erdos913.erdos_913",
  "statement_lean": "theorem erdos_913 :\n    { n | Set.InjOn (n * (n + 1)).factorization (n * (n + 1)).primeFactors }.Infinite",
  "challenge_source": "/-\nCopyright 2025 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 913\n\n*Reference:* [erdosproblems.com/913](https://www.erdosproblems.com/913)\n\nReviewed by @b-mehta on 2025-05-27\n-/\n\n@[expose] public section\n\nnamespace Erdos913\n\n/--\nAre there infinitely many $n$ such that if\n$$\n  n(n + 1) = \\prod_i p_i^{k_i}\n$$\nis the factorisation into distinct primes then all exponents $k_i$ are distinct?\n-/\n@[category research open, question, AMS 11]\ntheorem erdos_913 :\n    { n | Set.InjOn (n * (n + 1)).factorization (n * (n + 1)).primeFactors }.Infinite := by\n  sorry\n\n/--\nIt is likely that there are infinitely many primes $p$ such that $8p^2 - 1$ is also prime.\n-/\n@[category research open, AMS 11]\ntheorem erdos_913.variants.infinite_many_8p_sq_add_one_primes :\n    { p | p.Prime ∧ (8 * p ^ 2 - 1).Prime }.Infinite := by\n  sorry\n\n/-- If there are infinitely many primes $p$ such that $8p^2 - 1$ is prime, then this is true. -/\n@[category research solved, AMS 11]\ntheorem erdos_913.variants.conditional (h : { p | p.Prime ∧ (8 * p ^ 2 - 1).Prime }.Infinite) :\n    { n | Set.InjOn (n * (n + 1)).factorization (n * (n + 1)).primeFactors }.Infinite := by\n  set S := { p | p.Prime ∧ (8 * p ^ 2 - 1).Prime }\n  let f : ℕ → ℕ := fun p ↦ 8 * p ^ 2 - 1\n  have hS : ∀ p, p.Prime → 1 < 8 * p ^ 2 := by\n    rintro p hp\n    nlinarith [hp.two_le]\n  have : S.InjOn f := by\n    simp only [Set.InjOn, f]\n    rintro a ha b hb h\n    rw [tsub_left_inj (hS a ha.1).le (hS b hb.1).le] at h\n    simpa using h\n  refine ((h.sdiff (Set.finite_singleton 2)).image (this.mono Set.sdiff_subset)).mono ?_\n  simp only [Set.image_subset_iff, Set.preimage_ofPred_eq, S]\n  rintro p ⟨⟨hp, hp'⟩, hp''⟩\n  simp only [Set.mem_singleton_iff] at hp''\n  have fac : (f p * (f p + 1)).factorization =\n      Finsupp.single (8 * p ^ 2 - 1) 1 + (Finsupp.single p 2 + Finsupp.single 2 3) := by\n    simp only [f, Nat.sub_add_cancel (hS p hp).le]\n    have : 2 ≤ p := hp.two_le\n    rw [Nat.factorization_mul hp'.ne_zero (by positivity),\n      Nat.factorization_mul (by positivity) (by positivity), hp'.factorization,\n      hp.factorization_pow, (show 8 = 2 ^ 3 from rfl), Nat.prime_two.factorization_pow,\n      add_comm (Finsupp.single 2 3)]\n  have aux₂ : (fun₀ | 2 => 3).support = {2} := by simp\n  have aux₁ : ((fun₀ | p => 2) + fun₀ | 2 => 3).support = {p, 2} := by\n    rw [Finsupp.support_single_add (by simp [hp'']) (by simp), Finset.cons_eq_insert, aux₂]\n  have aux₃ : p + 1 < 8 * p ^ 2 := by\n    replace hp := hp.two_le\n    zify at hp ⊢\n    linear_combination (8 * p + 15 : ℤ) * hp\n  have aux₄ : 8 * p ^ 2 - 1 ≠ p := by\n    rw [ne_eq, tsub_eq_iff_eq_add_of_le (hS p hp).le]\n    exact aux₃.ne'\n  have aux₅ : 8 * p ^ 2 - 1 ≠ 2 := by\n    omega\n  have pf : (f p * (f p + 1)).primeFactors = {8 * p ^ 2 - 1, p, 2} := by\n    rw [← Nat.support_factorization, fac, Finsupp.support_single_add _ (by simp),\n      Finset.cons_eq_insert, aux₁]\n    simp [*]\n  simp only [Set.mem_ofPred_eq]\n  rw [fac, pf]\n  simp only [Finsupp.coe_add, Finset.coe_insert, Finset.coe_singleton]\n  rw [Set.injOn_insert (by simp [*]), Set.injOn_insert (by simp [hp''])]\n  simp [aux₄, hp'', Ne.symm, aux₅]\n\nend Erdos913\n",
  "statement_hash": "b53c40b9f4723d59355ab53e2cf5a9e5d877c8fb6ca2dc9d025c9dfc51566837",
  "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."
}