cfahlgren1/math / lean /OAI /Combinatorics /RamseyFive /Geometry /DimensionFourLowProcedure.lean
cfahlgren1's picture
download
raw
12.5 kB
import Mathlib
import OAI.Combinatorics.SharpRamsey.Entropy.LargeCard
import OAI.Combinatorics.RamseyFive.Decoding.DimensionTwoProcedure
import OAI.Combinatorics.RamseyFive.Geometry.DimensionFourHighIntegrals
namespace OAI
namespace SharpRamseyFive.ScoreGeometry
open Module ProjectiveIncidence ProjectiveTraining GreedyTraining GlobalRadial
open CellVariance ScoreRegularity PoissonScore WeightedPrograms MeasureTheory
open Filter ParameterHierarchy
open scoped BigOperators LinearAlgebra.Projectivization Classical NNReal Topology
theorem eventually_four_low_score_procedure {η : ℝ} (hη : 0<η) (hη' : η<1/10)
(Cb : ℝ) (hCb : 0≤Cb) :
∀ᶠ σ : ℝ in atTop,∀ (D b₀ τ : ℝ) (R : ℕ) (L₀ : ℝ≥0),
∀ (q : ℕ) (K I J : Type) [Field K] [Finite K] [CharP K q] [Fintype I] [LinearOrder J]
[Fintype (ℙ K (I→K))] [Fintype (ℙ K (Dual K (I→K)))]
[∀x : ℙ K (I→K),Fintype (RadialLine x)],
∀ {A : Type} [Fintype A] (g : ℝ) (F : Finset J) (hF : F.Nonempty)
(Flat : J→Submodule K (I→K)) (X U S : Finset (ℙ K (I→K)))
(t₀ : ℝ) (ht₀ : 0<t₀) (rawOwn : ℙ K (I→K)→Finset (ℙ K (I→K)))
(C : A→Finset (ℙ K (I→K))) (ia ib ic : ℙ K (I→K)→A) (T : Finset (ℙ K (Dual K (I→K)))),
2<q → Nat.card K=q → Real.exp σ=q → Fintype.card I=5 →
Range η σ D R → (L₀:ℝ)=L η σ D → 0≤b₀ → b₀≤Cb*D*σ^(6*beta η) →
0<τ → τ≤σ^(-200*beta η) → g≤2*σ → S⊆X → S⊆U →
(Nat.card K:ℝ)*(incidences X T:ℝ)≤τ*X.card*T.card →
(Nat.card K:ℝ)^5*Real.exp (-b₀)≤(X.card:ℝ)*T.card →
(∀j∈F,finrank K (Flat j)=3) →
(∀V : Submodule K (I→K),finrank K V=3 → ∃j∈F,Flat j=V) →
(X.card:ℝ)≤Real.exp (3*σ/2+g) →
t₀=(Real.exp (3*σ/2+g))^(4/3:ℝ)/Real.exp σ*Real.exp (-g/5) →
S=peelSet (P η σ D R/10000<g) F hF (fun j => flatPoints (Flat j)) X ⌈t₀⌉₊ (Nat.ceil_pos.mpr ht₀) →
Real.exp (3*σ/2+g)/4≤S.card → (S.card:ℝ)≤10*Real.exp (5*σ/2) →
(S.card:ℝ)≤(Nat.card K:ℝ)^2*Real.exp (P η σ D R/10000) →
(∀x,ownCell F hF (fun j => flatPoints (Flat j)) X
(peelLength (P η σ D R/10000<g) F hF (fun j => flatPoints (Flat j)) X ⌈t₀⌉₊ (Nat.ceil_pos.mpr ht₀)) x⊆rawOwn x) →
(∀x,S∩rawOwn x=C (ia x)∪C (ib x)) →
(∑j,(C j).card)≤3*S.card → (∀j,C j⊆S) →
(∀x,C (ic x)=C (ia x)∩C (ib x)) →
(Nat.card K:ℝ)*P η σ D R≤S.card →
(Nat.card K:ℝ)/S.card≤1/100 → (∀x,ownFraction S (C (ia x)) (C (ib x))≤2/25) →
Real.exp (-8*P η σ D R*τ)/4≤
(scheduleMeasure (fun _ : S => L₀*pointStrength S) R).real
{ω | let W := decoded U S (fun x => C (ia x)∪C (ib x)) (fun x => Real.exp (-(L₀:ℝ)*(1-ownFraction S (C (ia x)) (C (ib x))))) (emptyTests (exceptional S C) (hyperplaneSupport S) ω).card ω
(sampleCount ω:ℝ)≤2*((Nat.card K:ℝ)*P η σ D R) ∧
(W.card:ℝ)≤(S.card:ℝ)*Real.exp (10*P η σ D R) ∧
(9/10:ℝ)*S.card≤((W∩S).card:ℝ)} := by
have hi := eventually_four_low_score_integrals hη hη' Cb hCb
have hp := eventually_procedure_margins hη hη' Cb hCb
have hm := eventually_score_margins hη hη' Cb hCb
have ht := (tendsto_rpow_neg_atTop (mul_pos (by norm_num : (0:ℝ)<200) (beta_pos hη))).eventually (eventually_lt_nhds (by norm_num : (0:ℝ)<1/10))
have hl := eventually_hierarchy hη hη' Cb 1 10000000000 hCb (by norm_num)
filter_upwards [eventually_ge_atTop (10:ℝ),hi,hp,hm,ht,hl] with σ hσ hi hp hm ht hl
rw [←neg_mul] at ht
intro D b₀ τ R L₀ q K I J _ _ _ _ _ _ _ _ A _ g F hF Flat X U S t₀ ht₀ rawOwn C ia ib ic T
hq hcard hσq hI hr hL hb₀ hbhi hτ hτhi hg hSX hSU hdens hprod hFlat hcover hX htc hpeel hquarter hn hLow hraw hOwn hC hCS hCc hnP hdiv hf
have hdim : finrank K (I→K)=4+1 := by rw [Module.finrank_pi, hI]
have hS : S.Nonempty := Finset.card_pos.mp (Nat.cast_pos.mp (lt_of_lt_of_le (div_pos (Real.exp_pos _) (by norm_num)) hquarter))
have hret : X.card≤4*S.card := by exact_mod_cast (show (X.card:ℝ)≤4*S.card by linarith only [hX,hquarter])
have hP : (L₀:ℝ)*R=P η σ D R := by rw [hL];rfl
have hi := hi D b₀ τ R L₀ q K I J g F hF Flat X U S t₀ ht₀ rawOwn C ia ib ic
hq hcard hσq hI hr hL hb₀ hbhi hτhi hg hFlat hcover hX htc hpeel hquarter hn hLow hraw hOwn hC hCS hCc hdiv hf
have hp := hp D b₀ τ R hr hb₀ hbhi hτhi
have hm := hm D b₀ τ R hr hb₀ hbhi hτhi
have hlarge : 10000000000≤(L₀:ℝ) := by rw [hL];exact (hl D R b₀ τ hr hbhi hτhi).1
have hq10 : (10:ℝ)≤Nat.card K := by rw [hcard,←hσq];linarith only [Real.add_one_le_exp σ,hσ]
have hτ8 : 8*τ≤4/5 := by linarith only [hτhi,ht]
have hbcount := irregular_card_bound (d:=4) hdim (by norm_num) S C hS hC
(ξ:=(L₀:ℝ)/100) (by linarith only [Real.add_one_le_exp ((L₀:ℝ)/100),hlarge])
have hpay := ScoreScalars.exp_sub_le_scaled (a:=0) (b:=2*((L₀:ℝ)/100))
(C:=20000000) (by norm_num) (by
linarith only [Real.log_le_self (by norm_num : (0:ℝ)≤20000000),hlarge])
simp only [neg_zero,Real.exp_zero] at hpay
rw [show -(2*((L₀:ℝ)/100))=(-2)*((L₀:ℝ)/100) by ring] at hpay
have hbad : ((irregular (d:=4) S C ((L₀:ℝ)/100)).card:ℝ)≤(S.card:ℝ)/100 := by
apply hbcount.trans
nlinarith only [mul_le_mul_of_nonneg_right hpay (Nat.cast_nonneg S.card : (0:ℝ)≤S.card)]
have hh := cell_score_from_integrals (d:=4) hdim (by norm_num) hq10 X U S hSX hSU hS hret C hC ia ib hf T L₀ R b₀ τ 8
hτ hτ8 hdens hprod (by rw [hP];exact hp.1) (by norm_num) (by rwa [hP]) hbad
(by rw [hP];dsimp only at hp;linarith only [hp.2.1])
(by rw [hP,hL];exact hp.2.2.1)
(by rw [hP];exact hp.2.2.2.1)
(by rw [hP];exact hp.2.2.2.2)
(by rw [hP,hL];exact hm.2.2.2.2.2.2.1)
(by rw [hL];exact hm.2.2.2.2.2.2.2)
(by simpa only [hP] using hi.1)
(by simpa only [hP] using hi.2)
simpa only [hP,show (8:ℝ)+2=10 by norm_num] using hh
theorem eventually_four_high_score_procedure {η : ℝ} (hη : 0<η) (hη' : η<1/10)
(Cb : ℝ) (hCb : 0≤Cb) :
∀ᶠ σ : ℝ in atTop,∀ (D b₀ τ : ℝ) (R : ℕ) (L₀ : ℝ≥0),
∀ (q : ℕ) (K I J : Type) [Field K] [Finite K] [CharP K q] [Fintype I] [LinearOrder J]
[Fintype (ℙ K (I→K))] [Fintype (ℙ K (Dual K (I→K)))]
[∀x : ℙ K (I→K),Fintype (RadialLine x)],
∀ {A : Type} [Fintype A] (g : ℝ) (F : Finset J) (hF : F.Nonempty)
(Flat : J→Submodule K (I→K)) (H : Finset J) (hH : H.Nonempty)
(Hyper : J→Submodule K (I→K)) (X XH U S : Finset (ℙ K (I→K)))
(t₀ : ℝ) (ht₀ : 0<t₀) (rawOwn : ℙ K (I→K)→Finset (ℙ K (I→K)))
(C : A→Finset (ℙ K (I→K))) (ia ib ic : ℙ K (I→K)→A) (T : Finset (ℙ K (Dual K (I→K)))),
2<q → Nat.card K=q → Real.exp σ=q → Fintype.card I=5 →
Range η σ D R → (L₀:ℝ)=L η σ D → 0≤b₀ → b₀≤Cb*D*σ^(6*beta η) →
0<τ → τ≤σ^(-200*beta η) → S⊆U →
(Nat.card K:ℝ)*(incidences X T:ℝ)≤τ*X.card*T.card →
(Nat.card K:ℝ)^5*Real.exp (-b₀)≤(X.card:ℝ)*T.card → P η σ D R/10000<g → g≤σ →
(∀j∈F,finrank K (Flat j)=3) →
(∀V : Submodule K (I→K),finrank K V=3 → ∃j∈F,Flat j=V) →
(∀j∈H,finrank K (Hyper j)=4) →
(∀V : Submodule K (I→K),finrank K V=4 → ∃j∈H,Hyper j=V) →
(X.card:ℝ)=Real.exp (2*σ+g) → (X.card:ℝ)≤10*Real.exp (5*σ/2) →
XH=peelSet (P η σ D R/10000<g) H hH (fun j=>flatPoints (Hyper j)) X
((Nat.card K)^2) (pow_pos (Nat.card_pos (α:=K)) _) →
t₀=(Real.exp (2*σ+g))^(4/3:ℝ)/Real.exp σ*Real.exp (-(g+σ/2)/5) →
S=peelSet (P η σ D R/10000<g+σ/2) F hF (fun j=>flatPoints (Flat j)) XH ⌈t₀⌉₊ (Nat.ceil_pos.mpr ht₀) →
Real.exp (2*σ+g)/4≤S.card →
(∀x,ownCell F hF (fun j=>flatPoints (Flat j)) XH
(peelLength (P η σ D R/10000<g+σ/2) F hF (fun j=>flatPoints (Flat j)) XH ⌈t₀⌉₊ (Nat.ceil_pos.mpr ht₀)) x⊆rawOwn x) →
(∀x,ownCell H hH (fun j=>flatPoints (Hyper j)) X
(peelLength (P η σ D R/10000<g) H hH (fun j=>flatPoints (Hyper j)) X ((Nat.card K)^2) (pow_pos (Nat.card_pos (α:=K)) _)) x⊆rawOwn x) →
(∀x,S∩rawOwn x=C (ia x)∪C (ib x)) →
(∑j,(C j).card)≤3*S.card → (∀j,C j⊆S) →
(∀x,C (ic x)=C (ia x)∩C (ib x)) →
(Nat.card K:ℝ)*P η σ D R≤S.card →
(Nat.card K:ℝ)/S.card≤1/100 → (∀x,ownFraction S (C (ia x)) (C (ib x))≤2/25) →
Real.exp (-8*P η σ D R*τ)/4≤
(scheduleMeasure (fun _ : S => L₀*pointStrength S) R).real
{ω | let W := decoded U S (fun x => C (ia x)∪C (ib x)) (fun x => Real.exp (-(L₀:ℝ)*(1-ownFraction S (C (ia x)) (C (ib x))))) (emptyTests (exceptional S C) (hyperplaneSupport S) ω).card ω
(sampleCount ω:ℝ)≤2*((Nat.card K:ℝ)*P η σ D R) ∧
(W.card:ℝ)≤(S.card:ℝ)*Real.exp (10*P η σ D R) ∧
(9/10:ℝ)*S.card≤((W∩S).card:ℝ)} := by
have hi := eventually_four_high_score_integrals hη hη' Cb hCb
have hp := eventually_procedure_margins hη hη' Cb hCb
have hm := eventually_score_margins hη hη' Cb hCb
have ht := (tendsto_rpow_neg_atTop (mul_pos (by norm_num : (0:ℝ)<200) (beta_pos hη))).eventually (eventually_lt_nhds (by norm_num : (0:ℝ)<1/10))
have hl := eventually_hierarchy hη hη' Cb 1 10000000000 hCb (by norm_num)
filter_upwards [eventually_ge_atTop (10:ℝ),hi,hp,hm,ht,hl] with σ hσ hi hp hm ht hl
rw [←neg_mul] at ht
intro D b₀ τ R L₀ q K I J _ _ _ _ _ _ _ _ A _ g F hF Flat H hH Hyper X XH U S t₀ ht₀ rawOwn C ia ib ic T
hq hcard hσq hI hr hL hb₀ hbhi hτ hτhi hSU hdens hprod hg hg' hFlat hcover hHyper hHcover hnX hori hXH htc hpeel hquarter hraw hrawH hOwn hC hCS hCc hnP hdiv hf
have hdim : finrank K (I→K)=4+1 := by rw [Module.finrank_pi, hI]
have hS : S.Nonempty := Finset.card_pos.mp (Nat.cast_pos.mp (lt_of_lt_of_le (div_pos (Real.exp_pos _) (by norm_num)) hquarter))
have hret : X.card≤4*S.card := by exact_mod_cast (show (X.card:ℝ)≤4*S.card by rw [hnX];linarith only [hquarter])
have hHX : XH⊆X := hXH▸peel_subset _ H hH (fun j=>flatPoints (Hyper j)) X _ _
have hSH : S⊆XH := hpeel▸peel_subset _ F hF (fun j=>flatPoints (Flat j)) XH _ _
have hSX : S⊆X := hSH.trans hHX
have hP : (L₀:ℝ)*R=P η σ D R := by rw [hL];rfl
have hi := hi D b₀ τ R L₀ q K I J g F hF Flat H hH Hyper X XH U S t₀ ht₀ rawOwn C ia ib ic
hq hcard hσq hI hr hL hb₀ hbhi hτhi hg hg' hFlat hcover hHyper hHcover hnX hori hXH htc hpeel hquarter hraw hrawH hOwn hC hCS hCc hdiv hf
have hp := hp D b₀ τ R hr hb₀ hbhi hτhi
have hm := hm D b₀ τ R hr hb₀ hbhi hτhi
have hlarge : 10000000000≤(L₀:ℝ) := by rw [hL];exact (hl D R b₀ τ hr hbhi hτhi).1
have hq10 : (10:ℝ)≤Nat.card K := by rw [hcard,←hσq];linarith only [Real.add_one_le_exp σ,hσ]
have hτ8 : 8*τ≤4/5 := by linarith only [hτhi,ht]
have hbcount := irregular_card_bound (d:=4) hdim (by norm_num) S C hS hC
(ξ:=(L₀:ℝ)/100) (by linarith only [Real.add_one_le_exp ((L₀:ℝ)/100),hlarge])
have hpay := ScoreScalars.exp_sub_le_scaled (a:=0) (b:=2*((L₀:ℝ)/100))
(C:=20000000) (by norm_num) (by
linarith only [Real.log_le_self (by norm_num : (0:ℝ)≤20000000),hlarge])
simp only [neg_zero,Real.exp_zero] at hpay
rw [show -(2*((L₀:ℝ)/100))=(-2)*((L₀:ℝ)/100) by ring] at hpay
have hbad : ((irregular (d:=4) S C ((L₀:ℝ)/100)).card:ℝ)≤(S.card:ℝ)/100 := by
apply hbcount.trans
nlinarith only [mul_le_mul_of_nonneg_right hpay (Nat.cast_nonneg S.card : (0:ℝ)≤S.card)]
have hh := cell_score_from_integrals (d:=4) hdim (by norm_num) hq10 X U S hSX hSU hS hret C hC ia ib hf T L₀ R b₀ τ 8
hτ hτ8 hdens hprod (by rw [hP];exact hp.1) (by norm_num) (by rwa [hP]) hbad
(by rw [hP];dsimp only at hp;linarith only [hp.2.1])
(by rw [hP,hL];exact hp.2.2.1)
(by rw [hP];exact hp.2.2.2.1)
(by rw [hP];exact hp.2.2.2.2)
(by rw [hP,hL];exact hm.2.2.2.2.2.2.1)
(by rw [hL];exact hm.2.2.2.2.2.2.2)
(by simpa only [hP] using hi.1)
(by simpa only [hP] using hi.2)
simpa only [hP,show (8:ℝ)+2=10 by norm_num] using hh
end SharpRamseyFive.ScoreGeometry
end OAI

Xet Storage Details

Size:
12.5 kB
·
Xet hash:
66ec42a5caa6509781de837f446814dd67e82ed57271c79c7a62f1e12cb33a8f

Xet efficiently stores files, intelligently splitting them into unique chunks and accelerating uploads and downloads. More info.