Download data/lean/OAI/Combinatorics/BalancedRyser/Local/InjectionConditioning.lean from introvoyz045/math: direct link, hf CLI and curl.
- Browser
- Download file 2.03 kB
-
https://huggingface.co/datasets/introvoyz045/math/resolve/main/data/lean/OAI/Combinatorics/BalancedRyser/Local/InjectionConditioning.lean
- Command line
-
hf download hf://datasets/introvoyz045/math/data/lean/OAI/Combinatorics/BalancedRyser/Local/InjectionConditioning.lean
-
curl -L -o InjectionConditioning.lean https://huggingface.co/datasets/introvoyz045/math/resolve/main/data/lean/OAI/Combinatorics/BalancedRyser/Local/InjectionConditioning.lean
2.03 kB
| import OAI.Combinatorics.BalancedRyser.Local.InjectionExposure | |
| import OAI.Combinatorics.BalancedRyser.Probability.FiniteUniformConditioning | |
| namespace OAI | |
| namespace Balanced.InjectionExposure | |
| variable {I J : Type*} [Fintype I] [Fintype J] [DecidableEq I] [DecidableEq J] | |
| [Nonempty (I βͺ J)] | |
| theorem original_uniform_conditioned (K : Finset I) (base : I βͺ J) | |
| (h : β e β (β(completions K base) : Set (I βͺ J)), | |
| e β (PMF.uniformOfFintype (I βͺ J)).support) : | |
| (PMF.uniformOfFintype (I βͺ J)).filter (β(completions K base)) h = | |
| PMF.uniformOfFinset (completions K base) (completions_nonempty K base) := by | |
| classical | |
| let S := completions K base | |
| have : Nonempty (βS : Set (I βͺ J)) := β¨β¨base, by simp [S]β©β© | |
| rw [uniform_filter_eq_subtype_map] | |
| ext e | |
| by_cases he : e β completions K base | |
| Β· rw [PMF.map_apply, tsum_eq_single (β¨e, heβ© : (βS : Set (I βͺ J)))] | |
| Β· simp only [PMF.uniformOfFintype_apply, PMF.uniformOfFinset_apply, | |
| he, ite_true] | |
| exact congrArg (fun n : β => (n : ENNReal)β»ΒΉ) | |
| (Fintype.card_coe (completions K base)) | |
| Β· intro f hf | |
| rw [ite_eq_right] | |
| intro hef | |
| exact hf (Subtype.ext hef.symm) | |
| Β· rw [PMF.uniformOfFinset_apply_of_notMem (completions_nonempty K base) he, | |
| PMF.map_apply] | |
| apply ENNReal.tsum_eq_zero.mpr | |
| intro f | |
| rw [ite_eq_right] | |
| intro hef | |
| exact he (hef βΈ f.property) | |
| theorem original_conditioned_next_event (K : Finset I) (base : I βͺ J) | |
| (h : β e β (β(completions K base) : Set (I βͺ J)), | |
| e β (PMF.uniformOfFintype (I βͺ J)).support) | |
| (i : I) (hi : i β K) (P : J β Prop) [DecidablePred P] : | |
| (((PMF.uniformOfFintype (I βͺ J)).filter (β(completions K base)) h).toOuterMeasure | |
| {e | P (e i)}).toReal = | |
| (((remaining K base).filter P).card : β) / ((remaining K base).card : β) := by | |
| rw [original_uniform_conditioned K base h] | |
| exact next_event_probability K base i hi P | |
| end Balanced.InjectionExposure | |
| end OAI | |