math / data /lean /OAI /Probability /FreeIsing /Trees /CutContinuationChannels.lean
introvoyz045's picture
Migrated from GitHub
4a56cd6 verified
Raw History Blame Contribute Delete
10.4 kB
import OAI.Probability.FreeIsing.Trees.CutContinuations
import OAI.Probability.FreeIsing.Trees.CutLevelConcentration
namespace OAI
noncomputable section
open MeasureTheory ProbabilityTheory
namespace Problem367.CutContinuationChannels
open RootedBroadcast
variable {d : β„•} {A : Type*} [MeasurableSpace A]
abbrev ConeSample (A : Type*) (v : TreeVertex d) :=
(DescendantVertex v β†’ IsingSpin) Γ— (DescendantVertex v β†’ A)
def globalCone (v : TreeVertex d)
(z : (TreeVertex d β†’ IsingSpin) Γ— (TreeVertex d β†’ A)) : ConeSample A v :=
((fun u => z.1 u.1), fun u => z.2 u.1)
def restrictCone {u v : TreeVertex d} (h : u.1 <+: v.1)
(z : ConeSample A u) : ConeSample A v :=
((fun w => z.1 ⟨w.1, h.trans w.2⟩), fun w => z.2 ⟨w.1, h.trans w.2⟩)
theorem measurable_globalCone (v : TreeVertex d) : Measurable (globalCone (A := A) v) := by
unfold globalCone
fun_prop
theorem measurable_restrictCone {u v : TreeVertex d} (h : u.1 <+: v.1) :
Measurable (restrictCone (A := A) h) := by
unfold restrictCone
fun_prop
def globalFactors (F : βˆ€ v : TreeVertex d, ConeSample A v β†’ ℝ)
(z : (TreeVertex d β†’ IsingSpin) Γ— (TreeVertex d β†’ A)) (v : TreeVertex d) : ℝ :=
F v (globalCone v z)
def continuationChannel (F : βˆ€ v : TreeVertex d, ConeSample A v β†’ ℝ)
{k L : β„•} (p : TreeShell d (k + 1)) (w : ReducedTail (cutLastColor p) L)
(z : ConeSample A p.1) : ℝ :=
∏ j ∈ Finset.range L,
F (rootPathVertex (appendCutContinuation p w).1 (k + 1 + (j + 1)))
(restrictCone (cutContinuation_vertex_descendant p w j) z)
theorem measurable_continuationChannel
(F : βˆ€ v : TreeVertex d, ConeSample A v β†’ ℝ) (hF : βˆ€ v, Measurable (F v))
{k L : β„•} (p : TreeShell d (k + 1)) (w : ReducedTail (cutLastColor p) L) :
Measurable (continuationChannel F p w) := by
apply Finset.measurable_fun_prod
intro j hj
exact (hF _).comp (measurable_restrictCone _)
omit [MeasurableSpace A] in
theorem continuationChannel_mem_Icc
(F : βˆ€ v : TreeVertex d, ConeSample A v β†’ ℝ)
(hb : βˆ€ v z, 0 ≀ F v z ∧ F v z ≀ 1)
{k L : β„•} (p : TreeShell d (k + 1)) (w : ReducedTail (cutLastColor p) L)
(z : ConeSample A p.1) : continuationChannel F p w z ∈ Set.Icc (0 : ℝ) 1 :=
⟨Finset.prod_nonneg (fun _ _ => (hb _ _).1),
Finset.prod_le_oneβ‚€ (fun _ _ => (hb _ _).1) (fun _ _ => (hb _ _).2)⟩
omit [MeasurableSpace A] in
@[simp] theorem continuationChannel_globalCone
(F : βˆ€ v : TreeVertex d, ConeSample A v β†’ ℝ)
{k L : β„•} (p : TreeShell d (k + 1)) (w : ReducedTail (cutLastColor p) L)
(z : (TreeVertex d β†’ IsingSpin) Γ— (TreeVertex d β†’ A)) :
continuationChannel F p w (globalCone p.1 z) =
cutContinuationProduct (globalFactors F z) p w := rfl
def averageChannel (F : βˆ€ v : TreeVertex d, ConeSample A v β†’ ℝ)
{k : β„•} (p : TreeShell d (k + 1)) (L : β„•) (z : ConeSample A p.1) : ℝ :=
(βˆ‘ w : ReducedTail (cutLastColor p) L, continuationChannel F p w z) /
(Fintype.card (ReducedTail (cutLastColor p) L) : ℝ)
theorem measurable_averageChannel
(F : βˆ€ v : TreeVertex d, ConeSample A v β†’ ℝ) (hF : βˆ€ v, Measurable (F v))
{k : β„•} (p : TreeShell d (k + 1)) (L : β„•) : Measurable (averageChannel F p L) :=
(Finset.measurable_fun_sum _ (fun w _ => measurable_continuationChannel F hF p w)).div_const _
omit [MeasurableSpace A] in
theorem averageChannel_mem_Icc (hd : 2 ≀ d)
(F : βˆ€ v : TreeVertex d, ConeSample A v β†’ ℝ)
(hb : βˆ€ v z, 0 ≀ F v z ∧ F v z ≀ 1)
{k : β„•} (p : TreeShell d (k + 1)) (L : β„•) (z : ConeSample A p.1) :
averageChannel F p L z ∈ Set.Icc (0 : ℝ) 1 := by
have hc : (0 : ℝ) < Fintype.card (ReducedTail (cutLastColor p) L) := by
rw [card_reducedTail]
exact_mod_cast pow_pos (by omega : 0 < d - 1) L
constructor
Β· exact div_nonneg (Finset.sum_nonneg
(fun w _ => (continuationChannel_mem_Icc F hb p w z).1)) hc.le
Β· apply (div_le_iffβ‚€ hc).mpr
simpa using Finset.sum_le_sum
(fun w (_ : w ∈ (Finset.univ : Finset (ReducedTail (cutLastColor p) L))) =>
(continuationChannel_mem_Icc F hb p w z).2)
omit [MeasurableSpace A] in
@[simp] theorem averageChannel_globalCone
(F : βˆ€ v : TreeVertex d, ConeSample A v β†’ ℝ)
{k : β„•} (p : TreeShell d (k + 1)) (L : β„•)
(z : (TreeVertex d β†’ IsingSpin) Γ— (TreeVertex d β†’ A)) :
averageChannel F p L (globalCone p.1 z) =
(βˆ‘ w : ReducedTail (cutLastColor p) L,
cutContinuationProduct (globalFactors F z) p w) / (((d - 1) ^ L : β„•) : ℝ) := by
simp [averageChannel]
omit [MeasurableSpace A] in
theorem path_average_le_averageChannel
(F : βˆ€ v : TreeVertex d, ConeSample A v β†’ ℝ)
(hb : βˆ€ v z, 0 ≀ F v z ∧ F v z ≀ 1)
{k : β„•} (I : Finset (TreeShell d (k + 1))) (L : β„•)
(z : (TreeVertex d β†’ IsingSpin) Γ— (TreeVertex d β†’ A)) :
(βˆ‘ v ∈ cutDescendants I L, rootPathProduct (globalFactors F z) v.1) /
((cutDescendants I L).card : ℝ) ≀
(βˆ‘ p ∈ I, averageChannel F p L (globalCone p.1 z)) / (I.card : ℝ) := by
simpa only [averageChannel_globalCone] using
average_rootPathProduct_le_continuation_average (globalFactors F z)
(fun v => hb v _) I L
theorem integral_averageChannel_le (hd : 2 ≀ d)
(F : βˆ€ v : TreeVertex d, ConeSample A v β†’ ℝ) (hF : βˆ€ v, Measurable (F v))
(hb : βˆ€ v z, 0 ≀ F v z ∧ F v z ≀ 1)
{k : β„•} (p : TreeShell d (k + 1)) (L : β„•)
(P : Measure ((TreeVertex d β†’ IsingSpin) Γ— (TreeVertex d β†’ A)))
[IsProbabilityMeasure P] {m : ℝ}
(hmean : βˆ€ w : ReducedTail (cutLastColor p) L,
(∫ z, cutContinuationProduct (globalFactors F z) p w βˆ‚P) ≀ m) :
(∫ z, averageChannel F p L (globalCone p.1 z) βˆ‚P) ≀ m := by
have hc : (0 : ℝ) < Fintype.card (ReducedTail (cutLastColor p) L) := by
rw [card_reducedTail]
exact_mod_cast pow_pos (by omega : 0 < d - 1) L
have hi (w : ReducedTail (cutLastColor p) L) :
Integrable (fun z => continuationChannel F p w (globalCone p.1 z)) P := by
apply Integrable.of_bound
((measurable_continuationChannel F hF p w).comp (measurable_globalCone p.1)).aestronglyMeasurable 1
apply Filter.Eventually.of_forall
intro z
change β€–continuationChannel F p w (globalCone p.1 z)β€– ≀ 1
rw [Real.norm_eq_abs, abs_of_nonneg (continuationChannel_mem_Icc F hb p w _).1]
exact (continuationChannel_mem_Icc F hb p w _).2
calc
_ = (βˆ‘ w : ReducedTail (cutLastColor p) L,
∫ z, continuationChannel F p w (globalCone p.1 z) βˆ‚P) /
(Fintype.card (ReducedTail (cutLastColor p) L) : ℝ) := by
unfold averageChannel
rw [integral_div, integral_finsetSum _ (fun w _ => hi w)]
_ ≀ (βˆ‘ _w : ReducedTail (cutLastColor p) L, m) /
(Fintype.card (ReducedTail (cutLastColor p) L) : ℝ) := by
apply div_le_div_of_nonneg_right _ hc.le
exact Finset.sum_le_sum (fun w _ => hmean w)
_ = m := by
simp only [Finset.sum_const, Finset.card_univ, nsmul_eq_mul]
exact mul_div_cancel_leftβ‚€ m hc.ne'
theorem measure_path_average_ge_le [StandardBorelSpace A]
{theta : ℝ} {ΞΌ : Measure (TreeVertex d β†’ IsingSpin)} [IsProbabilityMeasure ΞΌ]
(hΞΌ : HasFreeIsingLaw theta ΞΌ) (h0 : -1 ≀ theta) (h1 : theta ≀ 1) (hd : 2 ≀ d)
(Ξ½ : TreeVertex d β†’ Measure A) [βˆ€ v, IsProbabilityMeasure (Ξ½ v)]
(F : βˆ€ v : TreeVertex d, ConeSample A v β†’ ℝ) (hF : βˆ€ v, Measurable (F v))
(hb : βˆ€ v z, 0 ≀ F v z ∧ F v z ≀ 1)
{k : β„•} (I : Finset (TreeShell d (k + 1))) (hI : I.Nonempty) (L : β„•)
{Ο„ : ℝ} (hΟ„ : 0 ≀ Ο„)
(hmean : βˆ€ p ∈ I, βˆ€ w : ReducedTail (cutLastColor p) L,
(∫ z, cutContinuationProduct (globalFactors F z) p w
βˆ‚ΞΌ.prod (Measure.infinitePi Ξ½)) ≀ Ο„ / 4) :
(ΞΌ.prod (Measure.infinitePi Ξ½))
{z | Ο„ ≀ (βˆ‘ v ∈ cutDescendants I L, rootPathProduct (globalFactors F z) v.1) /
((cutDescendants I L).card : ℝ)} ≀
ENNReal.ofReal (Real.exp (-(I.card : ℝ) * Ο„ ^ 2 / 2)) := by
calc
_ ≀ (ΞΌ.prod (Measure.infinitePi Ξ½))
{z | Ο„ ≀ (βˆ‘ p ∈ I, averageChannel F p L (globalCone p.1 z)) / (I.card : ℝ)} := by
apply measure_mono
intro z hz
exact hz.trans (path_average_le_averageChannel F hb I L z)
_ ≀ _ := hΞΌ.measure_cutLevel_average_ge_le h0 h1 (k + 1) Ξ½
(fun p => averageChannel F p L) (fun p => measurable_averageChannel F hF p L)
(fun p z => averageChannel_mem_Icc hd F hb p L z) I hI hΟ„
(fun p hp => integral_averageChannel_le hd F hF hb p L _ (hmean p hp))
theorem measure_restricted_path_average_ge_le_double_exp [StandardBorelSpace A]
{theta : ℝ} {ΞΌ : Measure (TreeVertex d β†’ IsingSpin)} [IsProbabilityMeasure ΞΌ]
(hΞΌ : HasFreeIsingLaw theta ΞΌ) (h0 : -1 ≀ theta) (h1 : theta ≀ 1) (hd : 2 ≀ d)
(Ξ½ : TreeVertex d β†’ Measure A) [βˆ€ v, IsProbabilityMeasure (Ξ½ v)]
(F : βˆ€ v : TreeVertex d, ConeSample A v β†’ ℝ) (hF : βˆ€ v, Measurable (F v))
(hb : βˆ€ v z, 0 ≀ F v z ∧ F v z ≀ 1)
(forbidden : Finset (Fin d)) (hforbidden : forbidden.card ≀ 1) (k L : β„•)
{q β„“ : ℝ} (hβ„“ : 0 ≀ β„“) (hq : q ≀ Real.log ((d : ℝ) - 1) / 8)
(hlevel : β„“ / 2 - 1 ≀ (k + 1 : β„•))
(hmean : βˆ€ p ∈ avoidingTreeCut forbidden k, βˆ€ w : ReducedTail (cutLastColor p) L,
(∫ z, cutContinuationProduct (globalFactors F z) p w
βˆ‚ΞΌ.prod (Measure.infinitePi Ξ½)) ≀ Real.exp (-q * β„“) / 4) :
(ΞΌ.prod (Measure.infinitePi Ξ½))
{z | Real.exp (-q * β„“) ≀
(βˆ‘ v ∈ cutDescendants (avoidingTreeCut forbidden k) L,
rootPathProduct (globalFactors F z) v.1) /
((cutDescendants (avoidingTreeCut forbidden k) L).card : ℝ)} ≀
ENNReal.ofReal (Real.exp (-(((d : ℝ) - 1) ^ (β„“ / 4)) / (2 * ((d : ℝ) - 1)))) := by
have hdR : (2 : ℝ) ≀ d := by exact_mod_cast hd
exact (measure_path_average_ge_le hΞΌ h0 h1 hd Ξ½ F hF hb
(avoidingTreeCut forbidden k) (avoidingTreeCut_nonempty hd forbidden hforbidden k)
L (Real.exp_pos _).le hmean).trans
(ENNReal.ofReal_le_ofReal (BoundedAverageConcentration.exponential_card_bound
(by linarith) hβ„“ hq (rpow_le_card_avoidingTreeCut hd forbidden hforbidden k hlevel)))
end Problem367.CutContinuationChannels
end
end OAI