mathlib3 documentation

analysis.calculus.iterated_deriv

One-dimensional iterated derivatives #

THIS FILE IS SYNCHRONIZED WITH MATHLIB4. Any changes to this file require a corresponding PR to mathlib4.

We define the n-th derivative of a function f : π•œ β†’ F as a function iterated_deriv n f : π•œ β†’ F, as well as a version on domains iterated_deriv_within n f s : π•œ β†’ F, and prove their basic properties.

Main definitions and results #

Let π•œ be a nontrivially normed field, and F a normed vector space over π•œ. Let f : π•œ β†’ F.

Implementation details #

The results are deduced from the corresponding results for the more general (multilinear) iterated FrΓ©chet derivative. For this, we write iterated_deriv n f as the composition of iterated_fderiv π•œ n f and a continuous linear equiv. As continuous linear equivs respect differentiability and commute with differentiation, this makes it possible to prove readily that the derivative of the n-th derivative is the n+1-th derivative in iterated_deriv_within_succ, by translating the corresponding result iterated_fderiv_within_succ_apply_left for the iterated FrΓ©chet derivative.

noncomputable def iterated_deriv {π•œ : Type u_1} [nontrivially_normed_field π•œ] {F : Type u_2} [normed_add_comm_group F] [normed_space π•œ F] (n : β„•) (f : π•œ β†’ F) (x : π•œ) :
F

The n-th iterated derivative of a function from π•œ to F, as a function from π•œ to F.

Equations
noncomputable def iterated_deriv_within {π•œ : Type u_1} [nontrivially_normed_field π•œ] {F : Type u_2} [normed_add_comm_group F] [normed_space π•œ F] (n : β„•) (f : π•œ β†’ F) (s : set π•œ) (x : π•œ) :
F

The n-th iterated derivative of a function from π•œ to F within a set s, as a function from π•œ to F.

Equations
theorem iterated_deriv_within_univ {π•œ : Type u_1} [nontrivially_normed_field π•œ] {F : Type u_2} [normed_add_comm_group F] [normed_space π•œ F] {n : β„•} {f : π•œ β†’ F} :

Properties of the iterated derivative within a set #

theorem iterated_deriv_within_eq_iterated_fderiv_within {π•œ : Type u_1} [nontrivially_normed_field π•œ] {F : Type u_2} [normed_add_comm_group F] [normed_space π•œ F] {n : β„•} {f : π•œ β†’ F} {s : set π•œ} {x : π•œ} :
iterated_deriv_within n f s x = ⇑(iterated_fderiv_within π•œ n f s x) (Ξ» (i : fin n), 1)
theorem iterated_deriv_within_eq_equiv_comp {π•œ : Type u_1} [nontrivially_normed_field π•œ] {F : Type u_2} [normed_add_comm_group F] [normed_space π•œ F] {n : β„•} {f : π•œ β†’ F} {s : set π•œ} :

Write the iterated derivative as the composition of a continuous linear equiv and the iterated FrΓ©chet derivative

theorem iterated_fderiv_within_eq_equiv_comp {π•œ : Type u_1} [nontrivially_normed_field π•œ] {F : Type u_2} [normed_add_comm_group F] [normed_space π•œ F] {n : β„•} {f : π•œ β†’ F} {s : set π•œ} :

Write the iterated FrΓ©chet derivative as the composition of a continuous linear equiv and the iterated derivative.

theorem iterated_fderiv_within_apply_eq_iterated_deriv_within_mul_prod {π•œ : Type u_1} [nontrivially_normed_field π•œ] {F : Type u_2} [normed_add_comm_group F] [normed_space π•œ F] {n : β„•} {f : π•œ β†’ F} {s : set π•œ} {x : π•œ} {m : fin n β†’ π•œ} :
⇑(iterated_fderiv_within π•œ n f s x) m = finset.univ.prod (Ξ» (i : fin n), m i) β€’ iterated_deriv_within n f s x

The n-th FrΓ©chet derivative applied to a vector (m 0, ..., m (n-1)) is the derivative multiplied by the product of the m is.

theorem norm_iterated_fderiv_within_eq_norm_iterated_deriv_within {π•œ : Type u_1} [nontrivially_normed_field π•œ] {F : Type u_2} [normed_add_comm_group F] [normed_space π•œ F] {n : β„•} {f : π•œ β†’ F} {s : set π•œ} {x : π•œ} :
@[simp]
theorem iterated_deriv_within_zero {π•œ : Type u_1} [nontrivially_normed_field π•œ] {F : Type u_2} [normed_add_comm_group F] [normed_space π•œ F] {f : π•œ β†’ F} {s : set π•œ} :
@[simp]
theorem iterated_deriv_within_one {π•œ : Type u_1} [nontrivially_normed_field π•œ] {F : Type u_2} [normed_add_comm_group F] [normed_space π•œ F] {f : π•œ β†’ F} {s : set π•œ} {x : π•œ} (h : unique_diff_within_at π•œ s x) :
theorem cont_diff_on_of_continuous_on_differentiable_on_deriv {π•œ : Type u_1} [nontrivially_normed_field π•œ] {F : Type u_2} [normed_add_comm_group F] [normed_space π•œ F] {f : π•œ β†’ F} {s : set π•œ} {n : β„•βˆž} (Hcont : βˆ€ (m : β„•), ↑m ≀ n β†’ continuous_on (Ξ» (x : π•œ), iterated_deriv_within m f s x) s) (Hdiff : βˆ€ (m : β„•), ↑m < n β†’ differentiable_on π•œ (Ξ» (x : π•œ), iterated_deriv_within m f s x) s) :
cont_diff_on π•œ n f s

If the first n derivatives within a set of a function are continuous, and its first n-1 derivatives are differentiable, then the function is C^n. This is not an equivalence in general, but this is an equivalence when the set has unique derivatives, see cont_diff_on_iff_continuous_on_differentiable_on_deriv.

theorem cont_diff_on_of_differentiable_on_deriv {π•œ : Type u_1} [nontrivially_normed_field π•œ] {F : Type u_2} [normed_add_comm_group F] [normed_space π•œ F] {f : π•œ β†’ F} {s : set π•œ} {n : β„•βˆž} (h : βˆ€ (m : β„•), ↑m ≀ n β†’ differentiable_on π•œ (iterated_deriv_within m f s) s) :
cont_diff_on π•œ n f s

To check that a function is n times continuously differentiable, it suffices to check that its first n derivatives are differentiable. This is slightly too strong as the condition we require on the n-th derivative is differentiability instead of continuity, but it has the advantage of avoiding the discussion of continuity in the proof (and for n = ∞ this is optimal).

theorem cont_diff_on.continuous_on_iterated_deriv_within {π•œ : Type u_1} [nontrivially_normed_field π•œ] {F : Type u_2} [normed_add_comm_group F] [normed_space π•œ F] {f : π•œ β†’ F} {s : set π•œ} {n : β„•βˆž} {m : β„•} (h : cont_diff_on π•œ n f s) (hmn : ↑m ≀ n) (hs : unique_diff_on π•œ s) :

On a set with unique derivatives, a C^n function has derivatives up to n which are continuous.

theorem cont_diff_within_at.differentiable_within_at_iterated_deriv_within {π•œ : Type u_1} [nontrivially_normed_field π•œ] {F : Type u_2} [normed_add_comm_group F] [normed_space π•œ F] {f : π•œ β†’ F} {s : set π•œ} {x : π•œ} {n : β„•βˆž} {m : β„•} (h : cont_diff_within_at π•œ n f s x) (hmn : ↑m < n) (hs : unique_diff_on π•œ (has_insert.insert x s)) :
theorem cont_diff_on.differentiable_on_iterated_deriv_within {π•œ : Type u_1} [nontrivially_normed_field π•œ] {F : Type u_2} [normed_add_comm_group F] [normed_space π•œ F] {f : π•œ β†’ F} {s : set π•œ} {n : β„•βˆž} {m : β„•} (h : cont_diff_on π•œ n f s) (hmn : ↑m < n) (hs : unique_diff_on π•œ s) :

On a set with unique derivatives, a C^n function has derivatives less than n which are differentiable.

theorem cont_diff_on_iff_continuous_on_differentiable_on_deriv {π•œ : Type u_1} [nontrivially_normed_field π•œ] {F : Type u_2} [normed_add_comm_group F] [normed_space π•œ F] {f : π•œ β†’ F} {s : set π•œ} {n : β„•βˆž} (hs : unique_diff_on π•œ s) :

The property of being C^n, initially defined in terms of the FrΓ©chet derivative, can be reformulated in terms of the one-dimensional derivative on sets with unique derivatives.

theorem iterated_deriv_within_succ {π•œ : Type u_1} [nontrivially_normed_field π•œ] {F : Type u_2} [normed_add_comm_group F] [normed_space π•œ F] {n : β„•} {f : π•œ β†’ F} {s : set π•œ} {x : π•œ} (hxs : unique_diff_within_at π•œ s x) :

The n+1-th iterated derivative within a set with unique derivatives can be obtained by differentiating the n-th iterated derivative.

theorem iterated_deriv_within_eq_iterate {π•œ : Type u_1} [nontrivially_normed_field π•œ] {F : Type u_2} [normed_add_comm_group F] [normed_space π•œ F] {n : β„•} {f : π•œ β†’ F} {s : set π•œ} {x : π•œ} (hs : unique_diff_on π•œ s) (hx : x ∈ s) :
iterated_deriv_within n f s x = (Ξ» (g : π•œ β†’ F), deriv_within g s)^[n] f x

The n-th iterated derivative within a set with unique derivatives can be obtained by iterating n times the differentiation operation.

theorem iterated_deriv_within_succ' {π•œ : Type u_1} [nontrivially_normed_field π•œ] {F : Type u_2} [normed_add_comm_group F] [normed_space π•œ F] {n : β„•} {f : π•œ β†’ F} {s : set π•œ} {x : π•œ} (hxs : unique_diff_on π•œ s) (hx : x ∈ s) :

The n+1-th iterated derivative within a set with unique derivatives can be obtained by taking the n-th derivative of the derivative.

Properties of the iterated derivative on the whole space #

theorem iterated_deriv_eq_iterated_fderiv {π•œ : Type u_1} [nontrivially_normed_field π•œ] {F : Type u_2} [normed_add_comm_group F] [normed_space π•œ F] {n : β„•} {f : π•œ β†’ F} {x : π•œ} :
iterated_deriv n f x = ⇑(iterated_fderiv π•œ n f x) (Ξ» (i : fin n), 1)
theorem iterated_deriv_eq_equiv_comp {π•œ : Type u_1} [nontrivially_normed_field π•œ] {F : Type u_2} [normed_add_comm_group F] [normed_space π•œ F] {n : β„•} {f : π•œ β†’ F} :

Write the iterated derivative as the composition of a continuous linear equiv and the iterated FrΓ©chet derivative

theorem iterated_fderiv_eq_equiv_comp {π•œ : Type u_1} [nontrivially_normed_field π•œ] {F : Type u_2} [normed_add_comm_group F] [normed_space π•œ F] {n : β„•} {f : π•œ β†’ F} :

Write the iterated FrΓ©chet derivative as the composition of a continuous linear equiv and the iterated derivative.

theorem iterated_fderiv_apply_eq_iterated_deriv_mul_prod {π•œ : Type u_1} [nontrivially_normed_field π•œ] {F : Type u_2} [normed_add_comm_group F] [normed_space π•œ F] {n : β„•} {f : π•œ β†’ F} {x : π•œ} {m : fin n β†’ π•œ} :
⇑(iterated_fderiv π•œ n f x) m = finset.univ.prod (Ξ» (i : fin n), m i) β€’ iterated_deriv n f x

The n-th FrΓ©chet derivative applied to a vector (m 0, ..., m (n-1)) is the derivative multiplied by the product of the m is.

theorem norm_iterated_fderiv_eq_norm_iterated_deriv {π•œ : Type u_1} [nontrivially_normed_field π•œ] {F : Type u_2} [normed_add_comm_group F] [normed_space π•œ F] {n : β„•} {f : π•œ β†’ F} {x : π•œ} :
@[simp]
theorem iterated_deriv_zero {π•œ : Type u_1} [nontrivially_normed_field π•œ] {F : Type u_2} [normed_add_comm_group F] [normed_space π•œ F] {f : π•œ β†’ F} :
@[simp]
theorem iterated_deriv_one {π•œ : Type u_1} [nontrivially_normed_field π•œ] {F : Type u_2} [normed_add_comm_group F] [normed_space π•œ F] {f : π•œ β†’ F} :
theorem cont_diff_iff_iterated_deriv {π•œ : Type u_1} [nontrivially_normed_field π•œ] {F : Type u_2} [normed_add_comm_group F] [normed_space π•œ F] {f : π•œ β†’ F} {n : β„•βˆž} :

The property of being C^n, initially defined in terms of the FrΓ©chet derivative, can be reformulated in terms of the one-dimensional derivative.

theorem cont_diff_of_differentiable_iterated_deriv {π•œ : Type u_1} [nontrivially_normed_field π•œ] {F : Type u_2} [normed_add_comm_group F] [normed_space π•œ F] {f : π•œ β†’ F} {n : β„•βˆž} (h : βˆ€ (m : β„•), ↑m ≀ n β†’ differentiable π•œ (iterated_deriv m f)) :
cont_diff π•œ n f

To check that a function is n times continuously differentiable, it suffices to check that its first n derivatives are differentiable. This is slightly too strong as the condition we require on the n-th derivative is differentiability instead of continuity, but it has the advantage of avoiding the discussion of continuity in the proof (and for n = ∞ this is optimal).

theorem cont_diff.continuous_iterated_deriv {π•œ : Type u_1} [nontrivially_normed_field π•œ] {F : Type u_2} [normed_add_comm_group F] [normed_space π•œ F] {f : π•œ β†’ F} {n : β„•βˆž} (m : β„•) (h : cont_diff π•œ n f) (hmn : ↑m ≀ n) :
theorem cont_diff.differentiable_iterated_deriv {π•œ : Type u_1} [nontrivially_normed_field π•œ] {F : Type u_2} [normed_add_comm_group F] [normed_space π•œ F] {f : π•œ β†’ F} {n : β„•βˆž} (m : β„•) (h : cont_diff π•œ n f) (hmn : ↑m < n) :
theorem iterated_deriv_succ {π•œ : Type u_1} [nontrivially_normed_field π•œ] {F : Type u_2} [normed_add_comm_group F] [normed_space π•œ F] {n : β„•} {f : π•œ β†’ F} :

The n+1-th iterated derivative can be obtained by differentiating the n-th iterated derivative.

theorem iterated_deriv_eq_iterate {π•œ : Type u_1} [nontrivially_normed_field π•œ] {F : Type u_2} [normed_add_comm_group F] [normed_space π•œ F] {n : β„•} {f : π•œ β†’ F} :

The n-th iterated derivative can be obtained by iterating n times the differentiation operation.

theorem iterated_deriv_succ' {π•œ : Type u_1} [nontrivially_normed_field π•œ] {F : Type u_2} [normed_add_comm_group F] [normed_space π•œ F] {n : β„•} {f : π•œ β†’ F} :

The n+1-th iterated derivative can be obtained by taking the n-th derivative of the derivative.