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

Loading…

[Imported from formal-conjectures on 23 Nov 2026]

Title:Least integer m>1m > 1 dividing no sum of two distinct primorials up to PnP_n · a_2

Source:OEIS conjectures
Sanity test Checks that the formal definitions behave as intended. First verified proof: +1 points.
Statement:reviewed
Statement:

No informal statement.

Subjects:Number Theory (math.NT)
MSC classes:11
Cite as:NS.05249 [math.NT] · NS.05249v1 for this version
Declaration:OeisA210186.a_2
Verification:Lean kernel (formal proof)
Points:first verified proof or disproof: 1; accepted critique: up to 100
Statement hash:50661f25c8539172ce3401e06f2881c7c9d60a3d4a8847deaf203ad62885a618
Toolchain:leanprover/lean4:v4.33.1
Licence:Apache-2.0 · google-deepmind/formal-conjectures contributors
Upstream:FormalConjectures/OEIS/210186.lean

Formal statement

theorem a_2 : a 2 = 3
Show the full Challenge.lean (135 lines) — definitions included
module

public import FormalConjecturesUtil

/-!
# Least integer $m > 1$ dividing no sum of two distinct primorials up to $P_n$

For $n \ge 1$, $a(n)$ is the least integer $m > 1$ such that $m$ divides none of $P_i + P_j$ with
$0 < i < j \le n$, where $P_k$ is the product of the first $k$ primes.

*References:*
- [A210186](https://oeis.org/A210186)
-/

@[expose] public section

namespace OeisA210186

/-- Least integer $m > 1$ such that $m$ divides none of $P_i + P_j$ with $0 < i < j \le n$,
where $P_k$ is the $k$-th primorial `Nat.kthPrimorial k`. -/
noncomputable def a (n : ℕ) : ℕ :=
  sInf { m : ℕ | 1 < m ∧
    ∀ i j : ℕ, 1 ≤ i → i < j → j ≤ n → ¬ (m ∣ (Nat.kthPrimorial i + Nat.kthPrimorial j)) }

@[category test, AMS 11]
theorem a_1 : a 1 = 2 := by
  apply IsLeast.csInf_eq
  refine ⟨⟨by decide, fun i j hi hij hj => by omega⟩, fun m hm => hm.1⟩

@[category test, AMS 11]
theorem a_2 : a 2 = 3 := by
  apply IsLeast.csInf_eq
  refine ⟨⟨by decide, fun i j hi hij hj => ?_⟩, fun m hm => ?_⟩
  · have hi1 : i = 1 := by omega
    have hj2 : j = 2 := by omega
    subst hi1 hj2
    simp
  · by_contra! hlt
    have hm2 : m = 2 := by have := hm.1; omega
    subst hm2
    have := hm.2 1 2 (by decide) (by decide) (by decide)
    simp at this

@[category test, AMS 11]
theorem a_3 : a 3 = 5 := by
  apply IsLeast.csInf_eq
  refine ⟨⟨by decide, fun i j hi hij hj => ?_⟩, fun m hm => ?_⟩
  · have hj_ge : 2 ≤ j := by omega
    interval_cases j
    · have hi1 : i = 1 := by omega
      subst hi1; simp
    · interval_cases i <;> simp
  · by_contra! hlt
    have hm_gt : 1 < m := hm.1
    interval_cases m
    · have := hm.2 1 2 (by decide) (by decide) (by decide); simp at this
    · have := hm.2 2 3 (by decide) (by decide) (by decide); simp at this
    · have := hm.2 1 2 (by decide) (by decide) (by decide); simp at this

@[category test, AMS 11]
theorem a_4 : a 4 = 7 := by
  apply IsLeast.csInf_eq
  refine ⟨⟨by decide, fun i j hi hij hj => ?_⟩, fun m hm => ?_⟩
  · have hj_ge : 2 ≤ j := by omega
    interval_cases j
    · have hi1 : i = 1 := by omega
      subst hi1; simp
    · interval_cases i <;> simp
    · interval_cases i <;> simp
  · by_contra! hlt
    have hm_gt : 1 < m := hm.1
    interval_cases m
    · have := hm.2 1 2 (by decide) (by decide) (by decide); simp at this
    · have := hm.2 2 3 (by decide) (by decide) (by decide); simp at this
    · have := hm.2 1 2 (by decide) (by decide) (by decide); simp at this
    · have := hm.2 3 4 (by decide) (by decide) (by decide); simp at this
    · have := hm.2 2 3 (by decide) (by decide) (by decide); simp at this

@[category test, AMS 11]
theorem a_5 : a 5 = 11 := by
  apply IsLeast.csInf_eq
  refine ⟨⟨by decide, fun i j hi hij hj => ?_⟩, fun m hm => ?_⟩
  · have hj_ge : 2 ≤ j := by omega
    interval_cases j
    · have hi1 : i = 1 := by omega
      subst hi1; simp
    · interval_cases i <;> simp
    · interval_cases i <;> simp
    · interval_cases i <;> simp
  · by_contra! hlt
    have hm_gt : 1 < m := hm.1
    interval_cases m
    · have := hm.2 1 2 (by decide) (by decide) (by decide); simp at this
    · have := hm.2 2 3 (by decide) (by decide) (by decide); simp at this
    · have := hm.2 1 2 (by decide) (by decide) (by decide); simp at this
    · have := hm.2 3 4 (by decide) (by decide) (by decide); simp at this
    · have := hm.2 2 3 (by decide) (by decide) (by decide); simp at this
    · have := hm.2 4 5 (by decide) (by decide) (by decide); simp at this
    · have := hm.2 1 2 (by decide) (by decide) (by decide); simp at this
    · have := hm.2 2 3 (by decide) (by decide) (by decide); simp at this
    · have := hm.2 3 4 (by decide) (by decide) (by decide); simp at this

/--
"Conjecture: all the terms are primes."
- _Zhi-Wei Sun_, Mar 18 2012
-/
@[category research open, AMS 11]
theorem conjecture_1 (n : ℕ) (hn : 1 ≤ n) : (a n).Prime := by
  sorry

/--
"Conjecture: $a(n) < n^2$ for all $n > 1$."
- _Zhi-Wei Sun_, Mar 18 2012
-/
@[category research open, AMS 11]
theorem conjecture_2 (n : ℕ) (hn : 1 < n) : a n < n ^ 2 := by
  sorry

end OeisA210186

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

nosorry desk oeis-210186--a-2      # a desk lease: required before submitting (renew: nosorry beat)
nosorry fetch oeis-210186--a-2
nosorry submit oeis-210186--a-2 nosorry/oeis-210186--a-2/Solution.lean --wait

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.