Skip to content

Commit 4f9fb53

Browse files
EtienneC30Bergschaf
authored andcommitted
feat: add an alias for the forward direction of indepFun_iff_map_prod_eq_prod_map_map (leanprover-community#39767)
When assuming `hXY : IndepFun X Y P`, if one wants to rewrite `P.map (fun w => (X w, Y w)) = (P.map X).prod (P.map Y)`, one has to use [ProbabilityTheory.indepFun_iff_map_prod_eq_prod_map_map](https://leanprover-community.github.io/mathlib4_docs/Mathlib/Probability/Independence/Basic.html#ProbabilityTheory.indepFun_iff_map_prod_eq_prod_map_map), which is an iff with side-condition so is not convenient. We thus introduce an alias for this direction. We do the same for the `iIndepFun` version, removing the unnecessary `IsProbabilityMeasure` hypothesis there. We do the same in the `infinitePi` case too.
1 parent adca138 commit 4f9fb53

6 files changed

Lines changed: 120 additions & 80 deletions

File tree

Mathlib/Probability/HasLaw.lean

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -188,7 +188,7 @@ lemma indepFun_iff_hasLaw_prodMk_prod [IsFiniteMeasure P] {𝓨 : Type*} {m𝓨
188188
X ⟂ᵢ[P] Y ↔ HasLaw (fun ω ↦ (X ω, Y ω)) (μ.prod ν) P where
189189
mp h :=
190190
{ map_eq := by
191-
rw [(indepFun_iff_map_prod_eq_prod_map_map (by fun_prop) (by fun_prop)).1 h, hX.map_eq,
191+
rw [h.map_prod_eq_prod_map_map (by fun_prop) (by fun_prop), hX.map_eq,
192192
hY.map_eq] }
193193
mpr h := by
194194
rw [indepFun_iff_map_prod_eq_prod_map_map (by fun_prop) (by fun_prop),
@@ -201,8 +201,7 @@ lemma iIndepFun.hasLaw_pi {ι : Type*} [Fintype ι] {𝓧 : ι → Type*} {m𝓧
201201
(h : iIndepFun X P) :
202202
HasLaw (fun ω i ↦ X i ω) (Measure.pi μ) P where
203203
map_eq := by
204-
have := h.isProbabilityMeasure
205-
rw [(iIndepFun_iff_map_fun_eq_pi_map (by fun_prop)).1 h]
204+
rw [h.map_fun_eq_pi_map (by fun_prop)]
206205
simp_rw [fun i ↦ (hX i).map_eq]
207206

208207
lemma iIndepFun_iff_hasLaw_pi_pi [IsProbabilityMeasure P] {ι : Type*} [Fintype ι] {𝓧 : ι → Type*}

Mathlib/Probability/IdentDistrib.lean

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -348,8 +348,7 @@ lemma indepFun_of_identDistrib_pair
348348
{X : γ → α} {X' : δ → α} {Y : γ → β} {Y' : δ → β} (h_indep : X ⟂ᵢ[μ] Y)
349349
(h_ident : IdentDistrib (fun ω ↦ (X ω, Y ω)) (fun ω ↦ (X' ω, Y' ω)) μ μ') :
350350
X' ⟂ᵢ[μ'] Y' := by
351-
rw [indepFun_iff_map_prod_eq_prod_map_map _ _, ← h_ident.map_eq,
352-
(indepFun_iff_map_prod_eq_prod_map_map _ _).1 h_indep]
351+
rw [indepFun_iff_map_prod_eq_prod_map_map, ← h_ident.map_eq, h_indep.map_prod_eq_prod_map_map]
353352
· exact congr (congrArg Measure.prod <| (h_ident.comp measurable_fst).map_eq)
354353
(h_ident.comp measurable_snd).map_eq
355354
· exact measurable_fst.aemeasurable.comp_aemeasurable h_ident.aemeasurable_fst

Mathlib/Probability/IdentDistribIndep.lean

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -47,8 +47,8 @@ lemma IdentDistrib.prodMk [IsFiniteMeasure μ]
4747
have : IsFiniteMeasure ν := by
4848
have : IsFiniteMeasure (ν.map Z) := by rw [← hXZ.map_eq]; infer_instance
4949
exact Measure.isFiniteMeasure_of_map hXZ.aemeasurable_snd
50-
rw [(indepFun_iff_map_prod_eq_prod_map_map hXZ.aemeasurable_fst hYW.aemeasurable_fst).mp hXY,
51-
(indepFun_iff_map_prod_eq_prod_map_map hXZ.aemeasurable_snd hYW.aemeasurable_snd).mp hZW,
50+
rw [hXY.map_prod_eq_prod_map_map hXZ.aemeasurable_fst hYW.aemeasurable_fst,
51+
hZW.map_prod_eq_prod_map_map hXZ.aemeasurable_snd hYW.aemeasurable_snd,
5252
hXZ.map_eq, hYW.map_eq]
5353

5454
/-- If `(X i)` and `(Y i)` are families of independent random variables indexed by a countable

Mathlib/Probability/Independence/Basic.lean

Lines changed: 66 additions & 46 deletions
Original file line numberDiff line numberDiff line change
@@ -705,33 +705,7 @@ theorem indepFun_iff_map_prod_eq_prod_map_map {mβ : MeasurableSpace β} {mβ' :
705705
f ⟂ᵢ[μ] g ↔ μ.map (fun ω ↦ (f ω, g ω)) = (μ.map f).prod (μ.map g) := by
706706
apply indepFun_iff_map_prod_eq_prod_map_map' hf hg <;> apply IsFiniteMeasure.toSigmaFinite
707707

708-
theorem iIndepFun_iff_map_fun_eq_pi_map [Fintype ι] {β : ι → Type*}
709-
{m : ∀ i, MeasurableSpace (β i)} {f : Π i, Ω → β i} [IsProbabilityMeasure μ]
710-
(hf : ∀ i, AEMeasurable (f i) μ) :
711-
iIndepFun f μ ↔ μ.map (fun ω i ↦ f i ω) = Measure.pi (fun i ↦ μ.map (f i)) := by
712-
classical
713-
rw [iIndepFun_iff_measure_inter_preimage_eq_mul]
714-
have h₀ {s : ∀ i, Set (β i)} (hm : ∀ (i : ι), MeasurableSet (s i)) :
715-
∏ i : ι, μ (f i ⁻¹' s i) = ∏ i : ι, μ.map (f i) (s i) ∧
716-
μ (⋂ i : ι, (f i ⁻¹' s i)) = μ.map (fun ω i ↦ f i ω) (univ.pi s) := by
717-
constructor
718-
· congr with x
719-
rw [Measure.map_apply_of_aemeasurable (hf x) (hm x)]
720-
· rw [Measure.map_apply_of_aemeasurable (aemeasurable_pi_lambda _ fun x ↦ hf x)
721-
(.univ_pi hm)]
722-
congr with x
723-
simp
724-
constructor
725-
· refine fun hS ↦ (Measure.pi_eq fun h hm ↦ ?_).symm
726-
rw [← (h₀ hm).1, ← (h₀ hm).2]
727-
simpa [hm] using hS Finset.univ (sets := h)
728-
· intro h S s hs
729-
specialize h₀ (s := fun i ↦ if i ∈ S then s i else univ)
730-
fun i ↦ by beta_reduce; split_ifs with hiS <;> simp [hiS, hs]
731-
simp only [apply_ite, preimage_univ, measure_univ, Finset.prod_ite_mem, Finset.univ_inter,
732-
Finset.prod_ite, Finset.filter_univ_mem, iInter_ite, iInter_univ, inter_univ, h,
733-
Measure.pi_pi] at h₀
734-
rw [h₀.2, ← h₀.1]
708+
alias ⟨IndepFun.map_prod_eq_prod_map_map, _⟩ := indepFun_iff_map_prod_eq_prod_map_map
735709

736710
@[symm]
737711
nonrec theorem IndepFun.symm {_ : MeasurableSpace β} {_ : MeasurableSpace β'}
@@ -777,25 +751,6 @@ lemma indepFun_prod₀ (mX : AEMeasurable X μ) (mY : AEMeasurable Y ν) :
777751
· rw [measurePreserving_snd.map_eq]
778752
exact (AEMeasurable.ae_eq_mk mY).symm
779753

780-
variable {ι : Type*} [Fintype ι] {Ω : ι → Type*} {mΩ : ∀ i, MeasurableSpace (Ω i)}
781-
{μ : (i : ι) → Measure (Ω i)} [∀ i, IsProbabilityMeasure (μ i)]
782-
{𝓧 : ι → Type*} [∀ i, MeasurableSpace (𝓧 i)] {X : (i : ι) → Ω i → 𝓧 i}
783-
784-
/-- Given random variables `X i : Ω i → 𝓧 i`, they are independent when viewed as random
785-
variables defined on the product space `Π i, Ω i`. -/
786-
lemma iIndepFun_pi (mX : ∀ i, AEMeasurable (X i) (μ i)) :
787-
iIndepFun (fun i ω ↦ X i (ω i)) (Measure.pi μ) := by
788-
refine iIndepFun_iff_map_fun_eq_pi_map ?_ |>.2 ?_
789-
· exact fun i ↦ (mX i).comp_quasiMeasurePreserving (Measure.quasiMeasurePreserving_eval _ i)
790-
rw [Measure.pi_map_pi mX]
791-
congr
792-
ext i : 1
793-
rw [← (measurePreserving_eval μ i).map_eq, AEMeasurable.map_map_of_aemeasurable,
794-
Function.comp_def]
795-
· rw [(measurePreserving_eval μ i).map_eq]
796-
exact mX i
797-
· exact (measurable_pi_apply i).aemeasurable
798-
799754
end Prod
800755

801756
theorem IndepFun.comp {_mβ : MeasurableSpace β} {_mβ' : MeasurableSpace β'}
@@ -882,6 +837,71 @@ lemma iIndepFun_iff_finset : iIndepFun f μ ↔ ∀ s : Finset ι, iIndepFun (s.
882837

883838
alias ⟨iIndepFun.restrict, _⟩ := iIndepFun_iff_finset
884839

840+
theorem iIndepFun.map_fun_eq_pi_map [Fintype ι] {β : ι → Type*}
841+
{m : ∀ i, MeasurableSpace (β i)} {f : Π i, Ω → β i}
842+
(hf : ∀ i, AEMeasurable (f i) μ) (h : iIndepFun f μ) :
843+
μ.map (fun ω i ↦ f i ω) = Measure.pi (fun i ↦ μ.map (f i)) := by
844+
classical
845+
have := h.isProbabilityMeasure
846+
rw [iIndepFun_iff_measure_inter_preimage_eq_mul] at h
847+
have h₀ {s : ∀ i, Set (β i)} (hm : ∀ (i : ι), MeasurableSet (s i)) :
848+
∏ i : ι, μ (f i ⁻¹' s i) = ∏ i : ι, μ.map (f i) (s i) ∧
849+
μ (⋂ i : ι, (f i ⁻¹' s i)) = μ.map (fun ω i ↦ f i ω) (univ.pi s) := by
850+
constructor
851+
· congr with x
852+
rw [Measure.map_apply_of_aemeasurable (hf x) (hm x)]
853+
· rw [Measure.map_apply_of_aemeasurable (aemeasurable_pi_lambda _ fun x ↦ hf x)
854+
(.univ_pi hm)]
855+
congr with x
856+
simp
857+
refine (Measure.pi_eq fun h' hm ↦ ?_).symm
858+
rw [← (h₀ hm).1, ← (h₀ hm).2]
859+
simpa [hm] using h Finset.univ (sets := h')
860+
861+
theorem iIndepFun_iff_map_fun_eq_pi_map [Fintype ι] {β : ι → Type*}
862+
{m : ∀ i, MeasurableSpace (β i)} {f : Π i, Ω → β i} [IsProbabilityMeasure μ]
863+
(hf : ∀ i, AEMeasurable (f i) μ) :
864+
iIndepFun f μ ↔ μ.map (fun ω i ↦ f i ω) = Measure.pi (fun i ↦ μ.map (f i)) := by
865+
refine ⟨iIndepFun.map_fun_eq_pi_map hf, ?_⟩
866+
classical
867+
rw [iIndepFun_iff_measure_inter_preimage_eq_mul]
868+
have h₀ {s : ∀ i, Set (β i)} (hm : ∀ (i : ι), MeasurableSet (s i)) :
869+
∏ i : ι, μ (f i ⁻¹' s i) = ∏ i : ι, μ.map (f i) (s i) ∧
870+
μ (⋂ i : ι, (f i ⁻¹' s i)) = μ.map (fun ω i ↦ f i ω) (univ.pi s) := by
871+
constructor
872+
· congr with x
873+
rw [Measure.map_apply_of_aemeasurable (hf x) (hm x)]
874+
· rw [Measure.map_apply_of_aemeasurable (aemeasurable_pi_lambda _ fun x ↦ hf x)
875+
(.univ_pi hm)]
876+
congr with x
877+
simp
878+
intro h S s hs
879+
specialize h₀ (s := fun i ↦ if i ∈ S then s i else univ)
880+
fun i ↦ by beta_reduce; split_ifs with hiS <;> simp [hiS, hs]
881+
simp only [apply_ite, preimage_univ, measure_univ, Finset.prod_ite_mem, Finset.univ_inter,
882+
Finset.prod_ite, Finset.filter_univ_mem, iInter_ite, iInter_univ, inter_univ, h,
883+
Measure.pi_pi] at h₀
884+
rw [h₀.2, ← h₀.1]
885+
886+
variable {ι : Type*} [Fintype ι] {Ω : ι → Type*} {mΩ : ∀ i, MeasurableSpace (Ω i)}
887+
{μ : (i : ι) → Measure (Ω i)} [∀ i, IsProbabilityMeasure (μ i)]
888+
{𝓧 : ι → Type*} [∀ i, MeasurableSpace (𝓧 i)] {X : (i : ι) → Ω i → 𝓧 i}
889+
890+
/-- Given random variables `X i : Ω i → 𝓧 i`, they are independent when viewed as random
891+
variables defined on the product space `Π i, Ω i`. -/
892+
lemma iIndepFun_pi (mX : ∀ i, AEMeasurable (X i) (μ i)) :
893+
iIndepFun (fun i ω ↦ X i (ω i)) (Measure.pi μ) := by
894+
refine iIndepFun_iff_map_fun_eq_pi_map ?_ |>.2 ?_
895+
· exact fun i ↦ (mX i).comp_quasiMeasurePreserving (Measure.quasiMeasurePreserving_eval _ i)
896+
rw [Measure.pi_map_pi mX]
897+
congr
898+
ext i : 1
899+
rw [← (measurePreserving_eval μ i).map_eq, AEMeasurable.map_map_of_aemeasurable,
900+
Function.comp_def]
901+
· rw [(measurePreserving_eval μ i).map_eq]
902+
exact mX i
903+
· exact (measurable_pi_apply i).aemeasurable
904+
885905
end iIndepFun
886906

887907
section Mul

Mathlib/Probability/Independence/InfinitePi.lean

Lines changed: 44 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -33,29 +33,39 @@ open MeasureTheory Measure ProbabilityTheory
3333

3434
namespace ProbabilityTheory
3535

36-
variable {ι Ω : Type*} {mΩ : MeasurableSpace Ω} {P : Measure Ω} [IsProbabilityMeasure P]
36+
variable {ι Ω : Type*} {mΩ : MeasurableSpace Ω} {P : Measure Ω}
3737
{𝓧 : ι → Type*} {m𝓧 : ∀ i, MeasurableSpace (𝓧 i)} {X : Π i, Ω → 𝓧 i}
3838

39+
/-- If random variables are independent then their joint distribution is the product measure. This
40+
is a version where the random variable `ω ↦ (Xᵢ(ω))ᵢ` is almost everywhere measurable.
41+
See `iIndepFun.map_fun_eq_infinitePi_map₀'` for a version which only assumes that
42+
each `Xᵢ` is almost everywhere measurable and that `ι` is countable. -/
43+
lemma iIndepFun.map_fun_eq_infinitePi_map₀ (mX : AEMeasurable (fun ω i ↦ X i ω) P)
44+
(h : iIndepFun X P) :
45+
P.map (fun ω i ↦ X i ω) = infinitePi (fun i ↦ P.map (X i)) := by
46+
have := h.isProbabilityMeasure
47+
have _ i := isProbabilityMeasure_map (mX.eval i)
48+
refine eq_infinitePi _ fun s t ht ↦ ?_
49+
rw [iIndepFun_iff_finset] at h
50+
have : (s : Set ι).pi t = s.restrict ⁻¹' (Set.univ.pi fun i ↦ t i) := by ext; simp
51+
rw [this, ← map_apply, AEMeasurable.map_map_of_aemeasurable]
52+
· have : s.restrict ∘ (fun ω i ↦ X i ω) = fun ω i ↦ s.restrict X i ω := by ext; simp
53+
rw [this, (h s).map_fun_eq_pi_map, pi_pi]
54+
· simp only [Finset.restrict]
55+
rw [s.prod_coe_sort fun i ↦ P.map (X i) (t i)]
56+
exact fun i ↦ mX.eval i
57+
any_goals fun_prop
58+
· exact mX
59+
· exact .univ_pi fun i ↦ ht i
60+
3961
/-- Random variables are independent iff their joint distribution is the product measure. This
4062
is a version where the random variable `ω ↦ (Xᵢ(ω))ᵢ` is almost everywhere measurable.
4163
See `iIndepFun_iff_map_fun_eq_infinitePi_map₀'` for a version which only assumes that
4264
each `Xᵢ` is almost everywhere measurable and that `ι` is countable. -/
43-
lemma iIndepFun_iff_map_fun_eq_infinitePi_map₀ (mX : AEMeasurable (fun ω i ↦ X i ω) P) :
65+
lemma iIndepFun_iff_map_fun_eq_infinitePi_map₀ [IsProbabilityMeasure P]
66+
(mX : AEMeasurable (fun ω i ↦ X i ω) P) :
4467
iIndepFun X P ↔ P.map (fun ω i ↦ X i ω) = infinitePi (fun i ↦ P.map (X i)) where
45-
mp h := by
46-
have _ i := isProbabilityMeasure_map (mX.eval i)
47-
refine eq_infinitePi _ fun s t ht ↦ ?_
48-
rw [iIndepFun_iff_finset] at h
49-
have : (s : Set ι).pi t = s.restrict ⁻¹' (Set.univ.pi fun i ↦ t i) := by ext; simp
50-
rw [this, ← map_apply, AEMeasurable.map_map_of_aemeasurable]
51-
· have : s.restrict ∘ (fun ω i ↦ X i ω) = fun ω i ↦ s.restrict X i ω := by ext; simp
52-
rw [this, (iIndepFun_iff_map_fun_eq_pi_map ?_).1 (h s), pi_pi]
53-
· simp only [Finset.restrict]
54-
rw [s.prod_coe_sort fun i ↦ P.map (X i) (t i)]
55-
exact fun i ↦ mX.eval i
56-
any_goals fun_prop
57-
· exact mX
58-
· exact .univ_pi fun i ↦ ht i
68+
mp h := h.map_fun_eq_infinitePi_map₀ mX
5969
mpr h := by
6070
have _ i := isProbabilityMeasure_map (mX.eval i)
6171
rw [iIndepFun_iff_finset]
@@ -68,19 +78,33 @@ lemma iIndepFun_iff_map_fun_eq_infinitePi_map₀ (mX : AEMeasurable (fun ω i
6878
exact mX
6979
exact fun i ↦ mX.eval i
7080

81+
/-- If random variables are independent then their joint distribution is the product measure. This
82+
is an `AEMeasurable` version of `iIndepFun.map_fun_eq_infinitePi_map`, which is why it requires
83+
`ι` to be countable. -/
84+
lemma iIndepFun.map_fun_eq_infinitePi_map₀' [Countable ι] (mX : ∀ i, AEMeasurable (X i) P)
85+
(h : iIndepFun X P) :
86+
P.map (fun ω i ↦ X i ω) = infinitePi (fun i ↦ P.map (X i)) :=
87+
h.map_fun_eq_infinitePi_map₀ <| aemeasurable_pi_iff.2 mX
88+
7189
/-- Random variables are independent iff their joint distribution is the product measure. This is
7290
an `AEMeasurable` version of `iIndepFun_iff_map_fun_eq_infinitePi_map`, which is why it requires
7391
`ι` to be countable. -/
74-
lemma iIndepFun_iff_map_fun_eq_infinitePi_map₀' [Countable ι] (mX : ∀ i, AEMeasurable (X i) P) :
92+
lemma iIndepFun_iff_map_fun_eq_infinitePi_map₀' [IsProbabilityMeasure P] [Countable ι]
93+
(mX : ∀ i, AEMeasurable (X i) P) :
7594
iIndepFun X P ↔ P.map (fun ω i ↦ X i ω) = infinitePi (fun i ↦ P.map (X i)) :=
7695
iIndepFun_iff_map_fun_eq_infinitePi_map₀ <| aemeasurable_pi_iff.2 mX
7796

97+
/-- If random variables are independent then their joint distribution is the product measure. -/
98+
lemma iIndepFun.map_fun_eq_infinitePi_map (mX : ∀ i, Measurable (X i)) (h : iIndepFun X P) :
99+
P.map (fun ω i ↦ X i ω) = infinitePi (fun i ↦ P.map (X i)) :=
100+
h.map_fun_eq_infinitePi_map₀ <| measurable_pi_iff.2 mX |>.aemeasurable
101+
78102
/-- Random variables are independent iff their joint distribution is the product measure. -/
79-
lemma iIndepFun_iff_map_fun_eq_infinitePi_map (mX : ∀ i, Measurable (X i)) :
103+
lemma iIndepFun_iff_map_fun_eq_infinitePi_map [IsProbabilityMeasure P]
104+
(mX : ∀ i, Measurable (X i)) :
80105
iIndepFun X P ↔ P.map (fun ω i ↦ X i ω) = infinitePi (fun i ↦ P.map (X i)) :=
81106
iIndepFun_iff_map_fun_eq_infinitePi_map₀ <| measurable_pi_iff.2 mX |>.aemeasurable
82107

83-
omit [IsProbabilityMeasure P] in
84108
lemma iIndepFun.hasLaw_infinitePi {μ : (i : ι) → Measure (𝓧 i)} (hX : ∀ i, HasLaw (X i) (μ i) P)
85109
(h1 : iIndepFun X P) (h2 : AEMeasurable (fun ω i ↦ X i ω) P) :
86110
HasLaw (fun ω i ↦ X i ω) (infinitePi μ) P where
@@ -90,7 +114,7 @@ lemma iIndepFun.hasLaw_infinitePi {μ : (i : ι) → Measure (𝓧 i)} (hX : ∀
90114
rw [(iIndepFun_iff_map_fun_eq_infinitePi_map₀ h2).1 h1]
91115
simp_rw [fun i ↦ (hX i).map_eq]
92116

93-
lemma iIndepFun_iff_hasLaw_Pi_infinitePi {μ : (i : ι) → Measure (𝓧 i)}
117+
lemma iIndepFun_iff_hasLaw_Pi_infinitePi [IsProbabilityMeasure P] {μ : (i : ι) → Measure (𝓧 i)}
94118
(hX : ∀ i, HasLaw (X i) (μ i) P) (hm : AEMeasurable (fun ω i ↦ X i ω) P) :
95119
iIndepFun X P ↔ HasLaw (fun ω i ↦ X i ω) (infinitePi μ) P where
96120
mp h := h.hasLaw_infinitePi hX hm
@@ -118,8 +142,6 @@ lemma _root_.MeasureTheory.Measure.map_infinitePi_infinitePi_of_inj {α : Type*}
118142

119143
section curry
120144

121-
omit [IsProbabilityMeasure P]
122-
123145
section dependent
124146

125147
variable {κ : ι → Type*} {𝓧 : (i : ι) → κ i → Type*} {m𝓧 : ∀ i j, MeasurableSpace (𝓧 i j)}

Mathlib/Probability/Independence/Integration.lean

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -258,9 +258,9 @@ theorem IndepFun.integral_bilin_comp_comp
258258
(hf.comp_aemeasurable hX).isProbabilityMeasure_of_indepFun (f ∘ X) (g ∘ Y) h
259259
(hXY.comp₀ hX hY hf.1.aemeasurable hg.1.aemeasurable)
260260
rw [← integral_map (f := fun z ↦ B (f z.1) (g z.2)) (φ := fun ω ↦ (X ω, Y ω)) (by fun_prop),
261-
(indepFun_iff_map_prod_eq_prod_map_map hX hY).1 hXY,
262-
integral_prod_bilin _ hf hg, integral_map hX hf.1, integral_map hY hg.1]
263-
rw [(indepFun_iff_map_prod_eq_prod_map_map hX hY).1 hXY]
261+
hXY.map_prod_eq_prod_map_map hX hY, integral_prod_bilin _ hf hg, integral_map hX hf.1,
262+
integral_map hY hg.1]
263+
rw [hXY.map_prod_eq_prod_map_map hX hY]
264264
exact Continuous.comp_aestronglyMeasurable₂ (g := (B · ·)) (by fun_prop)
265265
hf.1.comp_fst hg.1.comp_snd
266266

@@ -457,11 +457,11 @@ lemma iIndepFun.integral_fun_prod_comp (hX : iIndepFun X μ)
457457
have := hX.isProbabilityMeasure
458458
change ∫ ω, (fun x ↦ ∏ i, f i (x i)) (X · ω) ∂μ = _
459459
rw [← integral_map (f := fun x ↦ ∏ i, f i (x i)) (φ := fun ω ↦ (X · ω)),
460-
(iIndepFun_iff_map_fun_eq_pi_map mX).1 hX, integral_fintype_prod_eq_prod]
460+
hX.map_fun_eq_pi_map mX, integral_fintype_prod_eq_prod]
461461
· congr with i
462462
rw [integral_map (mX i) (hf i)]
463463
· fun_prop
464-
rw [(iIndepFun_iff_map_fun_eq_pi_map mX).1 hX]
464+
rw [hX.map_fun_eq_pi_map mX]
465465
exact Finset.aestronglyMeasurable_fun_prod Finset.univ fun i _ ↦
466466
(hf i).comp_quasiMeasurePreserving (Measure.quasiMeasurePreserving_eval _ i)
467467

0 commit comments

Comments
 (0)