@@ -390,6 +390,7 @@ lemma hasFDerivWithinAt_of_isOpen (h : IsOpen s) (hx : x ∈ s) :
390390 HasFDerivWithinAt f f' s x ↔ HasFDerivAt f f' x :=
391391 hasFDerivWithinAt_of_mem_nhds (h.mem_nhds hx)
392392
393+ @[simp]
393394theorem hasFDerivWithinAt_insert {y : E} :
394395 HasFDerivWithinAt f f' (insert y s) x ↔ HasFDerivWithinAt f f' s x := by
395396 rcases eq_or_ne x y with (rfl | h)
@@ -405,10 +406,42 @@ protected theorem HasFDerivWithinAt.insert (h : HasFDerivWithinAt g g' s x) :
405406 HasFDerivWithinAt g g' (insert x s) x :=
406407 h.insert'
407408
409+ @[simp]
408410theorem hasFDerivWithinAt_diff_singleton (y : E) :
409411 HasFDerivWithinAt f f' (s \ {y}) x ↔ HasFDerivWithinAt f f' s x := by
410412 rw [← hasFDerivWithinAt_insert, insert_diff_singleton, hasFDerivWithinAt_insert]
411413
414+ @[simp]
415+ protected theorem HasFDerivWithinAt.empty : HasFDerivWithinAt f f' ∅ x := by
416+ simp [HasFDerivWithinAt, hasFDerivAtFilter_iff_isLittleOTVS]
417+
418+ @[simp]
419+ protected theorem DifferentiableWithinAt.empty : DifferentiableWithinAt 𝕜 f ∅ x :=
420+ ⟨0 , .empty⟩
421+
422+ theorem HasFDerivWithinAt.of_finite (h : s.Finite) : HasFDerivWithinAt f f' s x := by
423+ induction s, h using Set.Finite.induction_on with
424+ | empty => exact .empty
425+ | insert _ _ ih => exact ih.insert'
426+
427+ theorem DifferentiableWithinAt.of_finite (h : s.Finite) : DifferentiableWithinAt 𝕜 f s x :=
428+ ⟨0 , .of_finite h⟩
429+
430+ @[simp]
431+ protected theorem HasFDerivWithinAt.singleton {y} : HasFDerivWithinAt f f' {x} y :=
432+ .of_finite <| finite_singleton _
433+
434+ @[simp]
435+ protected theorem DifferentiableWithinAt.singleton {y} : DifferentiableWithinAt 𝕜 f {x} y :=
436+ ⟨0 , .singleton⟩
437+
438+ theorem HasFDerivWithinAt.of_subsingleton (h : s.Subsingleton) : HasFDerivWithinAt f f' s x :=
439+ .of_finite h.finite
440+
441+ theorem DifferentiableWithinAt.of_subsingleton (h : s.Subsingleton) :
442+ DifferentiableWithinAt 𝕜 f s x :=
443+ .of_finite h.finite
444+
412445theorem HasStrictFDerivAt.isBigO_sub (hf : HasStrictFDerivAt f f' x) :
413446 (fun p : E × E => f p.1 - f p.2 ) =O[𝓝 (x, x)] fun p : E × E => p.1 - p.2 :=
414447 hf.isLittleO.isBigO.congr_of_sub.2 (f'.isBigO_comp _ _)
0 commit comments