Skip to content

Commit

Permalink
feat: Add congr_deriv lemmas mirroring congr_fderiv (#9065)
Browse files Browse the repository at this point in the history
Add convenience lemmas
* `HasStrictDerivAt.congr_deriv`
* `HasDerivAt.congr_deriv`
* `HasDerivWithinAt.congr_deriv`

These mirror the already existing
* `HasStrictFDerivAt.congr_fderiv`
* `HasFDerivAt.congr_fderiv`
* `HasFDerivWithinAt.congr_fderiv`
  • Loading branch information
winstonyin authored and awueth committed Dec 19, 2023
1 parent 05d5e25 commit 5aabd4e
Showing 1 changed file with 11 additions and 0 deletions.
11 changes: 11 additions & 0 deletions Mathlib/Analysis/Calculus/Deriv/Basic.lean
Original file line number Diff line number Diff line change
Expand Up @@ -614,6 +614,17 @@ theorem Filter.EventuallyEq.hasDerivWithinAt_iff_of_mem (h₁ : f₁ =ᶠ[𝓝[s
fun h' ↦ h'.congr_of_eventuallyEq_of_mem h₁.symm hx,
fun h' ↦ h'.congr_of_eventuallyEq_of_mem h₁ hx⟩

theorem HasStrictDerivAt.congr_deriv (h : HasStrictDerivAt f f' x) (h' : f' = g') :
HasStrictDerivAt f g' x :=
h.congr_fderiv <| congr_arg _ h'

theorem HasDerivAt.congr_deriv (h : HasDerivAt f f' x) (h' : f' = g') : HasDerivAt f g' x :=
HasFDerivAt.congr_fderiv h <| congr_arg _ h'

theorem HasDerivWithinAt.congr_deriv (h : HasDerivWithinAt f f' s x) (h' : f' = g') :
HasDerivWithinAt f g' s x :=
HasFDerivWithinAt.congr_fderiv h <| congr_arg _ h'

theorem HasDerivAt.congr_of_eventuallyEq (h : HasDerivAt f f' x) (h₁ : f₁ =ᶠ[𝓝 x] f) :
HasDerivAt f₁ f' x :=
HasDerivAtFilter.congr_of_eventuallyEq h h₁ (mem_of_mem_nhds h₁ : _)
Expand Down

0 comments on commit 5aabd4e

Please sign in to comment.