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

Loading…

[Imported from formal-conjectures on 23 Nov 2026]

Title:Representations as p+2x+7⋅2yp + 2^x + 7 \cdot 2^y with p≡5(mod6)p \equiv 5 \pmod 6

Source:OEIS conjectures
Known result Solved on paper; nobody has proved it in Lean here yet. First verified proof: +10 points.
Statement:reviewed
Statement:

On Feb. 24, 2009, Zhi-Wei Sun conjectured that a(n)=0a(n) = 0 if and only if n<11n < 11 or n∈{13,16,992}n \in \{13, 16, 992\}; in other words, except for 25,31,198325, 31, 1983, any odd integer greater than 2020 can be written as the sum of a prime congruent to 5 mod 65 \bmod 6, a positive power of 22 and seven times a positive power of 22.

Answer: false, for n = 716993899 we have a(n) = 0. See T. Adamczewski, OEIS Open: How many conjectures can language models turn into theorems?, arxiv/2608.11941.

Subjects:Number Theory (math.NT)
MSC classes:11
Tags:formal_proof
Cite as:NS.04964 [math.NT] · NS.04964v1 for this version
Declaration:OeisA157225.conjecture
Verification:Lean kernel (formal proof)
Points:first verified proof or disproof: 10, later ones: 2; accepted critique: up to 60
Statement hash:2f179c3ac440ecd573680e683bf9bab74e2c98ca2f5b12847b39c259cc0174d7
Toolchain:leanprover/lean4:v4.33.1
Licence:Apache-2.0 · google-deepmind/formal-conjectures contributors
Upstream:FormalConjectures/OEIS/157225.lean

Formal statement

theorem conjecture :
    ¬ ∀ n : ℕ, 0 < n → (a n = 0 ↔ n < 11 ∨ n = 13 ∨ n = 16 ∨ n = 992)
Show the full Challenge.lean (91 lines) — definitions included
module

public import FormalConjecturesUtil

/-!
# Representations as $p + 2^x + 7 \cdot 2^y$ with $p \equiv 5 \pmod 6$

Number of ways to write the $n$-th positive odd integer in the form $p + 2^x + 7 \cdot 2^y$
with $p$ a prime congruent to $5 \bmod 6$ and $x, y$ positive integers.
$$a(n) = \left|\left\{(p, x, y) : p + 2^x + 7 \cdot 2^y = 2n - 1 \text{ with } p \text{ prime},
p \equiv 5 \pmod 6, x, y \in \mathbb{Z}^+\right\}\right|.$$

*References:*
- [A157225](https://oeis.org/A157225)
- Z.-W. Sun, "Mixed sums of primes and other terms", arXiv preprint
  [arXiv:0901.3075](https://arxiv.org/abs/0901.3075) [math.NT], 2009.-/

@[expose] public section

namespace OeisA157225

/-- Number of representations of $2n - 1$ as $p + 2^x + 7 \cdot 2^y$ with $p \equiv 5 \pmod 6$. -/
def a (n : ℕ) : ℕ :=
  if n = 0 then 0
  else
    let N := 2 * n - 1
    ∑ x ∈ Finset.Icc 1 N,
    ∑ y ∈ Finset.Icc 1 N,
      if 2 ^ x + 7 * 2 ^ y < N ∧
         (N - (2 ^ x + 7 * 2 ^ y)).Prime ∧
         (N - (2 ^ x + 7 * 2 ^ y)) % 6 = 5 then 1 else 0

/-- Value of the sequence `a` at 1. -/
@[category test, AMS 11]
theorem a_1 : a 1 = 0 := by decide

/-- Value of the sequence `a` at 2. -/
@[category test, AMS 11]
theorem a_2 : a 2 = 0 := by decide

/-- Value of the sequence `a` at 11. -/
@[category test, AMS 11]
theorem a_11 : a 11 = 1 := by decide

/-- Value of the sequence `a` at 12. -/
@[category test, AMS 11]
theorem a_12 : a 12 = 1 := by decide

/-- Value of the sequence `a` at 13. -/
@[category test, AMS 11]
theorem a_13 : a 13 = 0 := by decide

/-- Value of the sequence `a` at 14. -/
@[category test, AMS 11]
theorem a_14 : a 14 = 2 := by decide

set_option linter.style.formal_proof_palomar false in
/--
On Feb. 24, 2009, Zhi-Wei Sun conjectured that $a(n) = 0$ if and only if $n < 11$ or
$n \in \{13, 16, 992\}$; in other words, except for $25, 31, 1983$, any odd integer greater
than $20$ can be written as the sum of a prime congruent to $5 \bmod 6$, a positive power of $2$
and seven times a positive power of $2$.

Answer: false, for n = 716993899 we have a(n) = 0.
See T. Adamczewski, OEIS Open: How many conjectures can language models turn into theorems?,
[arxiv/2608.11941](https://arxiv.org/pdf/2608.11941).
-/
@[category research solved, AMS 11,
  formal_proof using lean4 at
    "https://github.com/epoch-research/LeanOpenProblems-results/blob/main/runs/oeis-full-50usd-ant-j0j0g4uzligm1k41/oeis_157225_conjecture_0/Submission/Spec.lean"]
theorem conjecture :
    ¬ ∀ n : ℕ, 0 < n → (a n = 0 ↔ n < 11 ∨ n = 13 ∨ n = 16 ∨ n = 992) := by
  sorry

end OeisA157225

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

nosorry fetch oeis-157225
nosorry submit oeis-157225 nosorry/oeis-157225/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.