Documentation

Expdb.Mathlib.EulerMaclaurin

Arbitrary-order Euler--Maclaurin summation #

This file is adapted from Interval/EulerMaclaurin/Bernoulli.lean and Interval/EulerMaclaurin/EulerMaclaurin.lean in girving/interval at commit f4a3231fd735cdf6d5265864d9a9207744a7aca2, licensed under Apache-2.0.

The source has been modified, namespaced for Expdb, and updated for newer version of Mathlib.

Periodic Bernoulli functions #

noncomputable def Expdb.EulerMaclaurin.saw (s : ) (x : ) :

The scaled periodic Bernoulli function of order s.

Equations
Instances For

    Non-explicit bounds #

    noncomputable def Expdb.EulerMaclaurin.sawBound (s : ) :

    A uniform bound for the absolute value of saw s.

    Equations
    Instances For
      @[simp]

      The uniform bound for saw is nonnegative.

      Euler--Maclaurin on one unit interval #

      The full formula #

      theorem Expdb.EulerMaclaurin.sum_Icc_eq_integral_add {s : } {a : } {E : Type u_1} [NormedAddCommGroup E] [NormedSpace E] {f : E} {t : Set } {n : } [CompleteSpace E] (fc : ContDiffOn (s + 1) f t) (u : UniqueDiffOn t) (abt : Set.Icc (↑a) (a + n)t) :
      kFinset.Icc a (a + n), f k = ( (x : ) in a..a + n, f x) + 2⁻¹ (f a + f (a + n)) + mFinset.range s, (-1) ^ m saw (m + 2) 0 (iteratedDerivWithin (m + 1) f t (a + n) - iteratedDerivWithin (m + 1) f t a) + (-1) ^ s (x : ) in a..a + n, saw (s + 1) x iteratedDerivWithin (s + 1) f t x

      The arbitrary-order Euler--Maclaurin formula for a sum over consecutive integers.

      theorem Expdb.EulerMaclaurin.norm_sum_Icc_nat_sub_integral_le {E : Type u_1} [NormedAddCommGroup E] [NormedSpace E] {f : E} {t : Set } [CompleteSpace E] {a b s : } (hab : a b) (fc : ContDiffOn (s + 1) f t) (u : UniqueDiffOn t) (abt : Set.Icc a bt) {C₀ : } (hendpoint : xSet.Icc a b, f x C₀) (C : ) (hderiv : ∀ (k : ), 1 kk s + 1xSet.Icc a b, iteratedDerivWithin k f t x C k) :
      nFinset.Icc a b, f n - (x : ) in a..b, f x C₀ + mFinset.range s, |saw (m + 2) 0| * (2 * C (m + 1)) + sawBound (s + 1) * C (s + 1) * ↑(b - a)

      A convenient norm form of Euler--Maclaurin for natural endpoints. Uniform bounds on the function and its derivatives control the difference between the inclusive sum and its integral; the right-hand side records the endpoint, correction-term, and remainder contributions.