Glueing derivatives along a threshold
ProvedMovingSofa.ForMathlib.hasDerivAt_if_lecalculus
Two everywhere-differentiable functions agreeing in value and derivative at a threshold glue to a differentiable function with glued derivative.
Preamble
import Mathlib.Analysis.Calculus.ContDiff.Deriv open Set
Formal statement
namespace MovingSofa.ForMathlib
theorem hasDerivAt_if_le {E : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E]
{f g f' g' : ℝ → E} {c : ℝ}
(hf : ∀ t, HasDerivAt f (f' t) t) (hg : ∀ t, HasDerivAt g (g' t) t)
(hfg : f c = g c) (hfg' : f' c = g' c) (t : ℝ) :
HasDerivAt (fun s => if s ≤ c then f s else g s) (if t ≤ c then f' t else g' t) t := by sorry
end MovingSofa.ForMathlibSource