Bandits.probReal_sumRewards_le_sumRewards_le
No docstring.
Bandits.probReal_sumRewards_le_sumRewards_le.{u_1, u_2} {๐ : Type u_1} {ฮฉ : Type u_2} [DecidableEq ๐] {m๐ : MeasurableSpace ๐} {mฮฉ : MeasurableSpace ฮฉ} {P : MeasureTheory.Measure ฮฉ} [MeasureTheory.IsProbabilityMeasure P] {alg : Learning.Algorithm ๐ โ} {ฮฝ : ProbabilityTheory.Kernel ๐ โ} [ProbabilityTheory.IsMarkovKernel ฮฝ] {A : โ โ ฮฉ โ ๐} {R : โ โ ฮฉ โ โ} [Nonempty ๐] [Fintype ๐] [MeasurableSingletonClass ๐] (h : Learning.IsAlgEnvSeq A R alg (Learning.stationaryEnv ฮฝ) P) (a : ๐) (n mโ mโ : โ) : MeasureTheory.Measure.real P {ฯ | Learning.pullCount A (bestArm ฮฝ) n ฯ = mโ โง Learning.pullCount A a n ฯ = mโ โง Learning.sumRewards A R (bestArm ฮฝ) n ฯ โค Learning.sumRewards A R a n ฯ} โค MeasureTheory.Measure.real (streamMeasure ฮฝ) {ฯ | โ i โ Finset.range mโ, ฯ i (bestArm ฮฝ) โค โ i โ Finset.range mโ, ฯ i a}Bandits.probReal_sumRewards_le_sumRewards_le.{u_1, u_2} {๐ : Type u_1} {ฮฉ : Type u_2} [DecidableEq ๐] {m๐ : MeasurableSpace ๐} {mฮฉ : MeasurableSpace ฮฉ} {P : MeasureTheory.Measure ฮฉ} [MeasureTheory.IsProbabilityMeasure P] {alg : Learning.Algorithm ๐ โ} {ฮฝ : ProbabilityTheory.Kernel ๐ โ} [ProbabilityTheory.IsMarkovKernel ฮฝ] {A : โ โ ฮฉ โ ๐} {R : โ โ ฮฉ โ โ} [Nonempty ๐] [Fintype ๐] [MeasurableSingletonClass ๐] (h : Learning.IsAlgEnvSeq A R alg (Learning.stationaryEnv ฮฝ) P) (a : ๐) (n mโ mโ : โ) : MeasureTheory.Measure.real P {ฯ | Learning.pullCount A (bestArm ฮฝ) n ฯ = mโ โง Learning.pullCount A a n ฯ = mโ โง Learning.sumRewards A R (bestArm ฮฝ) n ฯ โค Learning.sumRewards A R a n ฯ} โค MeasureTheory.Measure.real (streamMeasure ฮฝ) {ฯ | โ i โ Finset.range mโ, ฯ i (bestArm ฮฝ) โค โ i โ Finset.range mโ, ฯ i a}
Code
lemma probReal_sumRewards_le_sumRewards_le [Fintype ๐] [MeasurableSingletonClass ๐]
(h : IsAlgEnvSeq A R alg (stationaryEnv ฮฝ) P)
(a : ๐) (n mโ mโ : โ) :
P.real {ฯ | pullCount A (bestArm ฮฝ) n ฯ = mโ โง pullCount A a n ฯ = mโ โง
sumRewards A R (bestArm ฮฝ) n ฯ โค sumRewards A R a n ฯ} โค
(streamMeasure ฮฝ).real
{ฯ | โ i โ range mโ, ฯ i (bestArm ฮฝ) โค โ i โ range mโ, ฯ i a}Proof
by
have hA := h.measurable_action
have hR := h.measurable_feedback
refine le_trans (le_of_eq ?_)
(ArrayModel.probReal_sumRewards_le_sumRewards_le (alg := alg) a n mโ mโ)
let s := {p : โ ร โ ร โ ร โ | p.1 = mโ โง p.2.1 = mโ โง p.2.2.1 โค p.2.2.2}
have hs : MeasurableSet s := by simp only [measurableSet_setOfPred, s]; fun_prop
change P.real ((fun ฯ โฆ (pullCount A (bestArm ฮฝ) n ฯ,
pullCount A a n ฯ, sumRewards A R (bestArm ฮฝ) n ฯ, sumRewards A R a n ฯ)) โปยน' s) =
(ArrayModel.arrayMeasure ฮฝ).real
((fun ฯ โฆ (pullCount (ArrayModel.action alg) (bestArm ฮฝ) n ฯ,
pullCount (ArrayModel.action alg) a n ฯ,
sumRewards (ArrayModel.action alg) (ArrayModel.reward alg) (bestArm ฮฝ) n ฯ,
sumRewards (ArrayModel.action alg) (ArrayModel.reward alg) a n ฯ)) โปยน' s)
simp_rw [measureReal_def]
congr 1
rw [โ Measure.map_apply ?_ hs, โ Measure.map_apply (by fun_prop) hs]
swap
ยท refine Measurable.prod (by fun_prop) (Measurable.prod (by fun_prop) ?_)
exact (measurable_sumRewards hA hR _ _).prod (measurable_sumRewards hA hR _ _)
congr 1
refine IdentDistrib.map_eq ?_
have h_eq := h.law_pullCount_sumRewards_unique' (ArrayModel.isAlgEnvSeq_arrayMeasure alg ฮฝ)
(n := n)
exact h_eq.comp (u := fun p โฆ ((p (bestArm ฮฝ)).1, (p a).1, (p (bestArm ฮฝ)).2, (p a).2))
(by fun_prop)Actions: Source ยท Open Issue
Meaning last changed in v4.34.0-rc2-14-gf86702d (2026-08-25), the 5th recorded change.
Self-contained, with its dependencies inlined and proofs replaced by sorry: download the raw file ยท open it in the Lean web editor.
Dependency graph
Audit surface: 10 project declarations, 94 external constants
โ Proved: no sorry anywhere in its closure
This is the tool's own reading of one build's recorded axioms, and it is not robust against an author who wants it to pass. Checking meant to be relied on should go through Comparator, which replays the proof through the kernel from an export against an explicit list of permitted axioms.