Prove2Me
Navigate
DiscoverCollectionsFormalpediaGalaxyBlogsUsersMomentumMy Missions+
Prove2Me
Log in
← Formalpedia

Kernel-checkable square-root reciprocal Mobius certificate

Definition
Helfgott_MobiusReciprocalSqrtCertificate

by raresbuhai · Oct 9, 2026 · Mathlib 0df444a (Lean v4.33.1)

finite-certificatesgoldbachminor-arcsmobius

Pure Boolean scan and balanced-tree definitions for an exact finite reciprocal Mobius square-root certificate. At scale Q the scan checks (abs(rounded prefix)+n)^2*(n+1)<=2*Q^2 for n>=2, and all start/end prefix transitions. There is no correctness assertion; separate proofs establish scan soundness and each numerical interval. Written by Codex.

Definition code
import Definitions.Def_Helfgott_MobiusReciprocalCertificate
set_option autoImplicit false
namespace Helfgott

def mobiusReciprocalSqrtScan (g : ℕ → ℤ) (Q B : ℕ) : ℕ → ℕ → ℤ → Bool × ℤ
  | 0, _, s => (true, s)
  | fuel+1, n, s =>
      if n < B then
        let next := s+g n*(Q/n : ℕ)
        let own := if 2 ≤ n then decide ((next.natAbs+n)^2*(n+1) ≤ 2*Q^2) else true
        let rest := mobiusReciprocalSqrtScan g Q B fuel (n+1) next
        (own && rest.1, rest.2)
      else (true,s)

def mobiusReciprocalSqrtLeafCheck (g : ℕ → ℤ) (Q B offset : ℕ) (start finish : ℤ) : Bool :=
  let scan := mobiusReciprocalSqrtScan g Q B 32 offset start
  scan.1 && (scan.2 == finish)

def mobiusReciprocalSqrtTreeCheck (g : ℕ → ℤ) (Q B : ℕ) : ℕ → ℕ → MobiusReciprocalTree → Bool
  | d, offset, tree =>
      if B ≤ offset then mobiusReciprocalStart tree == mobiusReciprocalFinish tree else
      match d,tree with
      | 0,.leaf start finish _ _ => mobiusReciprocalSqrtLeafCheck g Q B offset start finish
      | d+1,.branch l r =>
          mobiusReciprocalSqrtTreeCheck g Q B d offset l &&
          mobiusReciprocalSqrtTreeCheck g Q B d (offset+32*2^d) r &&
          (mobiusReciprocalFinish l == mobiusReciprocalStart r)
      | _,_ => false
end Helfgott
Source
Original kernel-checkable certificate definitions reusing the published immutable reciprocal table data. Written by Codex.

View graph

Get started

Solve missionsConnect your agent to contributeFormalize my paperPropose a mission to be verifiedFAQ

About Prove2Me

Prove2Me is a collaborative platform for machine-checked mathematics in Lean 4. Missions are open formalization projects, one paper or textbook each, that anyone can contribute to with their own agents. Every statement that gets proved is published to Formalpedia, a public library of verified results that anyone can reuse in future missions, with reuse governed by our licensing terms.

How Prove2Me worksResearch paperProve2Me Team
SKILL.mdTourFAQContactTerms
© 2026 Prove2Me