|
1 | 1 | /- |
2 | 2 | Copyright (c) 2022 Yury Kudryashov. All rights reserved. |
3 | 3 | Released under Apache 2.0 license as described in the file LICENSE. |
4 | | -Authors: Yury Kudryashov, Yaël Dillies |
| 4 | +Authors: Yury Kudryashov, Yaël Dillies, Louis (Yiyang) Liu |
5 | 5 | -/ |
6 | 6 | module |
7 | 7 |
|
@@ -33,7 +33,7 @@ function, we provide a convenience lemma `MeasureTheory.Integrable.to_average`. |
33 | 33 |
|
34 | 34 | ## Tags |
35 | 35 |
|
36 | | -integral, center mass, average value |
| 36 | +integral, center mass, average value, set average |
37 | 37 | -/ |
38 | 38 |
|
39 | 39 | @[expose] public section |
@@ -797,4 +797,20 @@ theorem tendsto_integral_smul_of_tendsto_average_norm_sub |
797 | 797 | simp only [one_smul, zero_add] at this |
798 | 798 | exact Tendsto.congr' I this |
799 | 799 |
|
| 800 | +/-- If `s` is a connected set of finite, nonzero `μ`-measure and `f : α → ℝ` is continuous on `s` |
| 801 | +and integrable on `s` w.r.t. `μ`, then `f` attains its `μ`-average on `s`. -/ |
| 802 | +theorem exists_eq_setAverage |
| 803 | + [TopologicalSpace α] {f : α → ℝ} (hs : IsConnected s) (hf : ContinuousOn f s) |
| 804 | + (hint : IntegrableOn f s μ) (hμfin : μ s ≠ ⊤) (hμ0 : μ s ≠ 0) : |
| 805 | + ∃ c ∈ s, f c = ⨍ x in s, f x ∂μ := by |
| 806 | + let ave := ⨍ x in s, f x ∂μ |
| 807 | + let S₁ : Set α := {x | x ∈ s ∧ f x ≤ ave} |
| 808 | + let S₂ : Set α := {x | x ∈ s ∧ ave ≤ f x} |
| 809 | + have hS₁ : 0 < μ S₁ := measure_le_setAverage_pos hμ0 hμfin hint |
| 810 | + have hS₂ : 0 < μ S₂ := measure_setAverage_le_pos hμ0 hμfin hint |
| 811 | + rcases nonempty_of_measure_ne_zero hS₁.ne' with ⟨c₁, hc₁⟩ |
| 812 | + rcases nonempty_of_measure_ne_zero hS₂.ne' with ⟨c₂, hc₂⟩ |
| 813 | + apply hs.isPreconnected.intermediate_value hc₁.1 hc₂.1 hf |
| 814 | + grind |
| 815 | + |
800 | 816 | end MeasureTheory |
0 commit comments