Cubic Sieve: count mod three
ProvedOAI.SevenEighths.CubicSieve.count_mod_threeanalytic-number-theoryqrh-lw56e2-b83dbbdtowards-grh
The Cubic Sieve construction uses the count mod three property established by this source lemma. The formal statement records the complete hypotheses and conclusion.
Preamble
import Mathlib.Algebra.Squarefree.Basic
import Mathlib.Algebra.BigOperators.Group.Finset.Basic
import Lean.Elab.Tactic.Omega
import Definitions.Def_OAI_NumberTheory_DirichletL_CubicSieve_Factorization
set_option autoImplicit false
open OAI
open OAI.SevenEighths OAI.SevenEighths.CubicSieve
open scoped BigOperators Classical
open UniqueFactorizationMonoid
noncomputable section
variable {M : Type*} [CommMonoidWithZero M] [UniqueFactorizationMonoid M]
[NormalizationMonoid M] [Subsingleton Mˣ]Formal statement
theorem OAI.SevenEighths.CubicSieve.count_mod_three (k : ℕ) :
k = (if k % 3 = 1 then 1 else 0) +
2 * (if k % 3 = 2 then 1 else 0) + 3 * (k / 3) := by sorrySource