Skip to content

Commit 279879e

Browse files
committed
refactor(MeasureTheory/Integral/MeanValue): enhance documentation; golf
1 parent 0fd5c83 commit 279879e

1 file changed

Lines changed: 4 additions & 6 deletions

File tree

Mathlib/MeasureTheory/Integral/MeanValue.lean

Lines changed: 4 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -14,9 +14,9 @@ We prove versions of the first mean value theorem for set integrals.
1414
1515
## Main results
1616
17-
* `exists_eq_const_mul_setIntegral_of_ae_nonneg`:
17+
* `exists_eq_const_mul_setIntegral_of_ae_nonneg` (a.e. nonnegativity of `g` on `s`):
1818
`∃ c ∈ s, (∫ x in s, f x * g x ∂μ) = f c * (∫ x in s, g x ∂μ)`.
19-
* `exists_eq_const_mul_setIntegral_of_nonneg`:
19+
* `exists_eq_const_mul_setIntegral_of_nonneg` (pointwise nonnegativity of `g` on `s`):
2020
`∃ c ∈ s, (∫ x in s, f x * g x ∂μ) = f c * (∫ x in s, g x ∂μ)`.
2121
2222
## Tags
@@ -90,14 +90,12 @@ theorem exists_eq_const_mul_setIntegral_of_ae_nonneg
9090
intro x hx
9191
simp [hx, mul_comm]
9292
have h_IntOn : IntegrableOn (fun x ↦ (ρ x).toReal * f x) s μ := by
93-
rw [integrableOn_congr_fun_ae hmul_ae]
94-
exact hfg
93+
rwa [integrableOn_congr_fun_ae hmul_ae]
9594
have h_Int : Integrable f ((μ.restrict s).withDensity ρ) := by
9695
rwa [integrable_withDensity_iff_integrable_smul₀' hρ_ae hρ_top, ← IntegrableOn]
9796
have hνrs : ν.restrict s = (μ.restrict s).withDensity ρ := by
9897
ext t ht
99-
have hts : MeasurableSet (t ∩ s) := ht.inter hs_meas
100-
simp [ν, withDensity_apply, Measure.restrict_apply, ht, hs_meas]
98+
simp [ht, ν, hs_meas]
10199
simpa [IntegrableOn, hνrs] using h_Int
102100
obtain ⟨c, hc, h_ave⟩ := exists_eq_setAverage hs_conn hf hint hνfin hν0''
103101
refine ⟨c, hc, ?_⟩

0 commit comments

Comments
 (0)