Skip to content

Commit b7d36b6

Browse files
committed
chore(Analysis/Calculus/FDeriv/Extend): use Lean 4 naming scheme (#14632)
Most of the declarations in this file are still named according to the Lean 3 naming scheme.
1 parent fba419c commit b7d36b6

File tree

1 file changed

+33
-23
lines changed

1 file changed

+33
-23
lines changed

Mathlib/Analysis/Calculus/FDeriv/Extend.lean

+33-23
Original file line numberDiff line numberDiff line change
@@ -12,13 +12,12 @@ import Mathlib.Analysis.Calculus.MeanValue
1212
1313
We investigate how differentiable functions inside a set extend to differentiable functions
1414
on the boundary. For this, it suffices that the function and its derivative admit limits there.
15-
A general version of this statement is given in `has_fderiv_at_boundary_of_tendsto_fderiv`.
15+
A general version of this statement is given in `hasFDerivWithinAt_closure_of_tendsto_fderiv`.
1616
1717
One-dimensional versions, in which one wants to obtain differentiability at the left endpoint or
18-
the right endpoint of an interval, are given in
19-
`has_deriv_at_interval_left_endpoint_of_tendsto_deriv` and
20-
`has_deriv_at_interval_right_endpoint_of_tendsto_deriv`. These versions are formulated in terms
21-
of the one-dimensional derivative `deriv ℝ f`.
18+
the right endpoint of an interval, are given in `hasDerivWithinAt_Ici_of_tendsto_deriv` and
19+
`hasDerivWithinAt_Iic_of_tendsto_deriv`. These versions are formulated in terms of the
20+
one-dimensional derivative `deriv ℝ f`.
2221
-/
2322

2423

@@ -32,7 +31,7 @@ open scoped Topology
3231
/-- If a function `f` is differentiable in a convex open set and continuous on its closure, and its
3332
derivative converges to a limit `f'` at a point on the boundary, then `f` is differentiable there
3433
with derivative `f'`. -/
35-
theorem has_fderiv_at_boundary_of_tendsto_fderiv {f : E → F} {s : Set E} {x : E} {f' : E →L[ℝ] F}
34+
theorem hasFDerivWithinAt_closure_of_tendsto_fderiv {f : E → F} {s : Set E} {x : E} {f' : E →L[ℝ] F}
3635
(f_diff : DifferentiableOn ℝ f s) (s_conv : Convex ℝ s) (s_open : IsOpen s)
3736
(f_cont : ∀ y ∈ closure s, ContinuousWithinAt f s y)
3837
(h : Tendsto (fun y => fderiv ℝ f y) (𝓝[s] x) (𝓝 f')) :
@@ -102,16 +101,20 @@ theorem has_fderiv_at_boundary_of_tendsto_fderiv {f : E → F} {s : Set E} {x :
102101
exact
103102
tendsto_const_nhds.mul
104103
(Tendsto.comp continuous_norm.continuousAt <| tendsto_snd.sub tendsto_fst)
105-
#align has_fderiv_at_boundary_of_tendsto_fderiv has_fderiv_at_boundary_of_tendsto_fderiv
104+
#align has_fderiv_at_boundary_of_tendsto_fderiv hasFDerivWithinAt_closure_of_tendsto_fderiv
105+
106+
@[deprecated (since := "2024-07-10")] alias has_fderiv_at_boundary_of_tendsto_fderiv :=
107+
hasFDerivWithinAt_closure_of_tendsto_fderiv
106108

107109
/-- If a function is differentiable on the right of a point `a : ℝ`, continuous at `a`, and
108110
its derivative also converges at `a`, then `f` is differentiable on the right at `a`. -/
109-
theorem has_deriv_at_interval_left_endpoint_of_tendsto_deriv {s : Set ℝ} {e : E} {a : ℝ} {f : ℝ → E}
111+
theorem hasDerivWithinAt_Ici_of_tendsto_deriv {s : Set ℝ} {e : E} {a : ℝ} {f : ℝ → E}
110112
(f_diff : DifferentiableOn ℝ f s) (f_lim : ContinuousWithinAt f s a) (hs : s ∈ 𝓝[>] a)
111113
(f_lim' : Tendsto (fun x => deriv f x) (𝓝[>] a) (𝓝 e)) : HasDerivWithinAt f e (Ici a) a := by
112-
/- This is a specialization of `has_fderiv_at_boundary_of_tendsto_fderiv`. To be in the setting of
113-
this theorem, we need to work on an open interval with closure contained in `s ∪ {a}`, that we
114-
call `t = (a, b)`. Then, we check all the assumptions of this theorem and we apply it. -/
114+
/- This is a specialization of `hasFDerivWithinAt_closure_of_tendsto_fderiv`. To be in the
115+
setting of this theorem, we need to work on an open interval with closure contained in
116+
`s ∪ {a}`, that we call `t = (a, b)`. Then, we check all the assumptions of this theorem and
117+
we apply it. -/
115118
obtain ⟨b, ab : a < b, sab : Ioc a b ⊆ s⟩ := mem_nhdsWithin_Ioi_iff_exists_Ioc_subset.1 hs
116119
let t := Ioo a b
117120
have ts : t ⊆ s := Subset.trans Ioo_subset_Ioc_self sab
@@ -131,22 +134,26 @@ theorem has_deriv_at_interval_left_endpoint_of_tendsto_deriv {s : Set ℝ} {e :
131134
exact Tendsto.comp
132135
(isBoundedBilinearMap_smulRight : IsBoundedBilinearMap ℝ _).continuous_right.continuousAt
133136
(tendsto_nhdsWithin_mono_left Ioo_subset_Ioi_self f_lim')
134-
-- now we can apply `has_fderiv_at_boundary_of_differentiable`
137+
-- now we can apply `hasFDerivWithinAt_closure_of_tendsto_fderiv`
135138
have : HasDerivWithinAt f e (Icc a b) a := by
136139
rw [hasDerivWithinAt_iff_hasFDerivWithinAt, ← t_closure]
137-
exact has_fderiv_at_boundary_of_tendsto_fderiv t_diff t_conv t_open t_cont t_diff'
140+
exact hasFDerivWithinAt_closure_of_tendsto_fderiv t_diff t_conv t_open t_cont t_diff'
138141
exact this.mono_of_mem (Icc_mem_nhdsWithin_Ici <| left_mem_Ico.2 ab)
139-
#align has_deriv_at_interval_left_endpoint_of_tendsto_deriv has_deriv_at_interval_left_endpoint_of_tendsto_deriv
142+
#align has_deriv_at_interval_left_endpoint_of_tendsto_deriv hasDerivWithinAt_Ici_of_tendsto_deriv
143+
144+
@[deprecated (since := "2024-07-10")] alias has_deriv_at_interval_left_endpoint_of_tendsto_deriv :=
145+
hasDerivWithinAt_Ici_of_tendsto_deriv
140146

141147
/-- If a function is differentiable on the left of a point `a : ℝ`, continuous at `a`, and
142148
its derivative also converges at `a`, then `f` is differentiable on the left at `a`. -/
143-
theorem has_deriv_at_interval_right_endpoint_of_tendsto_deriv {s : Set ℝ} {e : E} {a : ℝ}
149+
theorem hasDerivWithinAt_Iic_of_tendsto_deriv {s : Set ℝ} {e : E} {a : ℝ}
144150
{f : ℝ → E} (f_diff : DifferentiableOn ℝ f s) (f_lim : ContinuousWithinAt f s a)
145151
(hs : s ∈ 𝓝[<] a) (f_lim' : Tendsto (fun x => deriv f x) (𝓝[<] a) (𝓝 e)) :
146152
HasDerivWithinAt f e (Iic a) a := by
147-
/- This is a specialization of `has_fderiv_at_boundary_of_differentiable`. To be in the setting of
148-
this theorem, we need to work on an open interval with closure contained in `s ∪ {a}`, that we
149-
call `t = (b, a)`. Then, we check all the assumptions of this theorem and we apply it. -/
153+
/- This is a specialization of `hasFDerivWithinAt_closure_of_tendsto_fderiv`. To be in the
154+
setting of this theorem, we need to work on an open interval with closure contained in
155+
`s ∪ {a}`, that we call `t = (b, a)`. Then, we check all the assumptions of this theorem and we
156+
apply it. -/
150157
obtain ⟨b, ba, sab⟩ : ∃ b ∈ Iio a, Ico b a ⊆ s := mem_nhdsWithin_Iio_iff_exists_Ico_subset.1 hs
151158
let t := Ioo b a
152159
have ts : t ⊆ s := Subset.trans Ioo_subset_Ico_self sab
@@ -166,12 +173,15 @@ theorem has_deriv_at_interval_right_endpoint_of_tendsto_deriv {s : Set ℝ} {e :
166173
exact Tendsto.comp
167174
(isBoundedBilinearMap_smulRight : IsBoundedBilinearMap ℝ _).continuous_right.continuousAt
168175
(tendsto_nhdsWithin_mono_left Ioo_subset_Iio_self f_lim')
169-
-- now we can apply `has_fderiv_at_boundary_of_differentiable`
176+
-- now we can apply `hasFDerivWithinAt_closure_of_tendsto_fderiv`
170177
have : HasDerivWithinAt f e (Icc b a) a := by
171178
rw [hasDerivWithinAt_iff_hasFDerivWithinAt, ← t_closure]
172-
exact has_fderiv_at_boundary_of_tendsto_fderiv t_diff t_conv t_open t_cont t_diff'
179+
exact hasFDerivWithinAt_closure_of_tendsto_fderiv t_diff t_conv t_open t_cont t_diff'
173180
exact this.mono_of_mem (Icc_mem_nhdsWithin_Iic <| right_mem_Ioc.2 ba)
174-
#align has_deriv_at_interval_right_endpoint_of_tendsto_deriv has_deriv_at_interval_right_endpoint_of_tendsto_deriv
181+
#align has_deriv_at_interval_right_endpoint_of_tendsto_deriv hasDerivWithinAt_Iic_of_tendsto_deriv
182+
183+
@[deprecated (since := "2024-07-10")] alias has_deriv_at_interval_right_endpoint_of_tendsto_deriv :=
184+
hasDerivWithinAt_Iic_of_tendsto_deriv
175185

176186
/-- If a real function `f` has a derivative `g` everywhere but at a point, and `f` and `g` are
177187
continuous at this point, then `g` is also the derivative of `f` at this point. -/
@@ -184,7 +194,7 @@ theorem hasDerivAt_of_hasDerivAt_of_ne {f g : ℝ → E} {x : ℝ}
184194
-- next line is the nontrivial bit of this proof, appealing to differentiability
185195
-- extension results.
186196
apply
187-
has_deriv_at_interval_left_endpoint_of_tendsto_deriv diff hf.continuousWithinAt
197+
hasDerivWithinAt_Ici_of_tendsto_deriv diff hf.continuousWithinAt
188198
self_mem_nhdsWithin
189199
have : Tendsto g (𝓝[>] x) (𝓝 (g x)) := tendsto_inf_left hg
190200
apply this.congr' _
@@ -197,7 +207,7 @@ theorem hasDerivAt_of_hasDerivAt_of_ne {f g : ℝ → E} {x : ℝ}
197207
-- next line is the nontrivial bit of this proof, appealing to differentiability
198208
-- extension results.
199209
apply
200-
has_deriv_at_interval_right_endpoint_of_tendsto_deriv diff hf.continuousWithinAt
210+
hasDerivWithinAt_Iic_of_tendsto_deriv diff hf.continuousWithinAt
201211
self_mem_nhdsWithin
202212
have : Tendsto g (𝓝[<] x) (𝓝 (g x)) := tendsto_inf_left hg
203213
apply this.congr' _

0 commit comments

Comments
 (0)