Buckets:
| import Mathlib | |
| import OAI.Analysis.CoulombIonization.Variational.ExpectedTruncatedControl | |
| import OAI.Analysis.CoulombIonization.Localization.OriginalPosteriorKernel | |
| import OAI.Analysis.CoulombIonization.FormDomain.FormRawPotential | |
| namespace OAI | |
| noncomputable section | |
| namespace CoulombAtom | |
| open MeasureTheory Filter | |
| open scoped Topology BigOperators ContDiff | |
| open MeasureTheory Filter Set Metric | |
| open scoped BigOperators ContDiff | |
| open CoulombAnalysis | |
| lemma masterKernel_pole_integrable {c₁ r₀ s : ℝ} (hc : 0 < c₁) (hr : 0 < r₀) (hs : 0 < s) | |
| {g : Space → ℝ} (hg : ContDiff ℝ ∞ g) (hcg : HasCompactSupport g) (x y : Space) : | |
| Integrable (fun z => masterKernel c₁ r₀ s g x z/‖y-z‖) := by | |
| have hη := scaled_packet_density_compact (masterWidth_pos hc hr hs x) hcg | |
| have hηc := (scaledRealPacket_smooth (masterWidth c₁ r₀ s x) hg).continuous.pow 2 | |
| exact translated_pole_integrable (hηc.integrable_of_hasCompactSupport hη) | |
| (hηc.memLp_of_hasCompactSupport hη) y x | |
| lemma master_configuration_potential_integrable {N : ℕ} (ν : Measure (Configuration N)) | |
| (y : Space) (hi : Integrable (rawPotential y) ν) (he : ∀ᵐ x ∂ν, ∀ i, x i ≠ y) | |
| {c₁ r₀ s : ℝ} (hc : 0 < c₁) (hr : 0 < r₀) (hs : 0 < s) | |
| {g : Space → ℝ} (hg : ContDiff ℝ ∞ g) (hcg : HasCompactSupport g) | |
| (hgn : ∫ z, (g z)^2 = 1) (hrad : IsRadial g) (hgs : tsupport g ⊆ ball 0 1) : | |
| Integrable (fun x : Configuration N => ∑ i, tfPotential (masterKernel c₁ r₀ s g (x i)) y) ν := by | |
| apply hi.mono' ((Finset.measurable_sum _ (fun i _ => | |
| (masterKernel_pole_measurable hc hr hs hg.continuous y).comp (measurable_pi_apply i))).aestronglyMeasurable) | |
| filter_upwards [he] with x hx | |
| change ‖∑ i, tfPotential (masterKernel c₁ r₀ s g (x i)) y‖ ≤ rawPotential y x | |
| rw [Real.norm_of_nonneg (Finset.sum_nonneg (fun i _ => masterKernel_potential_nonneg c₁ r₀ s g (x i) y))] | |
| apply Finset.sum_le_sum | |
| intro i _ | |
| simpa only [norm_sub_rev] using masterKernel_potential_le hc hr hs hg hcg hgn hrad hgs (hx i) | |
| lemma master_configuration_pole_integrable {N : ℕ} (ν : Measure (Configuration N)) | |
| (y : Space) (hi : Integrable (rawPotential y) ν) (he : ∀ᵐ x ∂ν, ∀ i, x i ≠ y) | |
| {c₁ r₀ s : ℝ} (hc : 0 < c₁) (hr : 0 < r₀) (hs : 0 < s) | |
| {g : Space → ℝ} (hg : ContDiff ℝ ∞ g) (hcg : HasCompactSupport g) | |
| (hgn : ∫ z, (g z)^2 = 1) (hrad : IsRadial g) (hgs : tsupport g ⊆ ball 0 1) : | |
| Integrable (fun p : Configuration N × Space => (∑ i, masterKernel c₁ r₀ s g (p.1 i) p.2)/‖y-p.2‖) | |
| (ν.prod volume) := by | |
| have hm : Measurable (fun p : Configuration N × Space => (∑ i, masterKernel c₁ r₀ s g (p.1 i) p.2)/‖y-p.2‖) := | |
| (Finset.measurable_sum _ (fun i _ => (masterKernel_joint_continuous hc hr hs hg.continuous).measurable.comp | |
| (((measurable_pi_apply i).comp measurable_fst).prodMk measurable_snd))).div (by fun_prop) | |
| apply (integrable_prod_iff hm.aestronglyMeasurable).mpr | |
| refine ⟨ae_of_all _ (fun x => ?_),?_⟩ | |
| · simp only [Finset.sum_div] | |
| exact integrable_finsetSum _ (fun i _ => masterKernel_pole_integrable hc hr hs hg hcg (x i) y) | |
| · have hp := master_configuration_potential_integrable ν y hi he hc hr hs hg hcg hgn hrad hgs | |
| convert hp using 1 | |
| funext x | |
| simp only [Finset.sum_div] | |
| simp_rw [Real.norm_of_nonneg (Finset.sum_nonneg (fun i _ => | |
| div_nonneg (masterKernel_nonneg c₁ r₀ s g (x i) _) (norm_nonneg _)))] | |
| exact integral_finsetSum _ (fun i _ => masterKernel_pole_integrable hc hr hs hg hcg (x i) y) | |
| theorem master_configuration_potential_fubini {N : ℕ} (ν : Measure (Configuration N)) [SFinite ν] | |
| (y : Space) (hi : Integrable (rawPotential y) ν) (he : ∀ᵐ x ∂ν, ∀ i, x i ≠ y) | |
| {c₁ r₀ s : ℝ} (hc : 0 < c₁) (hr : 0 < r₀) (hs : 0 < s) | |
| {g : Space → ℝ} (hg : ContDiff ℝ ∞ g) (hcg : HasCompactSupport g) | |
| (hgn : ∫ z, (g z)^2 = 1) (hrad : IsRadial g) (hgs : tsupport g ⊆ ball 0 1) : | |
| tfPotential (fun z => ∫ x, ∑ i, masterKernel c₁ r₀ s g (x i) z ∂ν) y = | |
| ∫ x, ∑ i, tfPotential (masterKernel c₁ r₀ s g (x i)) y ∂ν := by | |
| change (∫ z, (∫ x, ∑ i, masterKernel c₁ r₀ s g (x i) z ∂ν)/‖y-z‖) = _ | |
| calc | |
| _ = ∫ z, ∫ x, (∑ i, masterKernel c₁ r₀ s g (x i) z)/‖y-z‖ ∂ν := by simp only [integral_div] | |
| _ = ∫ x, (∫ z, (∑ i, masterKernel c₁ r₀ s g (x i) z)/‖y-z‖) ∂ν := | |
| integral_integral_swap (master_configuration_pole_integrable ν y hi he hc hr hs hg hcg hgn hrad hgs).swap | |
| _ = _ := by | |
| apply integral_congr_ae | |
| exact ae_of_all _ (fun x => by | |
| simp only [Finset.sum_div] | |
| exact integral_finsetSum _ (fun i _ => masterKernel_pole_integrable hc hr hs hg hcg (x i) y)) | |
| section Work_MasterConfigurationLoss_scope | |
| open MeasureTheory Filter Set Metric | |
| open scoped BigOperators ContDiff | |
| open CoulombAnalysis | |
| lemma rawLocalPotential_eq_indicator {N : ℕ} (y : Space) (q : ℝ) (x : Configuration N) : | |
| rawLocalPotential y q x = ∑ i, (ball y q).indicator (fun z => 1/‖z-y‖) (x i) := by | |
| classical | |
| unfold rawLocalPotential | |
| apply Finset.sum_congr rfl | |
| intro i _ | |
| by_cases h : ‖x i-y‖ < q | |
| · rw [ite_eq_left h,Set.indicator_of_mem (by simpa only [mem_ball,dist_eq_norm] using h)] | |
| · rw [ite_eq_right h,Set.indicator_of_notMem (by simpa only [mem_ball,dist_eq_norm] using h)] | |
| lemma rawLocalPotential_integrable_of_raw {N : ℕ} {ν : Measure (Configuration N)} | |
| (y : Space) (q : ℝ) (hi : Integrable (rawPotential y) ν) : | |
| Integrable (rawLocalPotential y q) ν := by | |
| apply hi.mono' (rawLocalPotential_measurable N y q).aestronglyMeasurable | |
| exact ae_of_all _ (fun x => by | |
| simpa only [Real.norm_of_nonneg (rawLocalPotential_nonneg y q x)] using | |
| (rawLocalPotential_le_raw y q x)) | |
| theorem master_configuration_potential_loss {N : ℕ} (ν : Measure (Configuration N)) [SFinite ν] | |
| (y : Space) (hi : Integrable (rawPotential y) ν) (he : ∀ᵐ x ∂ν, ∀ i, x i ≠ y) | |
| {c₁ r₀ s : ℝ} (hc : 0 < c₁) (hcL : c₁ < (10*(100000:ℝ))⁻¹) | |
| (hr : 0 < r₀) (hs : 0 < s) (hs1 : s ≤ 1) | |
| {g : Space → ℝ} (hg : ContDiff ℝ ∞ g) (hcg : HasCompactSupport g) | |
| (hgn : ∫ z, (g z)^2 = 1) (hrad : IsRadial g) (hgs : tsupport g ⊆ ball 0 1) : | |
| 0 ≤ (∫ x, rawPotential y x ∂ν)- | |
| tfPotential (fun z => ∫ x, ∑ i, masterKernel c₁ r₀ s g (x i) z ∂ν) y ∧ | |
| (∫ x, rawPotential y x ∂ν)- | |
| tfPotential (fun z => ∫ x, ∑ i, masterKernel c₁ r₀ s g (x i) z ∂ν) y ≤ | |
| ∫ x, rawLocalPotential y (2*masterWidth c₁ r₀ s y) x ∂ν := by | |
| rw [master_configuration_potential_fubini ν y hi he hc hr hs hg hcg hgn hrad hgs] | |
| have hp := master_configuration_potential_integrable ν y hi he hc hr hs hg hcg hgn hrad hgs | |
| rw [←integral_sub hi hp] | |
| have hh : ∀ᵐ x ∂ν, | |
| 0 ≤ rawPotential y x-(∑ i, tfPotential (masterKernel c₁ r₀ s g (x i)) y) ∧ | |
| rawPotential y x-(∑ i, tfPotential (masterKernel c₁ r₀ s g (x i)) y) ≤ | |
| rawLocalPotential y (2*masterWidth c₁ r₀ s y) x := by | |
| filter_upwards [he] with x hx | |
| have hpoint (i : Fin N) := masterKernel_potential_loss hc hcL hr hs hs1 hg hcg hgn hrad hgs (hx i) | |
| simp only [rawPotential,←Finset.sum_sub_distrib,rawLocalPotential_eq_indicator] | |
| constructor | |
| · exact Finset.sum_nonneg (fun i _ => by simpa only [norm_sub_rev] using (hpoint i).1) | |
| · apply Finset.sum_le_sum | |
| intro i _ | |
| simpa only [norm_sub_rev] using (hpoint i).2 | |
| exact ⟨integral_nonneg_of_ae (hh.mono fun _ h => h.1), | |
| integral_mono_ae (hi.sub hp) (rawLocalPotential_integrable_of_raw y _ hi) (hh.mono fun _ h => h.2)⟩ | |
| end Work_MasterConfigurationLoss_scope | |
| open MeasureTheory Filter Set | |
| open scoped BigOperators | |
| open CoulombObservation ProbabilityTheory | |
| lemma originalRawKernel_comp {N K : ℕ} (μ : Measure (Configuration N)) [IsFiniteMeasure μ] | |
| (ell : Fin K → ℝ) (j : ℕ) : | |
| originalRawKernel μ ell j ∘ₘ ((physicalObservationLaw μ K).map (originalDatum ell j)) = μ := by | |
| rw [originalRawKernel,condDistrib_comp_map (originalDatum_measurable ell j).aemeasurable | |
| measurable_fst.aemeasurable] | |
| simp [physicalObservationLaw,Measure.map_fst_prod] | |
| lemma originalRawKernel_ae {N K : ℕ} (μ : Measure (Configuration N)) [IsFiniteMeasure μ] | |
| (ell : Fin K → ℝ) (j : ℕ) {P : Configuration N → Prop} (hP : ∀ᵐ x ∂μ, P x) : | |
| ∀ᵐ z ∂physicalObservationLaw μ K, ∀ᵐ x ∂originalRawKernel μ ell j (originalDatum ell j z), P x := by | |
| rw [←originalRawKernel_comp μ ell j] at hP | |
| exact ae_of_ae_map (originalDatum_measurable ell j).aemeasurable (Measure.ae_ae_of_ae_comp hP) | |
| lemma originalRawKernel_integrable {N K : ℕ} (μ : Measure (Configuration N)) [IsFiniteMeasure μ] | |
| (ell : Fin K → ℝ) (j : ℕ) {f : Configuration N → ℝ} (hf : Measurable f) (hi : Integrable f μ) : | |
| ∀ᵐ z ∂physicalObservationLaw μ K, | |
| Integrable f (originalRawKernel μ ell j (originalDatum ell j z)) := by | |
| have hx := originalDatum_measurable (N := N) ell j | |
| have he : (physicalObservationLaw μ K).map Prod.fst = μ := by | |
| simp [physicalObservationLaw,Measure.map_fst_prod] | |
| have hi0 : Integrable (fun a : Configuration N × (Fin K × (Fin N × Fin 3) → ℝ) => f a.1) | |
| (physicalObservationLaw μ K) := by | |
| apply (integrable_map_measure hf.aestronglyMeasurable measurable_fst.aemeasurable).mp | |
| rwa [he] | |
| have hi1 : Integrable (fun p : OriginalDatum N K ell j × Configuration N => f p.2) | |
| ((physicalObservationLaw μ K).map (fun a => (originalDatum ell j a,a.1))) := by | |
| apply (integrable_map_measure (hf.comp measurable_snd).aestronglyMeasurable | |
| (hx.prodMk measurable_fst).aemeasurable).mpr | |
| exact hi0 | |
| exact hi1.condDistrib_ae hx.aemeasurable measurable_fst.aemeasurable | |
| lemma kernelPosteriorTest_integrable {N K : ℕ} (μ : Measure (Configuration N)) [IsFiniteMeasure μ] | |
| (ell : Fin K → ℝ) (j : ℕ) {g : Space → ℝ} (hg : Measurable g) | |
| (hi : Integrable (fun x : Configuration N => ∑ i, g (x i)) μ) : | |
| Integrable (fun z => kernelPosteriorTest μ ell j g (originalDatum ell j z)) | |
| (physicalObservationLaw μ K) := by | |
| have he : (physicalObservationLaw μ K).map Prod.fst = μ := by | |
| simp [physicalObservationLaw,Measure.map_fst_prod] | |
| have hf : Measurable (fun x : Configuration N => ∑ i, g (x i)) := | |
| Finset.measurable_sum Finset.univ (fun i _ => hg.comp (measurable_pi_apply i)) | |
| have hi0 : Integrable (fun z : Configuration N × (Fin K × (Fin N × Fin 3) → ℝ) => ∑ i, g (z.1 i)) | |
| (physicalObservationLaw μ K) := by | |
| apply (integrable_map_measure hf.aestronglyMeasurable measurable_fst.aemeasurable).mp | |
| rwa [he] | |
| exact integrable_condExp.congr (kernelPosteriorTest_eq μ ell j hg hi0) | |
| lemma kernelPosteriorTest_mean {N K : ℕ} (μ : Measure (Configuration N)) [IsFiniteMeasure μ] | |
| (ell : Fin K → ℝ) (j : ℕ) {g : Space → ℝ} (hg : Measurable g) | |
| (hi : Integrable (fun x : Configuration N => ∑ i, g (x i)) μ) : | |
| (∫ z, kernelPosteriorTest μ ell j g (originalDatum ell j z) ∂physicalObservationLaw μ K) = | |
| ∫ x, ∑ i, g (x i) ∂μ := by | |
| have he : (physicalObservationLaw μ K).map Prod.fst = μ := by | |
| simp [physicalObservationLaw,Measure.map_fst_prod] | |
| have hf : Measurable (fun x : Configuration N => ∑ i, g (x i)) := | |
| Finset.measurable_sum Finset.univ (fun i _ => hg.comp (measurable_pi_apply i)) | |
| have hi0 : Integrable (fun z : Configuration N × (Fin K × (Fin N × Fin 3) → ℝ) => ∑ i, g (z.1 i)) | |
| (physicalObservationLaw μ K) := by | |
| apply (integrable_map_measure hf.aestronglyMeasurable measurable_fst.aemeasurable).mp | |
| rwa [he] | |
| rw [←integral_congr_ae (kernelPosteriorTest_eq μ ell j hg hi0)] | |
| rw [posteriorTestValue,integral_condExp (observationInformation_le ell j)] | |
| exact (integral_map measurable_fst.aemeasurable hf.aestronglyMeasurable).symm.trans (by rw [he]) | |
| lemma kernelPosteriorTest_eq_of_integrable {N K : ℕ} (μ : Measure (Configuration N)) [IsFiniteMeasure μ] | |
| (ell : Fin K → ℝ) (j : ℕ) {g : Space → ℝ} (hg : Measurable g) | |
| (hi : Integrable (fun x : Configuration N => ∑ i, g (x i)) μ) : | |
| posteriorTestValue μ ell j g =ᵐ[physicalObservationLaw μ K] | |
| fun z => kernelPosteriorTest μ ell j g (originalDatum ell j z) := by | |
| have he : (physicalObservationLaw μ K).map Prod.fst = μ := by | |
| simp [physicalObservationLaw,Measure.map_fst_prod] | |
| have hf : Measurable (fun x : Configuration N => ∑ i, g (x i)) := | |
| Finset.measurable_sum Finset.univ (fun i _ => hg.comp (measurable_pi_apply i)) | |
| apply kernelPosteriorTest_eq μ ell j hg | |
| apply (integrable_map_measure hf.aestronglyMeasurable measurable_fst.aemeasurable).mp | |
| rwa [he] | |
| end CoulombAtom | |
| end | |
| end OAI | |
Xet Storage Details
- Size:
- 12.9 kB
- Xet hash:
- 848ab84118b44be89a4d7f2879712011e007d08f5018e1fb03823cd0b09bda6c
·
Xet efficiently stores files, intelligently splitting them into unique chunks and accelerating uploads and downloads. More info.