import OAI.Probability.ClassicalON.AnnulusLabels namespace OAI universe uι noncomputable section open scoped Classical namespace ClassicalON def coarseSite (N : ℤ) (v : Site) : Site := (v.1/N,v.2/N) def coarseCenter (N : ℤ) (v : Site) : Site := (N*v.1,N*v.2) theorem siteRadius_scale (N : ℤ) (hN : 0≤N) (x y : Site) : siteRadius (coarseCenter N x) (coarseCenter N y)=N*siteRadius x y := by simp only [siteRadius,coarseCenter,← mul_sub,abs_mul,abs_of_nonneg hN] exact (mul_max_of_nonneg _ _ hN).symm theorem coarseSite_close (N : ℤ) (hN : 0.mp h exact max_le (coarse_quotient_step N hN _ _ hh.1) (coarse_quotient_step N hN _ _ hh.2) theorem coarseSite_distance (N : ℤ) (hN : 0 c.1.val) h have h2 := congrArg (fun c : SiteColor => c.2.val) h change (x.1%5).toNat=(y.1%5).toNat at h1 change (x.2%5).toNat=(y.2%5).toNat at h2 by_contra hn have hr : |y.1-x.1|≤4 ∧ |y.2-x.2|≤4 := (siteRadius_le_iff x y 4).mp (by omega) have ha := abs_le.mp hr.1 have hb := abs_le.mp hr.2 apply hxy apply Prod.ext <;> omega theorem sameColor_separated {ι : Type uι} (N : ℤ) (hN : 0 coarseCenter N (v i.val)) := by intro i j hij rw [siteRadius_scale N (le_of_lt hN)] have hd : v i.val≠v j.val := fun h => hij (Subtype.ext (hv h)) have hh := sameColor_far hd (i.property.trans j.property.symm) nlinarith end ClassicalON end end OAI