Skip to content

Commit c4e2435

Browse files
committed
refactor(EMetricSpace): rename EMetric.ball -> Metric.eball (#34379)
Also rename `EMetric.closedBall` -> `Metric.closedEBall` and most (all?) of the related lemmas.
1 parent c3cf7cb commit c4e2435

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

52 files changed

+876
-597
lines changed

Mathlib/Analysis/Analytic/Basic.lean

Lines changed: 60 additions & 60 deletions
Large diffs are not rendered by default.

Mathlib/Analysis/Analytic/Binomial.lean

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -108,7 +108,7 @@ theorem one_add_cpow_hasFPowerSeriesOnBall_zero {a : ℂ} :
108108
apply AnalyticOn.cpow (analyticOn_const.add analyticOn_id) analyticOn_const
109109
intro z hz
110110
apply Complex.mem_slitPlane_of_norm_lt_one
111-
rw [← ENNReal.ofReal_one, Metric.emetric_ball] at hz
111+
rw [← ENNReal.ofReal_one, Metric.eball_ofReal] at hz
112112
simpa using hz
113113
· rw [← this]
114114
exact binomialSeries_radius_ge_one

Mathlib/Analysis/Analytic/CPolynomial.lean

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -120,7 +120,7 @@ protected theorem hasFiniteFPowerSeriesOnBall :
120120

121121
lemma cpolynomialAt : CPolynomialAt 𝕜 f x :=
122122
f.hasFiniteFPowerSeriesOnBall.cpolynomialAt_of_mem
123-
(by simp only [Metric.emetric_ball_top, Set.mem_univ])
123+
(by simp only [Metric.eball_top, Set.mem_univ])
124124

125125
lemma cpolynomialOn : CPolynomialOn 𝕜 f s := fun _ _ ↦ f.cpolynomialAt
126126

@@ -170,7 +170,7 @@ protected theorem hasFiniteFPowerSeriesOnBall_uncurry_of_multilinear :
170170
lemma cpolynomialAt_uncurry_of_multilinear :
171171
CPolynomialAt 𝕜 (fun (p : G × (Π i, Em i)) ↦ f p.1 p.2) x :=
172172
f.hasFiniteFPowerSeriesOnBall_uncurry_of_multilinear.cpolynomialAt_of_mem
173-
(by simp only [Metric.emetric_ball_top, Set.mem_univ])
173+
(by simp only [Metric.eball_top, Set.mem_univ])
174174

175175
lemma cpolynomialOn_uncurry_of_multilinear :
176176
CPolynomialOn 𝕜 (fun (p : G × (Π i, Em i)) ↦ f p.1 p.2) s :=

Mathlib/Analysis/Analytic/CPolynomialDef.lean

Lines changed: 23 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -65,7 +65,7 @@ structure HasFiniteFPowerSeriesOnBall (f : E → F) (p : FormalMultilinearSeries
6565

6666
theorem HasFiniteFPowerSeriesOnBall.mk' {f : E → F} {p : FormalMultilinearSeries 𝕜 E F} {x : E}
6767
{n : ℕ} {r : ℝ≥0∞} (finite : ∀ (m : ℕ), n ≤ m → p m = 0) (pos : 0 < r)
68-
(sum_eq : ∀ y ∈ EMetric.ball 0 r, (∑ i ∈ Finset.range n, p i fun _ ↦ y) = f (x + y)) :
68+
(sum_eq : ∀ y ∈ Metric.eball 0 r, (∑ i ∈ Finset.range n, p i fun _ ↦ y) = f (x + y)) :
6969
HasFiniteFPowerSeriesOnBall f p x n r where
7070
r_le := p.radius_eq_top_of_eventually_eq_zero (Filter.eventually_atTop.mpr ⟨n, finite⟩) ▸ le_top
7171
r_pos := pos
@@ -129,7 +129,7 @@ theorem CPolynomialOn.analyticOn {s : Set E} (hf : CPolynomialOn 𝕜 f s) : Ana
129129
hf.analyticOnNhd.analyticOn
130130

131131
theorem HasFiniteFPowerSeriesOnBall.congr (hf : HasFiniteFPowerSeriesOnBall f p x n r)
132-
(hg : EqOn f g (EMetric.ball x r)) : HasFiniteFPowerSeriesOnBall g p x n r :=
132+
(hg : EqOn f g (Metric.eball x r)) : HasFiniteFPowerSeriesOnBall g p x n r :=
133133
⟨hf.1.congr hg, hf.finite⟩
134134

135135
theorem HasFiniteFPowerSeriesOnBall.of_le {m n : ℕ}
@@ -210,7 +210,7 @@ theorem ContinuousLinearMap.comp_cpolynomialOn {s : Set E} (g : F →L[𝕜] G)
210210
the `m`th partial sums of this power series at every point of the disk for `n ≤ m`. -/
211211
theorem HasFiniteFPowerSeriesOnBall.eq_partialSum
212212
(hf : HasFiniteFPowerSeriesOnBall f p x n r) :
213-
∀ y ∈ EMetric.ball (0 : E) r, ∀ m, n ≤ m →
213+
∀ y ∈ Metric.eball (0 : E) r, ∀ m, n ≤ m →
214214
f (x + y) = p.partialSum m y :=
215215
fun y hy m hm ↦ (hf.hasSum hy).unique (hasSum_sum_of_ne_finset_zero
216216
(f := fun m => p m (fun _ => y)) (s := Finset.range m)
@@ -220,23 +220,23 @@ theorem HasFiniteFPowerSeriesOnBall.eq_partialSum
220220
/-- Variant of the previous result with the variable expressed as `y` instead of `x + y`. -/
221221
theorem HasFiniteFPowerSeriesOnBall.eq_partialSum'
222222
(hf : HasFiniteFPowerSeriesOnBall f p x n r) :
223-
∀ y ∈ EMetric.ball x r, ∀ m, n ≤ m →
223+
∀ y ∈ Metric.eball x r, ∀ m, n ≤ m →
224224
f y = p.partialSum m (y - x) := by
225225
intro y hy m hm
226-
rw [EMetric.mem_ball, edist_eq_enorm_sub, ← mem_emetric_ball_zero_iff] at hy
226+
rw [Metric.mem_eball, edist_eq_enorm_sub, ← mem_eball_zero_iff] at hy
227227
rw [← (HasFiniteFPowerSeriesOnBall.eq_partialSum hf _ hy m hm), add_sub_cancel]
228228

229229
/-! The particular cases where `f` has a finite power series bounded by `0` or `1`. -/
230230

231231
/-- If `f` has a formal power series on a ball bounded by `0`, then `f` is equal to `0` on
232232
the ball. -/
233233
theorem HasFiniteFPowerSeriesOnBall.eq_zero_of_bound_zero
234-
(hf : HasFiniteFPowerSeriesOnBall f pf x 0 r) : ∀ y ∈ EMetric.ball x r, f y = 0 := by
234+
(hf : HasFiniteFPowerSeriesOnBall f pf x 0 r) : ∀ y ∈ Metric.eball x r, f y = 0 := by
235235
intro y hy
236236
rw [hf.eq_partialSum' y hy 0 le_rfl, FormalMultilinearSeries.partialSum]
237237
simp only [Finset.range_zero, Finset.sum_empty]
238238

239-
theorem HasFiniteFPowerSeriesOnBall.bound_zero_of_eq_zero (hf : ∀ y ∈ EMetric.ball x r, f y = 0)
239+
theorem HasFiniteFPowerSeriesOnBall.bound_zero_of_eq_zero (hf : ∀ y ∈ Metric.eball x r, f y = 0)
240240
(r_pos : 0 < r) (hp : ∀ n, p n = 0) : HasFiniteFPowerSeriesOnBall f p x 0 r := by
241241
refine ⟨⟨?_, r_pos, ?_⟩, fun n _ ↦ hp n⟩
242242
· rw [p.radius_eq_top_of_forall_image_add_eq_zero 0 (fun n ↦ by rw [add_zero]; exact hp n)]
@@ -245,23 +245,23 @@ theorem HasFiniteFPowerSeriesOnBall.bound_zero_of_eq_zero (hf : ∀ y ∈ EMetri
245245
rw [hf (x + y)]
246246
· convert hasSum_zero
247247
rw [hp, ContinuousMultilinearMap.zero_apply]
248-
· rwa [EMetric.mem_ball, edist_eq_enorm_sub, add_comm, add_sub_cancel_right,
249-
← edist_zero_eq_enorm, ← EMetric.mem_ball]
248+
· rwa [Metric.mem_eball, edist_eq_enorm_sub, add_comm, add_sub_cancel_right,
249+
← edist_zero_eq_enorm, ← Metric.mem_eball]
250250

251251
/-- If `f` has a formal power series at `x` bounded by `0`, then `f` is equal to `0` in a
252252
neighborhood of `x`. -/
253253
theorem HasFiniteFPowerSeriesAt.eventually_zero_of_bound_zero
254254
(hf : HasFiniteFPowerSeriesAt f pf x 0) : f =ᶠ[𝓝 x] 0 :=
255-
Filter.eventuallyEq_iff_exists_mem.mpr (let ⟨r, hf⟩ := hf; ⟨EMetric.ball x r,
256-
EMetric.ball_mem_nhds x hf.r_pos, fun y hy ↦ hf.eq_zero_of_bound_zero y hy⟩)
255+
Filter.eventuallyEq_iff_exists_mem.mpr (let ⟨r, hf⟩ := hf; ⟨Metric.eball x r,
256+
Metric.eball_mem_nhds x hf.r_pos, fun y hy ↦ hf.eq_zero_of_bound_zero y hy⟩)
257257

258258
/-- If `f` has a formal power series on a ball bounded by `1`, then `f` is constant equal
259259
to `f x` on the ball. -/
260260
theorem HasFiniteFPowerSeriesOnBall.eq_const_of_bound_one
261-
(hf : HasFiniteFPowerSeriesOnBall f pf x 1 r) : ∀ y ∈ EMetric.ball x r, f y = f x := by
261+
(hf : HasFiniteFPowerSeriesOnBall f pf x 1 r) : ∀ y ∈ Metric.eball x r, f y = f x := by
262262
intro y hy
263263
rw [hf.eq_partialSum' y hy 1 le_rfl, hf.eq_partialSum' x
264-
(by rw [EMetric.mem_ball, edist_self]; exact hf.r_pos) 1 le_rfl]
264+
(by rw [Metric.mem_eball, edist_self]; exact hf.r_pos) 1 le_rfl]
265265
simp only [FormalMultilinearSeries.partialSum, Finset.range_one, Finset.sum_singleton]
266266
congr
267267
apply funext
@@ -271,13 +271,13 @@ theorem HasFiniteFPowerSeriesOnBall.eq_const_of_bound_one
271271
to `f x` in a neighborhood of `x`. -/
272272
theorem HasFiniteFPowerSeriesAt.eventually_const_of_bound_one
273273
(hf : HasFiniteFPowerSeriesAt f pf x 1) : f =ᶠ[𝓝 x] (fun _ => f x) :=
274-
Filter.eventuallyEq_iff_exists_mem.mpr (let ⟨r, hf⟩ := hf; ⟨EMetric.ball x r,
275-
EMetric.ball_mem_nhds x hf.r_pos, fun y hy ↦ hf.eq_const_of_bound_one y hy⟩)
274+
Filter.eventuallyEq_iff_exists_mem.mpr (let ⟨r, hf⟩ := hf; ⟨Metric.eball x r,
275+
Metric.eball_mem_nhds x hf.r_pos, fun y hy ↦ hf.eq_const_of_bound_one y hy⟩)
276276

277277
/-- If a function admits a finite power series expansion on a disk, then it is continuous there. -/
278278
protected theorem HasFiniteFPowerSeriesOnBall.continuousOn
279279
(hf : HasFiniteFPowerSeriesOnBall f p x n r) :
280-
ContinuousOn f (EMetric.ball x r) := hf.1.continuousOn
280+
ContinuousOn f (Metric.eball x r) := hf.1.continuousOn
281281

282282
protected theorem HasFiniteFPowerSeriesAt.continuousAt (hf : HasFiniteFPowerSeriesAt f p x n) :
283283
ContinuousAt f x := hf.hasFPowerSeriesAt.continuousAt
@@ -316,14 +316,14 @@ protected theorem FormalMultilinearSeries.hasFiniteFPowerSeriesOnBall_of_finite
316316
hasSum {y} _ := by rw [zero_add]; exact p.hasSum_of_finite hn y
317317

318318
theorem HasFiniteFPowerSeriesOnBall.sum (h : HasFiniteFPowerSeriesOnBall f p x n r) {y : E}
319-
(hy : y ∈ EMetric.ball (0 : E) r) : f (x + y) = p.sum y :=
319+
(hy : y ∈ Metric.eball (0 : E) r) : f (x + y) = p.sum y :=
320320
(h.hasSum hy).tsum_eq.symm
321321

322322
/-- The sum of a finite power series is continuous. -/
323323
protected theorem FormalMultilinearSeries.continuousOn_of_finite
324324
(p : FormalMultilinearSeries 𝕜 E F) {n : ℕ} (hn : ∀ m, n ≤ m → p m = 0) :
325325
Continuous p.sum := by
326-
rw [← continuousOn_univ, ← Metric.emetric_ball_top]
326+
rw [← continuousOn_univ, ← Metric.eball_top]
327327
exact (p.hasFiniteFPowerSeriesOnBall_of_finite hn).continuousOn
328328

329329
end FiniteFPowerSeries
@@ -443,24 +443,24 @@ theorem HasFiniteFPowerSeriesOnBall.changeOrigin (hf : HasFiniteFPowerSeriesOnBa
443443
hasSum {z} hz := by
444444
have : f (x + y + z) =
445445
FormalMultilinearSeries.sum (FormalMultilinearSeries.changeOrigin p y) z := by
446-
rw [mem_emetric_ball_zero_iff, lt_tsub_iff_right, add_comm] at hz
446+
rw [mem_eball_zero_iff, lt_tsub_iff_right, add_comm] at hz
447447
rw [p.changeOrigin_eval_of_finite hf.finite, add_assoc, hf.sum]
448-
exact mem_emetric_ball_zero_iff.2 ((enorm_add_le _ _).trans_lt hz)
448+
exact mem_eball_zero_iff.2 ((enorm_add_le _ _).trans_lt hz)
449449
rw [this]
450450
apply (p.changeOrigin y).hasSum_of_finite fun _ => p.changeOrigin_finite_of_finite hf.finite
451451

452452
/-- If a function admits a finite power series expansion `p` on an open ball `B (x, r)`, then
453453
it is continuously polynomial at every point of this ball. -/
454454
theorem HasFiniteFPowerSeriesOnBall.cpolynomialAt_of_mem
455-
(hf : HasFiniteFPowerSeriesOnBall f p x n r) (h : y ∈ EMetric.ball x r) :
455+
(hf : HasFiniteFPowerSeriesOnBall f p x n r) (h : y ∈ Metric.eball x r) :
456456
CPolynomialAt 𝕜 f y := by
457457
have : (‖y - x‖₊ : ℝ≥0∞) < r := by simpa [edist_eq_enorm_sub] using h
458458
have := hf.changeOrigin this
459459
rw [add_sub_cancel] at this
460460
exact this.cpolynomialAt
461461

462462
theorem HasFiniteFPowerSeriesOnBall.cpolynomialOn (hf : HasFiniteFPowerSeriesOnBall f p x n r) :
463-
CPolynomialOn 𝕜 f (EMetric.ball x r) :=
463+
CPolynomialOn 𝕜 f (Metric.eball x r) :=
464464
fun _y hy => hf.cpolynomialAt_of_mem hy
465465

466466
variable (𝕜 f)
@@ -470,7 +470,7 @@ variable (𝕜 f)
470470
theorem isOpen_cpolynomialAt : IsOpen { x | CPolynomialAt 𝕜 f x } := by
471471
rw [isOpen_iff_mem_nhds]
472472
rintro x ⟨p, n, r, hr⟩
473-
exact mem_of_superset (EMetric.ball_mem_nhds _ hr.r_pos) fun y hy => hr.cpolynomialAt_of_mem hy
473+
exact mem_of_superset (Metric.eball_mem_nhds _ hr.r_pos) fun y hy => hr.cpolynomialAt_of_mem hy
474474

475475
variable {𝕜}
476476

Mathlib/Analysis/Analytic/ChangeOrigin.lean

Lines changed: 16 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -256,13 +256,13 @@ theorem hasFPowerSeriesOnBall_changeOrigin (k : ℕ) (hr : 0 < p.radius) :
256256
theorem changeOrigin_eval (h : (‖x‖₊ + ‖y‖₊ : ℝ≥0∞) < p.radius) :
257257
(p.changeOrigin x).sum y = p.sum (x + y) := by
258258
have radius_pos : 0 < p.radius := lt_of_le_of_lt (zero_le _) h
259-
have x_mem_ball : x ∈ EMetric.ball (0 : E) p.radius :=
260-
mem_emetric_ball_zero_iff.2 ((le_add_right le_rfl).trans_lt h)
261-
have y_mem_ball : y ∈ EMetric.ball (0 : E) (p.changeOrigin x).radius := by
262-
refine mem_emetric_ball_zero_iff.2 (lt_of_lt_of_le ?_ p.changeOrigin_radius)
259+
have x_mem_ball : x ∈ Metric.eball (0 : E) p.radius :=
260+
mem_eball_zero_iff.2 ((le_add_right le_rfl).trans_lt h)
261+
have y_mem_ball : y ∈ Metric.eball (0 : E) (p.changeOrigin x).radius := by
262+
refine mem_eball_zero_iff.2 (lt_of_lt_of_le ?_ p.changeOrigin_radius)
263263
rwa [lt_tsub_iff_right, add_comm]
264-
have x_add_y_mem_ball : x + y ∈ EMetric.ball (0 : E) p.radius := by
265-
refine mem_emetric_ball_zero_iff.2 (lt_of_le_of_lt ?_ h)
264+
have x_add_y_mem_ball : x + y ∈ Metric.eball (0 : E) p.radius := by
265+
refine mem_eball_zero_iff.2 (lt_of_le_of_lt ?_ h)
266266
exact mod_cast nnnorm_add_le x y
267267
set f : (Σ k l : ℕ, { s : Finset (Fin (k + l)) // s.card = l }) → F := fun s =>
268268
p.changeOriginSeriesTerm s.1 s.2.1 s.2.2 s.2.2.2 (fun _ => x) fun _ => y
@@ -281,7 +281,7 @@ theorem changeOrigin_eval (h : (‖x‖₊ + ‖y‖₊ : ℝ≥0∞) < p.radius
281281
· simp only [changeOriginSeries, ContinuousMultilinearMap.sum_apply]
282282
apply hasSum_fintype
283283
· refine .of_nnnorm_bounded
284-
(p.changeOriginSeries_summable_aux₂ (mem_emetric_ball_zero_iff.1 x_mem_ball) k)
284+
(p.changeOriginSeries_summable_aux₂ (mem_eball_zero_iff.1 x_mem_ball) k)
285285
fun s => ?_
286286
refine (ContinuousMultilinearMap.le_opNNNorm _ _).trans_eq ?_
287287
simp
@@ -318,17 +318,17 @@ theorem HasFPowerSeriesWithinOnBall.changeOrigin (hf : HasFPowerSeriesWithinOnBa
318318
hasSum {z} h'z hz := by
319319
have : f (x + y + z) =
320320
FormalMultilinearSeries.sum (FormalMultilinearSeries.changeOrigin p y) z := by
321-
rw [mem_emetric_ball_zero_iff, lt_tsub_iff_right, add_comm] at hz
321+
rw [mem_eball_zero_iff, lt_tsub_iff_right, add_comm] at hz
322322
rw [p.changeOrigin_eval (hz.trans_le hf.r_le), add_assoc, hf.sum]
323323
· have : insert (x + y) s ⊆ insert (x + y) (insert x s) := by
324324
apply insert_subset_insert (subset_insert _ _)
325325
rw [insert_eq_of_mem hy] at this
326326
apply this
327327
simpa [add_assoc] using h'z
328-
exact mem_emetric_ball_zero_iff.2 (lt_of_le_of_lt (enorm_add_le _ _) hz)
328+
exact mem_eball_zero_iff.2 (lt_of_le_of_lt (enorm_add_le _ _) hz)
329329
rw [this]
330330
apply (p.changeOrigin y).hasSum
331-
refine EMetric.ball_subset_ball (le_trans ?_ p.changeOrigin_radius) hz
331+
refine Metric.eball_subset_eball (le_trans ?_ p.changeOrigin_radius) hz
332332
exact tsub_le_tsub hf.r_le le_rfl
333333

334334
/-- If a function admits a power series expansion `p` on a ball `B (x, r)`, then it also admits a
@@ -343,7 +343,7 @@ theorem HasFPowerSeriesOnBall.changeOrigin (hf : HasFPowerSeriesOnBall f p x r)
343343
it is analytic at every point of this ball. -/
344344
theorem HasFPowerSeriesWithinOnBall.analyticWithinAt_of_mem
345345
(hf : HasFPowerSeriesWithinOnBall f p s x r)
346-
(h : y ∈ insert x s ∩ EMetric.ball x r) : AnalyticWithinAt 𝕜 f s y := by
346+
(h : y ∈ insert x s ∩ Metric.eball x r) : AnalyticWithinAt 𝕜 f s y := by
347347
have : (‖y - x‖₊ : ℝ≥0∞) < r := by simpa [edist_eq_enorm_sub] using h.2
348348
have := hf.changeOrigin this (by simpa using h.1)
349349
rw [add_sub_cancel] at this
@@ -352,18 +352,18 @@ theorem HasFPowerSeriesWithinOnBall.analyticWithinAt_of_mem
352352
/-- If a function admits a power series expansion `p` on an open ball `B (x, r)`, then
353353
it is analytic at every point of this ball. -/
354354
theorem HasFPowerSeriesOnBall.analyticAt_of_mem (hf : HasFPowerSeriesOnBall f p x r)
355-
(h : y ∈ EMetric.ball x r) : AnalyticAt 𝕜 f y := by
355+
(h : y ∈ Metric.eball x r) : AnalyticAt 𝕜 f y := by
356356
rw [← hasFPowerSeriesWithinOnBall_univ] at hf
357357
rw [← analyticWithinAt_univ]
358358
exact hf.analyticWithinAt_of_mem (by simpa using h)
359359

360360
theorem HasFPowerSeriesWithinOnBall.analyticOn (hf : HasFPowerSeriesWithinOnBall f p s x r) :
361-
AnalyticOn 𝕜 f (insert x s ∩ EMetric.ball x r) :=
361+
AnalyticOn 𝕜 f (insert x s ∩ Metric.eball x r) :=
362362
fun _ hy ↦ ((analyticWithinAt_insert (y := x)).2 (hf.analyticWithinAt_of_mem hy)).mono
363363
inter_subset_left
364364

365365
theorem HasFPowerSeriesOnBall.analyticOnNhd (hf : HasFPowerSeriesOnBall f p x r) :
366-
AnalyticOnNhd 𝕜 f (EMetric.ball x r) :=
366+
AnalyticOnNhd 𝕜 f (Metric.eball x r) :=
367367
fun _y hy => hf.analyticAt_of_mem hy
368368

369369
variable (𝕜 f) in
@@ -372,7 +372,7 @@ that `f` is analytic at `x` is open. -/
372372
theorem isOpen_analyticAt : IsOpen { x | AnalyticAt 𝕜 f x } := by
373373
rw [isOpen_iff_mem_nhds]
374374
rintro x ⟨p, r, hr⟩
375-
exact mem_of_superset (EMetric.ball_mem_nhds _ hr.r_pos) fun y hy => hr.analyticAt_of_mem hy
375+
exact mem_of_superset (Metric.eball_mem_nhds _ hr.r_pos) fun y hy => hr.analyticAt_of_mem hy
376376

377377
theorem AnalyticAt.eventually_analyticAt (h : AnalyticAt 𝕜 f x) :
378378
∀ᶠ y in 𝓝 x, AnalyticAt 𝕜 f y :=
@@ -389,7 +389,7 @@ theorem AnalyticAt.exists_ball_analyticOnNhd (h : AnalyticAt 𝕜 f x) :
389389

390390
/-- Sum of series is analytic on its ball of convergence. -/
391391
protected theorem FormalMultilinearSeries.analyticOnNhd :
392-
AnalyticOnNhd 𝕜 p.sum (EMetric.ball 0 p.radius) := by
392+
AnalyticOnNhd 𝕜 p.sum (Metric.eball 0 p.radius) := by
393393
by_cases hr : p.radius = 0
394394
· simp [hr]
395395
exact (FormalMultilinearSeries.hasFPowerSeriesOnBall _ (pos_of_ne_zero hr)).analyticOnNhd

Mathlib/Analysis/Analytic/Composition.lean

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -706,11 +706,11 @@ theorem HasFPowerSeriesWithinAt.comp {g : F → G} {f : E → F} {q : FormalMult
706706
`f (x + y)` is close enough to `f x` to be in the disk where `g` is well behaved. Let
707707
`min (r, rf, δ)` be this new radius. -/
708708
obtain ⟨δ, δpos, hδ⟩ :
709-
∃ δ : ℝ≥0∞, 0 < δ ∧ ∀ {z : E}, z ∈ insert x s ∩ EMetric.ball x δ
710-
→ f z ∈ insert (f x) t ∩ EMetric.ball (f x) rg := by
711-
have : insert (f x) t ∩ EMetric.ball (f x) rg ∈ 𝓝[insert (f x) t] (f x) := by
709+
∃ δ : ℝ≥0∞, 0 < δ ∧ ∀ {z : E}, z ∈ insert x s ∩ Metric.eball x δ
710+
→ f z ∈ insert (f x) t ∩ Metric.eball (f x) rg := by
711+
have : insert (f x) t ∩ Metric.eball (f x) rg ∈ 𝓝[insert (f x) t] (f x) := by
712712
apply inter_mem_nhdsWithin
713-
exact EMetric.ball_mem_nhds _ Hg.r_pos
713+
exact Metric.eball_mem_nhds _ Hg.r_pos
714714
have := Hf.analyticWithinAt.continuousWithinAt_insert.tendsto_nhdsWithin (hs.insert x) this
715715
rcases EMetric.mem_nhdsWithin_iff.1 this with ⟨δ, δpos, Hδ⟩
716716
exact ⟨δ, δpos, fun {z} hz => Hδ (by rwa [Set.inter_comm])⟩
@@ -726,12 +726,12 @@ theorem HasFPowerSeriesWithinAt.comp {g : F → G} {f : E → F} {q : FormalMult
726726
/- Let `y` satisfy `‖y‖ < min (r, rf', δ)`. We want to show that `g (f (x + y))` is the sum of
727727
`q.comp p` applied to `y`. -/
728728
-- First, check that `y` is small enough so that estimates for `f` and `g` apply.
729-
have y_mem : y ∈ EMetric.ball (0 : E) rf :=
730-
(EMetric.ball_subset_ball (le_trans (min_le_left _ _) (min_le_left _ _))) hy
731-
have fy_mem : f (x + y) ∈ insert (f x) t ∩ EMetric.ball (f x) rg := by
729+
have y_mem : y ∈ Metric.eball (0 : E) rf :=
730+
(Metric.eball_subset_eball (le_trans (min_le_left _ _) (min_le_left _ _))) hy
731+
have fy_mem : f (x + y) ∈ insert (f x) t ∩ Metric.eball (f x) rg := by
732732
apply hδ
733-
have : y ∈ EMetric.ball (0 : E) δ :=
734-
(EMetric.ball_subset_ball (le_trans (min_le_left _ _) (min_le_right _ _))) hy
733+
have : y ∈ Metric.eball (0 : E) δ :=
734+
(Metric.eball_subset_eball (le_trans (min_le_left _ _) (min_le_right _ _))) hy
735735
simpa [-Set.mem_insert_iff, edist_eq_enorm_sub, h'y]
736736
/- Now the proof starts. To show that the sum of `q.comp p` at `y` is `g (f (x + y))`,
737737
we will write `q.comp p` applied to `y` as a big sum over all compositions.
@@ -795,7 +795,7 @@ theorem HasFPowerSeriesWithinAt.comp {g : F → G} {f : E → F} {q : FormalMult
795795
_ ≤ ‖compAlongComposition q p c‖ * (r : ℝ) ^ n := by
796796
rw [Finset.prod_const, Finset.card_fin]
797797
gcongr
798-
rw [EMetric.mem_ball, edist_zero_eq_enorm] at hy
798+
rw [Metric.mem_eball, edist_zero_eq_enorm] at hy
799799
have := le_trans (le_of_lt hy) (min_le_right _ _)
800800
rwa [enorm_le_coe, ← NNReal.coe_le_coe, coe_nnnorm] at this
801801
tendsto_nhds_of_cauchySeq_of_subseq cau compPartialSumTarget_tendsto_atTop C

0 commit comments

Comments
 (0)