Download data/lean/OAI/Analysis/HardSphere/PathBounds/FreeVisitProbability.lean from introvoyz045/math: direct link, hf CLI and curl.
- Browser
- Download file 8.78 kB
-
https://huggingface.co/datasets/introvoyz045/math/resolve/main/data/lean/OAI/Analysis/HardSphere/PathBounds/FreeVisitProbability.lean
- Command line
-
hf download hf://datasets/introvoyz045/math/data/lean/OAI/Analysis/HardSphere/PathBounds/FreeVisitProbability.lean
-
curl -L -o FreeVisitProbability.lean https://huggingface.co/datasets/introvoyz045/math/resolve/main/data/lean/OAI/Analysis/HardSphere/PathBounds/FreeVisitProbability.lean
8.78 kB
| import Mathlib | |
| import OAI.Analysis.HardSphere.Geometry.KilledObservable | |
| import OAI.Analysis.HardSphere.PathBounds.VisitPacking | |
| namespace OAI | |
| section | |
| section | |
| noncomputable section | |
| open MeasureTheory Set Filter | |
| open scoped ENNReal NNReal Topology BigOperators | |
| namespace HardSphere.FreeVisits | |
| open HardSphere.BathSlice HardSphere.Lattice HardSphere.CellOrbital HardSphere.Wiener | |
| lemma pathVisitedSites_card_measurable {S : Type*} {n : β} (L : Length) | |
| (v : S β Torus L) (A : Finset S) (i : Fin n) : | |
| Measurable (fun Ο : ConfigurationPath n L β¦ (pathVisitedSites L v A i Ο).card) := by | |
| classical | |
| simp only [pathVisitedSites,Finset.card_filter] | |
| apply Finset.measurable_sum | |
| intro a _ | |
| exact Measurable.ite (pathVisitsBall_isClosed L 12 (v a) i).measurableSet | |
| measurable_const measurable_const | |
| def visitCount {n K : β} (L : Length) (A : Finset (DiscreteTorus K)) (i : Fin n) | |
| (t : β) (X : Configuration n L) (w : CoordinatePaths n) : β := | |
| (pathVisitedSites L (siteCenter L) A i (freeTrajectory n L t w X)).card | |
| lemma visitCount_measurable {n K : β} (L : Length) (A : Finset (DiscreteTorus K)) (i : Fin n) | |
| (t : β) (X : Configuration n L) : Measurable (visitCount L A i t X) := | |
| (pathVisitedSites_card_measurable L (siteCenter L) A i).comp | |
| ((freeTrajectory_continuous n L t).comp (continuous_id.prodMk continuous_const)).measurable | |
| lemma one_segment_visit_tail {c : β} {M : ββ₯0β} | |
| (htail : β R : β, 0β€R β wiener {w | Rβ€βwβ}β€M*ENNReal.ofReal (Real.exp (-c*R^2))) | |
| {n K : β} [NeZero K] (L : Length) (hL : L.val=(K:β)) | |
| (A : Finset (DiscreteTorus K)) (i : Fin n) {t : β} (ht : 0<t) (X : Configuration n L) : | |
| coordinateWiener n {w | 29^3<visitCount L A i t X w} β€ | |
| 3*M*ENNReal.ofReal (Real.exp (-c/(2*t))) := by | |
| let R : β := (Real.sqrt (2*t))β»ΒΉ | |
| have hs : 0<Real.sqrt (2*t) := Real.sqrt_pos.mpr (by positivity) | |
| have hR : 0β€R := inv_nonneg.mpr hs.le | |
| have hsub : {w | 29^3<visitCount L A i t X w} β | |
| β j : Fin 3, {w | Rβ€βw (i,j)β} := by | |
| intro w hw | |
| by_contra hnot | |
| have hn : β j, βw (i,j)β<R := by simpa only [Set.mem_iUnion,Set.mem_ofPred_eq,not_exists,not_le] using hnot | |
| have hb := free_visited_card_le_of_norm L hL A i t w X (fun j β¦ ?_) | |
| Β· exact (not_lt_of_ge hb) hw | |
| Β· calc | |
| Real.sqrt (2*t)*βw (i,j)β β€ Real.sqrt (2*t)*R := mul_le_mul_of_nonneg_left (hn j).le hs.le | |
| _ = 1 := mul_inv_cancelβ (ne_of_gt hs) | |
| have he (j : Fin 3) : coordinateWiener n {w | Rβ€βw (i,j)β} = wiener {w | Rβ€βwβ} := by | |
| exact (measurePreserving_eval (fun _ : Direction n β¦ wiener) (i,j)).measure_preimage | |
| (measurableSet_le measurable_const measurable_norm).nullMeasurableSet | |
| calc | |
| _ β€ coordinateWiener n (β j : Fin 3, {w | Rβ€βw (i,j)β}) := measure_mono hsub | |
| _ β€ β' j : Fin 3, coordinateWiener n {w | Rβ€βw (i,j)β} := measure_iUnion_le _ | |
| _ = 3 * wiener {w | Rβ€βwβ} := by simp [he,tsum_fintype] | |
| _ β€ 3*(M*ENNReal.ofReal (Real.exp (-c*R^2))) := mul_le_mul_right (htail R hR) _ | |
| _ = _ := by | |
| dsimp [R] | |
| rw [inv_pow,Real.sq_sqrt (by positivity : 0β€2*t)] | |
| simp only [div_eq_mul_inv,mul_assoc] | |
| lemma visit_count_split {n K : β} (L : Length) (A : Finset (DiscreteTorus K)) (i : Fin n) | |
| {s t : β} (hs : 0<s) (ht : 0<t) (w : CoordinatePaths n) (X : Configuration n L) : | |
| visitCount L A i (s+t) X w β€ | |
| visitCount L A i s X (fun p β¦ normalizedPrefix (splitTime s t hs ht) (w p)) + | |
| visitCount L A i t | |
| (freeTrajectory n L s (fun p β¦ normalizedPrefix (splitTime s t hs ht) (w p)) X 1) | |
| (fun p β¦ normalizedSuffix (splitTime s t hs ht) (w p)) := by | |
| have hle := visited_card_split_le L (siteCenter L) A i (freeTrajectory n L (s+t) w X) | |
| (splitTime s t hs ht) (splitTime_pos s t hs ht) (splitTime_lt_one s t hs ht) | |
| have hp := congrArg Prod.fst (split_fixedTrajectory n L s t hs ht w X) | |
| have hq := congrArg Prod.snd (split_fixedTrajectory n L s t hs ht w X) | |
| dsimp only [Prod.fst,Prod.snd] at hp hq | |
| rw [hp,hq] at hle | |
| exact hle | |
| attribute [local irreducible] freeTrajectory pathVisitedSites | |
| lemma visit_tail_add {n K : β} (L : Length) (A : Finset (DiscreteTorus K)) (i : Fin n) | |
| {s t : β} (hs : 0<s) (ht : 0<t) (a b : β) (p q : ββ₯0β) | |
| (hsbound : β X, coordinateWiener n {w | a<visitCount L A i s X w}β€p) | |
| (htbound : β X, coordinateWiener n {w | b<visitCount L A i t X w}β€q) | |
| (X : Configuration n L) : | |
| coordinateWiener n {w | a+b<visitCount L A i (s+t) X w}β€p+q := by | |
| let u := splitTime s t hs ht | |
| let split : CoordinatePaths n β CoordinatePaths n Γ CoordinatePaths n := fun w β¦ | |
| (fun p β¦ normalizedPrefix u (w p),fun p β¦ normalizedSuffix u (w p)) | |
| let Eβ : Set (CoordinatePaths n Γ CoordinatePaths n) := | |
| {p | a<visitCount L A i s X p.1} | |
| let Eβ : Set (CoordinatePaths n Γ CoordinatePaths n) := | |
| {p | b<visitCount L A i t (freeTrajectory n L s p.1 X 1) p.2} | |
| have hEβ : MeasurableSet Eβ := measurableSet_lt measurable_const | |
| ((visitCount_measurable L A i s X).comp measurable_fst) | |
| have hEβ : MeasurableSet Eβ := by | |
| apply measurableSet_lt measurable_const | |
| exact (pathVisitedSites_card_measurable L (siteCenter L) A i).comp | |
| (measurable_snd.comp (split_fixedTrajectory_measurable n L s t X)) | |
| have hsub : {w | a+b<visitCount L A i (s+t) X w} β split β»ΒΉ' (EββͺEβ) := by | |
| intro w hw | |
| have hle := visit_count_split L A i hs ht w X | |
| change a<visitCount L A i s X (split w).1 β¨ | |
| b<visitCount L A i t (freeTrajectory n L s (split w).1 X 1) (split w).2 | |
| change a+b<visitCount L A i (s+t) X w at hw | |
| change visitCount L A i (s+t) X w β€ visitCount L A i s X (split w).1 + | |
| visitCount L A i t (freeTrajectory n L s (split w).1 X 1) (split w).2 at hle | |
| omega | |
| have hpβ : ((coordinateWiener n).prod (coordinateWiener n)) Eββ€p := by | |
| have he : Eβ={w | a<visitCount L A i s X w} ΓΛ’ Set.univ := by ext v; simp [Eβ] | |
| rw [he,Measure.prod_prod,measure_univ,mul_one] | |
| exact hsbound X | |
| have hpβ : ((coordinateWiener n).prod (coordinateWiener n)) Eββ€q := by | |
| rw [Measure.prod_apply hEβ] | |
| calc | |
| _ β€ β«β» _w : CoordinatePaths n, q βcoordinateWiener n := by | |
| apply lintegral_mono | |
| intro w | |
| exact htbound (freeTrajectory n L s w X 1) | |
| _ = q := by simp | |
| calc | |
| _ β€ coordinateWiener n (split β»ΒΉ' (EββͺEβ)) := measure_mono hsub | |
| _ = ((coordinateWiener n).prod (coordinateWiener n)) (EββͺEβ) := | |
| (coordinateSplit_preserving n u (splitTime_pos s t hs ht) (splitTime_lt_one s t hs ht)).measure_preimage | |
| (hEβ.union hEβ).nullMeasurableSet | |
| _ β€ ((coordinateWiener n).prod (coordinateWiener n)) Eβ + | |
| ((coordinateWiener n).prod (coordinateWiener n)) Eβ := measure_union_le _ _ | |
| _ β€ p+q := add_le_add hpβ hpβ | |
| lemma n_segment_visit_tail {c : β} {M : ββ₯0β} | |
| (htail : β R : β, 0β€R β wiener {w | Rβ€βwβ}β€M*ENNReal.ofReal (Real.exp (-c*R^2))) | |
| {n K : β} [NeZero K] (L : Length) (hL : L.val=(K:β)) | |
| (A : Finset (DiscreteTorus K)) (i : Fin n) {t : β} (ht : 0<t) : | |
| β k : β, 0<k β β X : Configuration n L, | |
| coordinateWiener n {w | 29^3*k<visitCount L A i ((k:β)*t) X w} β€ | |
| (k:ββ₯0β)*(3*M*ENNReal.ofReal (Real.exp (-c/(2*t)))) := by | |
| intro k hk | |
| induction k, hk using Nat.le_induction with | |
| | base => | |
| intro X | |
| simpa only [Nat.succ_eq_add_one,Nat.zero_add,Nat.cast_one,one_mul,mul_one] using one_segment_visit_tail htail L hL A i ht X | |
| | succ k hk ih => | |
| intro X | |
| have hkt : 0<(k:β)*t := mul_pos (by exact_mod_cast hk) ht | |
| have h := visit_tail_add L A i hkt ht (29^3*k) (29^3) | |
| ((k:ββ₯0β)*(3*M*ENNReal.ofReal (Real.exp (-c/(2*t))))) | |
| (3*M*ENNReal.ofReal (Real.exp (-c/(2*t)))) ih | |
| (fun X β¦ one_segment_visit_tail htail L hL A i ht X) X | |
| convert h using 1 <;> push_cast <;> ring_nf | |
| lemma whole_time_visit_tail {c : β} {M : ββ₯0β} | |
| (htail : β R : β, 0β€R β wiener {w | Rβ€βwβ}β€M*ENNReal.ofReal (Real.exp (-c*R^2))) | |
| {n K : β} [NeZero K] (L : Length) (hL : L.val=(K:β)) | |
| (A : Finset (DiscreteTorus K)) (i : Fin n) {t : β} (ht : 0<t) | |
| (k : β) (hk : 0<k) (X : Configuration n L) : | |
| coordinateWiener n {w | 29^3*k<visitCount L A i t X w} β€ | |
| (k:ββ₯0β)*(3*M*ENNReal.ofReal (Real.exp (-c*(k:β)/(2*t)))) := by | |
| have hk' : (0:β)<k := by exact_mod_cast hk | |
| have h := n_segment_visit_tail htail L hL A i (div_pos ht hk') k hk X | |
| have he : (k:β)*(t/k)=t := mul_div_cancelβ t (ne_of_gt hk') | |
| rw [he] at h | |
| convert h using 1 | |
| congr 3 | |
| field_simp | |
| end HardSphere.FreeVisits | |
| end | |
| end | |
| end | |
| end OAI | |