The Mathlib Handbook

The volumes of the handbook are not written yet. This site shows the map of Mathlib that they will follow, at Mathlib 4472534b60.

The areas / V17. Differential calculus in normed spaces

Mathlib.Analysis.Calculus.Gradient.Basic

79 declarations. Mathlib docs Β· Source

Gradient

Main Definitions

Let f be a function from a Hilbert Space F to π•œ (π•œ is ℝ or β„‚), x be a point in F and f' be a vector in F. Then

HasGradientWithinAt f f' s x

says that f has a gradient f' at x, where the domain of interest is restricted to s. We also have

HasGradientAt f f' x := HasGradientWithinAt f f' x univ

Main results

This file develops the following aspects of the theory of gradients:

  • definitions of gradients, both within a set and on the whole space.
  • translating between HasGradientAtFilter and HasFDerivAtFilter, HasGradientWithinAt and HasFDerivWithinAt, HasGradientAt and HasFDerivAt, gradient and fderiv.
  • uniqueness of gradients.
  • translating between HasGradientAtFilter and HasDerivAtFilter, HasGradientAt and HasDerivAt, gradient and deriv when F = π•œ.
  • the theorems about the inner product of the gradient.
  • the congruence of the gradient.
  • the gradient of constant functions.
  • the continuity of a function admitting a gradient.

Congruence properties of the Gradient

The Gradient of constant functions

Continuity of a function admitting a gradient

theorem HasGradientAt.congr_simp E1 #

βˆ€ {π•œ : Type u_1} {F : Type u_2} [inst : RCLike π•œ] [inst_1 : NormedAddCommGroup F] [inst_2 : InnerProductSpace π•œ F]
  [inst_3 : CompleteSpace F] (f f_1 : F β†’ π•œ),
  f = f_1 β†’ βˆ€ (f' f'_1 : F), f' = f'_1 β†’ βˆ€ (x x_1 : F), x = x_1 β†’ HasGradientAt f f' x = HasGradientAt f_1 f'_1 x_1

theorem HasGradientWithinAt.congr_simp E1 #

βˆ€ {π•œ : Type u_1} {F : Type u_2} [inst : RCLike π•œ] [inst_1 : NormedAddCommGroup F] [inst_2 : InnerProductSpace π•œ F]
  [inst_3 : CompleteSpace F] (f f_1 : F β†’ π•œ),
  f = f_1 β†’
    βˆ€ (f' f'_1 : F),
      f' = f'_1 β†’
        βˆ€ (s s_1 : Set F),
          s = s_1 β†’ βˆ€ (x x_1 : F), x = x_1 β†’ HasGradientWithinAt f f' s x = HasGradientWithinAt f_1 f'_1 s_1 x_1

theorem gradient.congr_simp E1 #

βˆ€ {π•œ : Type u_1} {F : Type u_2} [inst : RCLike π•œ] [inst_1 : NormedAddCommGroup F] [inst_2 : InnerProductSpace π•œ F]
  [inst_3 : CompleteSpace F] (f f_1 : F β†’ π•œ), f = f_1 β†’ βˆ€ (x x_1 : F), x = x_1 β†’ gradient f x = gradient f_1 x_1

theorem gradientWithin.congr_simp E1 #

βˆ€ {π•œ : Type u_1} {F : Type u_2} [inst : RCLike π•œ] [inst_1 : NormedAddCommGroup F] [inst_2 : InnerProductSpace π•œ F]
  [inst_3 : CompleteSpace F] (f f_1 : F β†’ π•œ),
  f = f_1 β†’ βˆ€ (s s_1 : Set F), s = s_1 β†’ βˆ€ (x x_1 : F), x = x_1 β†’ gradientWithin f s x = gradientWithin f_1 s_1 x_1

def HasGradientAtFilter E3 #

{π•œ : Type u_1} β†’
  {F : Type u_2} β†’
    [inst : RCLike π•œ] β†’
      [inst_1 : NormedAddCommGroup F] β†’ [InnerProductSpace π•œ F] β†’ [CompleteSpace F] β†’ (F β†’ π•œ) β†’ F β†’ F β†’ Filter F β†’ Prop

A function f has the gradient f' as derivative along the filter L if f x' = f x + ⟨f', x' - x⟩ + o (x' - x) when x' converges along the filter L.

def HasGradientWithinAt E3 #

{π•œ : Type u_1} β†’
  {F : Type u_2} β†’
    [inst : RCLike π•œ] β†’
      [inst_1 : NormedAddCommGroup F] β†’ [InnerProductSpace π•œ F] β†’ [CompleteSpace F] β†’ (F β†’ π•œ) β†’ F β†’ Set F β†’ F β†’ Prop

f has the gradient f' at the point x within the subset s if f x' = f x + ⟨f', x' - x⟩ + o (x' - x) where x' converges to x inside s.

def HasGradientAt E3 #

{π•œ : Type u_1} β†’
  {F : Type u_2} β†’
    [inst : RCLike π•œ] β†’
      [inst_1 : NormedAddCommGroup F] β†’ [InnerProductSpace π•œ F] β†’ [CompleteSpace F] β†’ (F β†’ π•œ) β†’ F β†’ F β†’ Prop

f has the gradient f' at the point x if f x' = f x + ⟨f', x' - x⟩ + o (x' - x) where x' converges to x.

def gradientWithin E1 #

{π•œ : Type u_1} β†’
  {F : Type u_2} β†’
    [inst : RCLike π•œ] β†’
      [inst_1 : NormedAddCommGroup F] β†’ [InnerProductSpace π•œ F] β†’ [CompleteSpace F] β†’ (F β†’ π•œ) β†’ Set F β†’ F β†’ F

Gradient of f at the point x within the set s, if it exists. Zero otherwise.

If the derivative exists (i.e., βˆƒ f', HasGradientWithinAt f f' s x), then f x' = f x + ⟨f', x' - x⟩ + o (x' - x) where x' converges to x inside s.

def gradient E3 #

{π•œ : Type u_1} β†’
  {F : Type u_2} β†’
    [inst : RCLike π•œ] β†’ [inst_1 : NormedAddCommGroup F] β†’ [InnerProductSpace π•œ F] β†’ [CompleteSpace F] β†’ (F β†’ π•œ) β†’ F β†’ F

Gradient of f at the point x, if it exists. Zero otherwise. Denoted as βˆ‡ within the Gradient namespace.

If the derivative exists (i.e., βˆƒ f', HasGradientAt f f' x), then f x' = f x + ⟨f', x' - x⟩ + o (x' - x) where x' converges to x.

def Gradient.Β«termβˆ‡Β» E1 #

Lean.ParserDescr

Gradient of f at the point x, if it exists. Zero otherwise. Denoted as βˆ‡ within the Gradient namespace.

If the derivative exists (i.e., βˆƒ f', HasGradientAt f f' x), then f x' = f x + ⟨f', x' - x⟩ + o (x' - x) where x' converges to x.

theorem hasGradientWithinAt_iff_hasFDerivWithinAt E1 #

βˆ€ {π•œ : Type u_1} {F : Type u_2} [inst : RCLike π•œ] [inst_1 : NormedAddCommGroup F] [inst_2 : InnerProductSpace π•œ F]
  [inst_3 : CompleteSpace F] {f : F β†’ π•œ} {f' x : F} {s : Set F},
  HasGradientWithinAt f f' s x ↔ HasFDerivWithinAt f ((InnerProductSpace.toDual π•œ F) f') s x

theorem hasFDerivWithinAt_iff_hasGradientWithinAt E1 #

βˆ€ {π•œ : Type u_1} {F : Type u_2} [inst : RCLike π•œ] [inst_1 : NormedAddCommGroup F] [inst_2 : InnerProductSpace π•œ F]
  [inst_3 : CompleteSpace F] {f : F β†’ π•œ} {x : F} {frechet : StrongDual π•œ F} {s : Set F},
  HasFDerivWithinAt f frechet s x ↔ HasGradientWithinAt f ((InnerProductSpace.toDual π•œ F).symm frechet) s x

theorem hasGradientAt_iff_hasFDerivAt E1 #

βˆ€ {π•œ : Type u_1} {F : Type u_2} [inst : RCLike π•œ] [inst_1 : NormedAddCommGroup F] [inst_2 : InnerProductSpace π•œ F]
  [inst_3 : CompleteSpace F] {f : F β†’ π•œ} {f' x : F},
  HasGradientAt f f' x ↔ HasFDerivAt f ((InnerProductSpace.toDual π•œ F) f') x

theorem hasFDerivAt_iff_hasGradientAt E1 #

βˆ€ {π•œ : Type u_1} {F : Type u_2} [inst : RCLike π•œ] [inst_1 : NormedAddCommGroup F] [inst_2 : InnerProductSpace π•œ F]
  [inst_3 : CompleteSpace F] {f : F β†’ π•œ} {x : F} {frechet : StrongDual π•œ F},
  HasFDerivAt f frechet x ↔ HasGradientAt f ((InnerProductSpace.toDual π•œ F).symm frechet) x

theorem HasGradientWithinAt.hasFDerivWithinAt E1 #

βˆ€ {π•œ : Type u_1} {F : Type u_2} [inst : RCLike π•œ] [inst_1 : NormedAddCommGroup F] [inst_2 : InnerProductSpace π•œ F]
  [inst_3 : CompleteSpace F] {f : F β†’ π•œ} {f' x : F} {s : Set F},
  HasGradientWithinAt f f' s x β†’ HasFDerivWithinAt f ((InnerProductSpace.toDual π•œ F) f') s x

Alias of the forward direction of hasGradientWithinAt_iff_hasFDerivWithinAt.

theorem HasFDerivWithinAt.hasGradientWithinAt E1 #

βˆ€ {π•œ : Type u_1} {F : Type u_2} [inst : RCLike π•œ] [inst_1 : NormedAddCommGroup F] [inst_2 : InnerProductSpace π•œ F]
  [inst_3 : CompleteSpace F] {f : F β†’ π•œ} {x : F} {frechet : StrongDual π•œ F} {s : Set F},
  HasFDerivWithinAt f frechet s x β†’ HasGradientWithinAt f ((InnerProductSpace.toDual π•œ F).symm frechet) s x

Alias of the forward direction of hasFDerivWithinAt_iff_hasGradientWithinAt.

theorem HasGradientAt.hasFDerivAt E1 #

βˆ€ {π•œ : Type u_1} {F : Type u_2} [inst : RCLike π•œ] [inst_1 : NormedAddCommGroup F] [inst_2 : InnerProductSpace π•œ F]
  [inst_3 : CompleteSpace F] {f : F β†’ π•œ} {f' x : F},
  HasGradientAt f f' x β†’ HasFDerivAt f ((InnerProductSpace.toDual π•œ F) f') x

Alias of the forward direction of hasGradientAt_iff_hasFDerivAt.

theorem HasFDerivAt.hasGradientAt E1 #

βˆ€ {π•œ : Type u_1} {F : Type u_2} [inst : RCLike π•œ] [inst_1 : NormedAddCommGroup F] [inst_2 : InnerProductSpace π•œ F]
  [inst_3 : CompleteSpace F] {f : F β†’ π•œ} {x : F} {frechet : StrongDual π•œ F},
  HasFDerivAt f frechet x β†’ HasGradientAt f ((InnerProductSpace.toDual π•œ F).symm frechet) x

Alias of the forward direction of hasFDerivAt_iff_hasGradientAt.

theorem gradient_eq_zero_of_not_differentiableAt E1 #

βˆ€ {π•œ : Type u_1} {F : Type u_2} [inst : RCLike π•œ] [inst_1 : NormedAddCommGroup F] [inst_2 : InnerProductSpace π•œ F]
  [inst_3 : CompleteSpace F] {f : F β†’ π•œ} {x : F}, Β¬DifferentiableAt π•œ f x β†’ gradient f x = 0

theorem toDual_gradientWithin E0 #

βˆ€ {π•œ : Type u_1} {F : Type u_2} [inst : RCLike π•œ] [inst_1 : NormedAddCommGroup F] [inst_2 : InnerProductSpace π•œ F]
  [inst_3 : CompleteSpace F] {f : F β†’ π•œ} {x : F} {s : Set F},
  (InnerProductSpace.toDual π•œ F) (gradientWithin f s x) = fderivWithin π•œ f s x

theorem toDual_gradient E0 #

βˆ€ {π•œ : Type u_1} {F : Type u_2} [inst : RCLike π•œ] [inst_1 : NormedAddCommGroup F] [inst_2 : InnerProductSpace π•œ F]
  [inst_3 : CompleteSpace F] {f : F β†’ π•œ} {x : F}, (InnerProductSpace.toDual π•œ F) (gradient f x) = fderiv π•œ f x

theorem toDual_comp_gradientWithin E0 #

βˆ€ {π•œ : Type u_1} {F : Type u_2} [inst : RCLike π•œ] [inst_1 : NormedAddCommGroup F] [inst_2 : InnerProductSpace π•œ F]
  [inst_3 : CompleteSpace F] {f : F β†’ π•œ} {s : Set F},
  ⇑(InnerProductSpace.toDual π•œ F) ∘ gradientWithin f s = fderivWithin π•œ f s

theorem toDual_comp_gradient E0 #

βˆ€ {π•œ : Type u_1} {F : Type u_2} [inst : RCLike π•œ] [inst_1 : NormedAddCommGroup F] [inst_2 : InnerProductSpace π•œ F]
  [inst_3 : CompleteSpace F] {f : F β†’ π•œ}, ⇑(InnerProductSpace.toDual π•œ F) ∘ gradient f = fderiv π•œ f

theorem HasGradientAt.unique E1 #

βˆ€ {π•œ : Type u_1} {F : Type u_2} [inst : RCLike π•œ] [inst_1 : NormedAddCommGroup F] [inst_2 : InnerProductSpace π•œ F]
  [inst_3 : CompleteSpace F] {f : F β†’ π•œ} {x gradf gradg : F},
  HasGradientAt f gradf x β†’ HasGradientAt f gradg x β†’ gradf = gradg

theorem DifferentiableAt.hasGradientAt E1 #

βˆ€ {π•œ : Type u_1} {F : Type u_2} [inst : RCLike π•œ] [inst_1 : NormedAddCommGroup F] [inst_2 : InnerProductSpace π•œ F]
  [inst_3 : CompleteSpace F] {f : F β†’ π•œ} {x : F}, DifferentiableAt π•œ f x β†’ HasGradientAt f (gradient f x) x

theorem HasGradientAt.differentiableAt E1 #

βˆ€ {π•œ : Type u_1} {F : Type u_2} [inst : RCLike π•œ] [inst_1 : NormedAddCommGroup F] [inst_2 : InnerProductSpace π•œ F]
  [inst_3 : CompleteSpace F] {f : F β†’ π•œ} {f' x : F}, HasGradientAt f f' x β†’ DifferentiableAt π•œ f x

theorem DifferentiableWithinAt.hasGradientWithinAt E1 #

βˆ€ {π•œ : Type u_1} {F : Type u_2} [inst : RCLike π•œ] [inst_1 : NormedAddCommGroup F] [inst_2 : InnerProductSpace π•œ F]
  [inst_3 : CompleteSpace F] {f : F β†’ π•œ} {x : F} {s : Set F},
  DifferentiableWithinAt π•œ f s x β†’ HasGradientWithinAt f (gradientWithin f s x) s x

theorem HasGradientWithinAt.differentiableWithinAt E1 #

βˆ€ {π•œ : Type u_1} {F : Type u_2} [inst : RCLike π•œ] [inst_1 : NormedAddCommGroup F] [inst_2 : InnerProductSpace π•œ F]
  [inst_3 : CompleteSpace F] {f : F β†’ π•œ} {f' x : F} {s : Set F},
  HasGradientWithinAt f f' s x β†’ DifferentiableWithinAt π•œ f s x

theorem hasGradientWithinAt_univ E0 #

βˆ€ {π•œ : Type u_1} {F : Type u_2} [inst : RCLike π•œ] [inst_1 : NormedAddCommGroup F] [inst_2 : InnerProductSpace π•œ F]
  [inst_3 : CompleteSpace F] {f : F β†’ π•œ} {f' x : F}, HasGradientWithinAt f f' Set.univ x ↔ HasGradientAt f f' x

theorem gradientWithin_univ E0 #

βˆ€ {π•œ : Type u_1} {F : Type u_2} [inst : RCLike π•œ] [inst_1 : NormedAddCommGroup F] [inst_2 : InnerProductSpace π•œ F]
  [inst_3 : CompleteSpace F] {f : F β†’ π•œ}, gradientWithin f Set.univ = gradient f

theorem DifferentiableOn.hasGradientAt E1 #

βˆ€ {π•œ : Type u_1} {F : Type u_2} [inst : RCLike π•œ] [inst_1 : NormedAddCommGroup F] [inst_2 : InnerProductSpace π•œ F]
  [inst_3 : CompleteSpace F] {f : F β†’ π•œ} {x : F} {s : Set F},
  DifferentiableOn π•œ f s β†’ s ∈ nhds x β†’ HasGradientAt f (gradient f x) x

theorem HasGradientAt.gradient E3 #

βˆ€ {π•œ : Type u_1} {F : Type u_2} [inst : RCLike π•œ] [inst_1 : NormedAddCommGroup F] [inst_2 : InnerProductSpace π•œ F]
  [inst_3 : CompleteSpace F] {f : F β†’ π•œ} {f' x : F}, HasGradientAt f f' x β†’ gradient f x = f'

theorem gradient_eq E0 #

βˆ€ {π•œ : Type u_1} {F : Type u_2} [inst : RCLike π•œ] [inst_1 : NormedAddCommGroup F] [inst_2 : InnerProductSpace π•œ F]
  [inst_3 : CompleteSpace F] {f : F β†’ π•œ} {f' : F β†’ F}, (βˆ€ (x : F), HasGradientAt f (f' x) x) β†’ gradient f = f'

theorem HasGradientAtFilter.hasDerivAtFilter E1 #

βˆ€ {π•œ : Type u_1} [inst : RCLike π•œ] {g : π•œ β†’ π•œ} {g' u : π•œ} {L' : Filter π•œ},
  HasGradientAtFilter g g' u L' β†’ HasDerivAtFilter g ((starRingEnd π•œ) g') (L' Γ—Λ’ pure u)

theorem HasDerivAtFilter.hasGradientAtFilter E1 #

βˆ€ {π•œ : Type u_1} [inst : RCLike π•œ] {g : π•œ β†’ π•œ} {g' u : π•œ} {L' : Filter π•œ},
  HasDerivAtFilter g g' (L' Γ—Λ’ pure u) β†’ HasGradientAtFilter g ((starRingEnd π•œ) g') u L'

theorem HasGradientAt.hasDerivAt E1 #

βˆ€ {π•œ : Type u_1} [inst : RCLike π•œ] {g : π•œ β†’ π•œ} {g' u : π•œ}, HasGradientAt g g' u β†’ HasDerivAt g ((starRingEnd π•œ) g') u

theorem HasDerivAt.hasGradientAt E1 #

βˆ€ {π•œ : Type u_1} [inst : RCLike π•œ] {g : π•œ β†’ π•œ} {g' u : π•œ}, HasDerivAt g g' u β†’ HasGradientAt g ((starRingEnd π•œ) g') u

theorem gradient_eq_deriv E1 #

βˆ€ {π•œ : Type u_1} [inst : RCLike π•œ] {g : π•œ β†’ π•œ} {u : π•œ}, gradient g u = (starRingEnd π•œ) (deriv g u)

theorem HasGradientAtFilter.hasDerivAtFilter' E1 #

βˆ€ {g : ℝ β†’ ℝ} {g' u : ℝ} {L' : Filter ℝ}, HasGradientAtFilter g g' u L' β†’ HasDerivAtFilter g g' (L' Γ—Λ’ pure u)

theorem HasDerivAtFilter.hasGradientAtFilter' E1 #

βˆ€ {g : ℝ β†’ ℝ} {g' u : ℝ} {L' : Filter ℝ}, HasDerivAtFilter g g' (L' Γ—Λ’ pure u) β†’ HasGradientAtFilter g g' u L'

theorem HasGradientAt.hasDerivAt' E1 #

βˆ€ {g : ℝ β†’ ℝ} {g' u : ℝ}, HasGradientAt g g' u β†’ HasDerivAt g g' u

theorem HasDerivAt.hasGradientAt' E1 #

βˆ€ {g : ℝ β†’ ℝ} {g' u : ℝ}, HasDerivAt g g' u β†’ HasGradientAt g g' u

theorem gradient_eq_deriv' E1 #

βˆ€ {g : ℝ β†’ ℝ} {u : ℝ}, gradient g u = deriv g u

theorem hasGradientAtFilter_iff_isLittleO E1 #

βˆ€ {π•œ : Type u_1} {F : Type u_2} [inst : RCLike π•œ] [inst_1 : NormedAddCommGroup F] [inst_2 : InnerProductSpace π•œ F]
  [inst_3 : CompleteSpace F] {f : F β†’ π•œ} {f' x : F} {L : Filter F},
  HasGradientAtFilter f f' x L ↔ (fun x' ↦ f x' - f x - inner π•œ f' (x' - x)) =o[L] fun x' ↦ x' - x

theorem hasGradientWithinAt_iff_isLittleO E1 #

βˆ€ {π•œ : Type u_1} {F : Type u_2} [inst : RCLike π•œ] [inst_1 : NormedAddCommGroup F] [inst_2 : InnerProductSpace π•œ F]
  [inst_3 : CompleteSpace F] {f : F β†’ π•œ} {f' x : F} {s : Set F},
  HasGradientWithinAt f f' s x ↔ (fun x' ↦ f x' - f x - inner π•œ f' (x' - x)) =o[nhdsWithin x s] fun x' ↦ x' - x

theorem hasGradientWithinAt_iff_tendsto E1 #

βˆ€ {π•œ : Type u_1} {F : Type u_2} [inst : RCLike π•œ] [inst_1 : NormedAddCommGroup F] [inst_2 : InnerProductSpace π•œ F]
  [inst_3 : CompleteSpace F] {f : F β†’ π•œ} {f' x : F} {s : Set F},
  HasGradientWithinAt f f' s x ↔
    Filter.Tendsto (fun x' ↦ β€–x' - x‖⁻¹ * β€–f x' - f x - inner π•œ f' (x' - x)β€–) (nhdsWithin x s) (nhds 0)

theorem hasGradientAt_iff_isLittleO E1 #

βˆ€ {π•œ : Type u_1} {F : Type u_2} [inst : RCLike π•œ] [inst_1 : NormedAddCommGroup F] [inst_2 : InnerProductSpace π•œ F]
  [inst_3 : CompleteSpace F] {f : F β†’ π•œ} {f' x : F},
  HasGradientAt f f' x ↔ (fun x' ↦ f x' - f x - inner π•œ f' (x' - x)) =o[nhds x] fun x' ↦ x' - x

theorem hasGradientAt_iff_tendsto E1 #

βˆ€ {π•œ : Type u_1} {F : Type u_2} [inst : RCLike π•œ] [inst_1 : NormedAddCommGroup F] [inst_2 : InnerProductSpace π•œ F]
  [inst_3 : CompleteSpace F] {f : F β†’ π•œ} {f' x : F},
  HasGradientAt f f' x ↔ Filter.Tendsto (fun x' ↦ β€–x' - x‖⁻¹ * β€–f x' - f x - inner π•œ f' (x' - x)β€–) (nhds x) (nhds 0)

theorem HasGradientAtFilter.isBigO_sub E1 #

βˆ€ {π•œ : Type u_1} {F : Type u_2} [inst : RCLike π•œ] [inst_1 : NormedAddCommGroup F] [inst_2 : InnerProductSpace π•œ F]
  [inst_3 : CompleteSpace F] {f : F β†’ π•œ} {f' x : F} {L : Filter F},
  HasGradientAtFilter f f' x L β†’ (fun x' ↦ f x' - f x) =O[L] fun x' ↦ x' - x

theorem hasGradientWithinAt_congr_set' E1 #

βˆ€ {π•œ : Type u_1} {F : Type u_2} [inst : RCLike π•œ] [inst_1 : NormedAddCommGroup F] [inst_2 : InnerProductSpace π•œ F]
  [inst_3 : CompleteSpace F] {f : F β†’ π•œ} {f' x : F} {s t : Set F} (y : F),
  s =αΆ [nhdsWithin x {y}ᢜ] t β†’ (HasGradientWithinAt f f' s x ↔ HasGradientWithinAt f f' t x)

theorem hasGradientWithinAt_congr_set E1 #

βˆ€ {π•œ : Type u_1} {F : Type u_2} [inst : RCLike π•œ] [inst_1 : NormedAddCommGroup F] [inst_2 : InnerProductSpace π•œ F]
  [inst_3 : CompleteSpace F] {f : F β†’ π•œ} {f' x : F} {s t : Set F},
  s =αΆ [nhds x] t β†’ (HasGradientWithinAt f f' s x ↔ HasGradientWithinAt f f' t x)

theorem hasGradientAt_iff_isLittleO_nhds_zero E1 #

βˆ€ {π•œ : Type u_1} {F : Type u_2} [inst : RCLike π•œ] [inst_1 : NormedAddCommGroup F] [inst_2 : InnerProductSpace π•œ F]
  [inst_3 : CompleteSpace F] {f : F β†’ π•œ} {f' x : F},
  HasGradientAt f f' x ↔ (fun h ↦ f (x + h) - f x - inner π•œ f' h) =o[nhds 0] fun h ↦ h

theorem HasGradientWithinAt.fderivWithin_apply E0 #

βˆ€ {π•œ : Type u_1} {F : Type u_2} [inst : RCLike π•œ] [inst_1 : NormedAddCommGroup F] [inst_2 : InnerProductSpace π•œ F]
  [inst_3 : CompleteSpace F] {f : F β†’ π•œ} {f' x y : F} {s : Set F},
  HasGradientWithinAt f f' s x β†’ UniqueDiffWithinAt π•œ s x β†’ (fderivWithin π•œ f s x) y = inner π•œ f' y

theorem HasGradientAt.fderiv_apply E0 #

βˆ€ {π•œ : Type u_1} {F : Type u_2} [inst : RCLike π•œ] [inst_1 : NormedAddCommGroup F] [inst_2 : InnerProductSpace π•œ F]
  [inst_3 : CompleteSpace F] {f : F β†’ π•œ} {f' x y : F}, HasGradientAt f f' x β†’ (fderiv π•œ f x) y = inner π•œ f' y

theorem inner_gradientWithin_left E0 #

βˆ€ {π•œ : Type u_1} {F : Type u_2} [inst : RCLike π•œ] [inst_1 : NormedAddCommGroup F] [inst_2 : InnerProductSpace π•œ F]
  [inst_3 : CompleteSpace F] {f : F β†’ π•œ} {x y : F} {s : Set F},
  inner π•œ (gradientWithin f s x) y = (fderivWithin π•œ f s x) y

theorem inner_gradient_left E0 #

βˆ€ {π•œ : Type u_1} {F : Type u_2} [inst : RCLike π•œ] [inst_1 : NormedAddCommGroup F] [inst_2 : InnerProductSpace π•œ F]
  [inst_3 : CompleteSpace F] {f : F β†’ π•œ} {x y : F}, inner π•œ (gradient f x) y = (fderiv π•œ f x) y

theorem inner_gradientWithin_right E0 #

βˆ€ {π•œ : Type u_1} {F : Type u_2} [inst : RCLike π•œ] [inst_1 : NormedAddCommGroup F] [inst_2 : InnerProductSpace π•œ F]
  [inst_3 : CompleteSpace F] {f : F β†’ π•œ} {x y : F} {s : Set F},
  inner π•œ x (gradientWithin f s y) = (starRingEnd π•œ) ((fderivWithin π•œ f s y) x)

theorem inner_gradient_right E0 #

βˆ€ {π•œ : Type u_1} {F : Type u_2} [inst : RCLike π•œ] [inst_1 : NormedAddCommGroup F] [inst_2 : InnerProductSpace π•œ F]
  [inst_3 : CompleteSpace F] {f : F β†’ π•œ} {x y : F}, inner π•œ x (gradient f y) = (starRingEnd π•œ) ((fderiv π•œ f y) x)

theorem Filter.EventuallyEq.hasGradientAtFilter_iff E0 #

βˆ€ {π•œ : Type u_1} {F : Type u_2} [inst : RCLike π•œ] [inst_1 : NormedAddCommGroup F] [inst_2 : InnerProductSpace π•œ F]
  [inst_3 : CompleteSpace F] {x : F} {L : Filter F} {fβ‚€ f₁ : F β†’ π•œ} {fβ‚€' f₁' : F},
  fβ‚€ =αΆ [L] f₁ β†’ fβ‚€ x = f₁ x β†’ fβ‚€' = f₁' β†’ (HasGradientAtFilter fβ‚€ fβ‚€' x L ↔ HasGradientAtFilter f₁ f₁' x L)

theorem HasGradientAtFilter.congr_of_eventuallyEq E1 #

βˆ€ {π•œ : Type u_1} {F : Type u_2} [inst : RCLike π•œ] [inst_1 : NormedAddCommGroup F] [inst_2 : InnerProductSpace π•œ F]
  [inst_3 : CompleteSpace F] {f : F β†’ π•œ} {f' x : F} {L : Filter F} {f₁ : F β†’ π•œ},
  HasGradientAtFilter f f' x L β†’ f₁ =αΆ [L] f β†’ f₁ x = f x β†’ HasGradientAtFilter f₁ f' x L

theorem HasGradientWithinAt.congr_mono E1 #

βˆ€ {π•œ : Type u_1} {F : Type u_2} [inst : RCLike π•œ] [inst_1 : NormedAddCommGroup F] [inst_2 : InnerProductSpace π•œ F]
  [inst_3 : CompleteSpace F] {f : F β†’ π•œ} {f' x : F} {s : Set F} {f₁ : F β†’ π•œ} {t : Set F},
  HasGradientWithinAt f f' s x β†’ (βˆ€ x ∈ t, f₁ x = f x) β†’ f₁ x = f x β†’ t βŠ† s β†’ HasGradientWithinAt f₁ f' t x

theorem HasGradientWithinAt.congr E1 #

βˆ€ {π•œ : Type u_1} {F : Type u_2} [inst : RCLike π•œ] [inst_1 : NormedAddCommGroup F] [inst_2 : InnerProductSpace π•œ F]
  [inst_3 : CompleteSpace F] {f : F β†’ π•œ} {f' x : F} {s : Set F} {f₁ : F β†’ π•œ},
  HasGradientWithinAt f f' s x β†’ (βˆ€ x ∈ s, f₁ x = f x) β†’ f₁ x = f x β†’ HasGradientWithinAt f₁ f' s x

theorem HasGradientWithinAt.congr_of_mem E1 #

βˆ€ {π•œ : Type u_1} {F : Type u_2} [inst : RCLike π•œ] [inst_1 : NormedAddCommGroup F] [inst_2 : InnerProductSpace π•œ F]
  [inst_3 : CompleteSpace F] {f : F β†’ π•œ} {f' x : F} {s : Set F} {f₁ : F β†’ π•œ},
  HasGradientWithinAt f f' s x β†’ (βˆ€ x ∈ s, f₁ x = f x) β†’ x ∈ s β†’ HasGradientWithinAt f₁ f' s x

theorem HasGradientWithinAt.congr_of_eventuallyEq E1 #

βˆ€ {π•œ : Type u_1} {F : Type u_2} [inst : RCLike π•œ] [inst_1 : NormedAddCommGroup F] [inst_2 : InnerProductSpace π•œ F]
  [inst_3 : CompleteSpace F] {f : F β†’ π•œ} {f' x : F} {s : Set F} {f₁ : F β†’ π•œ},
  HasGradientWithinAt f f' s x β†’ f₁ =αΆ [nhdsWithin x s] f β†’ f₁ x = f x β†’ HasGradientWithinAt f₁ f' s x

theorem HasGradientWithinAt.congr_of_eventuallyEq_of_mem E1 #

βˆ€ {π•œ : Type u_1} {F : Type u_2} [inst : RCLike π•œ] [inst_1 : NormedAddCommGroup F] [inst_2 : InnerProductSpace π•œ F]
  [inst_3 : CompleteSpace F] {f : F β†’ π•œ} {f' x : F} {s : Set F} {f₁ : F β†’ π•œ},
  HasGradientWithinAt f f' s x β†’ f₁ =αΆ [nhdsWithin x s] f β†’ x ∈ s β†’ HasGradientWithinAt f₁ f' s x

theorem HasGradientAt.congr_of_eventuallyEq E1 #

βˆ€ {π•œ : Type u_1} {F : Type u_2} [inst : RCLike π•œ] [inst_1 : NormedAddCommGroup F] [inst_2 : InnerProductSpace π•œ F]
  [inst_3 : CompleteSpace F] {f : F β†’ π•œ} {f' x : F} {f₁ : F β†’ π•œ},
  HasGradientAt f f' x β†’ f₁ =αΆ [nhds x] f β†’ HasGradientAt f₁ f' x

theorem Filter.EventuallyEq.gradient_eq E0 #

βˆ€ {π•œ : Type u_1} {F : Type u_2} [inst : RCLike π•œ] [inst_1 : NormedAddCommGroup F] [inst_2 : InnerProductSpace π•œ F]
  [inst_3 : CompleteSpace F] {f : F β†’ π•œ} {x : F} {f₁ : F β†’ π•œ}, f₁ =αΆ [nhds x] f β†’ gradient f₁ x = gradient f x

theorem Filter.EventuallyEq.gradient E3 #

βˆ€ {π•œ : Type u_1} {F : Type u_2} [inst : RCLike π•œ] [inst_1 : NormedAddCommGroup F] [inst_2 : InnerProductSpace π•œ F]
  [inst_3 : CompleteSpace F] {f : F β†’ π•œ} {x : F} {f₁ : F β†’ π•œ}, f₁ =αΆ [nhds x] f β†’ gradient f₁ =αΆ [nhds x] gradient f

theorem hasGradientAtFilter_const E1 #

βˆ€ {π•œ : Type u_1} {F : Type u_2} [inst : RCLike π•œ] [inst_1 : NormedAddCommGroup F] [inst_2 : InnerProductSpace π•œ F]
  [inst_3 : CompleteSpace F] (x : F) (L : Filter F) (c : π•œ), HasGradientAtFilter (fun x ↦ c) 0 x L

theorem hasGradientWithinAt_const E1 #

βˆ€ {π•œ : Type u_1} {F : Type u_2} [inst : RCLike π•œ] [inst_1 : NormedAddCommGroup F] [inst_2 : InnerProductSpace π•œ F]
  [inst_3 : CompleteSpace F] (x : F) (s : Set F) (c : π•œ), HasGradientWithinAt (fun x ↦ c) 0 s x

theorem hasGradientAt_const E1 #

βˆ€ {π•œ : Type u_1} {F : Type u_2} [inst : RCLike π•œ] [inst_1 : NormedAddCommGroup F] [inst_2 : InnerProductSpace π•œ F]
  [inst_3 : CompleteSpace F] (x : F) (c : π•œ), HasGradientAt (fun x ↦ c) 0 x

theorem gradient_fun_const E1 #

βˆ€ {π•œ : Type u_1} {F : Type u_2} [inst : RCLike π•œ] [inst_1 : NormedAddCommGroup F] [inst_2 : InnerProductSpace π•œ F]
  [inst_3 : CompleteSpace F] (x : F) (c : π•œ), gradient (fun x ↦ c) x = 0

theorem gradient_const E1 #

βˆ€ {π•œ : Type u_1} {F : Type u_2} [inst : RCLike π•œ] [inst_1 : NormedAddCommGroup F] [inst_2 : InnerProductSpace π•œ F]
  [inst_3 : CompleteSpace F] (x : F) (c : π•œ), gradient (Function.const F c) x = 0

theorem gradient_fun_const' E0 #

βˆ€ {π•œ : Type u_1} {F : Type u_2} [inst : RCLike π•œ] [inst_1 : NormedAddCommGroup F] [inst_2 : InnerProductSpace π•œ F]
  [inst_3 : CompleteSpace F] (c : π•œ), (gradient fun x ↦ c) = fun x ↦ 0

theorem gradient_const' E0 #

βˆ€ {π•œ : Type u_1} {F : Type u_2} [inst : RCLike π•œ] [inst_1 : NormedAddCommGroup F] [inst_2 : InnerProductSpace π•œ F]
  [inst_3 : CompleteSpace F] (c : π•œ), gradient (Function.const F c) = 0

theorem HasGradientAtFilter.tendsto_nhds E1 #

βˆ€ {π•œ : Type u_1} {F : Type u_2} [inst : RCLike π•œ] [inst_1 : NormedAddCommGroup F] [inst_2 : InnerProductSpace π•œ F]
  [inst_3 : CompleteSpace F] {f : F β†’ π•œ} {f' x : F} {L : Filter F},
  L ≀ nhds x β†’ HasGradientAtFilter f f' x L β†’ Filter.Tendsto f L (nhds (f x))

theorem HasGradientWithinAt.continuousWithinAt E1 #

βˆ€ {π•œ : Type u_1} {F : Type u_2} [inst : RCLike π•œ] [inst_1 : NormedAddCommGroup F] [inst_2 : InnerProductSpace π•œ F]
  [inst_3 : CompleteSpace F] {f : F β†’ π•œ} {f' x : F} {s : Set F}, HasGradientWithinAt f f' s x β†’ ContinuousWithinAt f s x

theorem HasGradientAt.continuousAt E1 #

βˆ€ {π•œ : Type u_1} {F : Type u_2} [inst : RCLike π•œ] [inst_1 : NormedAddCommGroup F] [inst_2 : InnerProductSpace π•œ F]
  [inst_3 : CompleteSpace F] {f : F β†’ π•œ} {f' x : F}, HasGradientAt f f' x β†’ ContinuousAt f x

theorem HasGradientAt.continuousOn E1 #

βˆ€ {π•œ : Type u_1} {F : Type u_2} [inst : RCLike π•œ] [inst_1 : NormedAddCommGroup F] [inst_2 : InnerProductSpace π•œ F]
  [inst_3 : CompleteSpace F] {f : F β†’ π•œ} {s : Set F} {f' : F β†’ F},
  (βˆ€ x ∈ s, HasGradientAt f (f' x) x) β†’ ContinuousOn f s