Documentation

LeanPool.Superdiffusion.Algsuperdiff.Section3.Provider.Corrector.DivergenceKernel

DivergenceKernel #

Ported from scottnarmstrong/Superdiffusion at 7f20476385d4af418f110303085ad0740c9eba46. Module imports, support namespace and local option directives adapted for Lean Pool.

Provider: an explicit divergence kernel for a difference of tensor densities #

Several smoothing arguments in Section 3 need to compare the same field averaged at two different scales, i.e. they need to control a difference of two product densities

χ_a(x) − χ_b(x) = ∏ᵢ a(xᵢ) − ∏ᵢ b(xᵢ),

where a and b are one-dimensional smooth compactly supported probability densities (in practice a = φ_ε and b = φ_R, the one-dimensional factors of Algsuperdiff/Section3/Provider/Corrector/MollifierScaling.lean's productDensity). What makes such a difference small when tested against a solenoidal or mean-zero field is that it is a divergence of a smooth compactly supported vector field.

This file writes that vector field down explicitly. With

G(t) = ∫_{-T}^{t} (a(s) − b(s)) ds (kernelPrimitive),

g_k(x) = G(x_k) · ∏_{i < k} b(x_i) · ∏_{i > k} a(x_i) (divKernel),

the fundamental theorem of calculus gives ∂_k g_k(x) = (a(x_k) − b(x_k)) · ∏_{i<k} b(x_i) · ∏_{i>k} a(x_i), because neither product involves the coordinate x_k. In terms of the interpolating densities

χ_m(x) = ∏_{i.val < m} b(x_i) · ∏_{m ≤ i.val} a(x_i) (mixedDensity),

this reads ∂_k g_k = χ_{k.val} − χ_{k.val + 1}, so the sum over k telescopes:

Σ_k ∂_k g_k = χ_0 − χ_d = χ_a − χ_b (coordDeriv_sum_divKernel).

Nothing deeper is used: no Newtonian potential, no Newton theorem, no elliptic solve and no Fourier analysis. The construction is elementary and completely explicit, and the divergence is phrased with Algsuperdiff/Section3/Provider/Corrector/SolenoidalStream.lean's coordDeriv, so it composes with the stream-tensor layer used there.

Support and smoothness are recorded as well: each component g_k is C^∞ (contDiff_divKernel_apply) and vanishes off the closed sup-norm ball of radius T (hasCompactSupport_divKernel_apply, tsupport_divKernel_apply_subset), provided a and b are unit-mass densities vanishing for T ≤ |s|. The concrete two-scale instance a = scaledBump hε, b = scaledBump hR, T = ε + R is recorded at the end of the file.

Disclosure. Nothing in this file realizes any source node. It is an elementary explicit construction offered as a local helper, and it claims no node status.

Coordinate derivatives along a single coordinate line #

Moving the kth coordinate of x to t is the same as translating x along the kth basis vector.

theorem Algsuperdiff.Section3.Provider.Corrector.coordDeriv_eq_of_hasDerivAt_update {d : ℕ} {F : HCPolySupport.Vec d → ℝ} {h : ℝ → ℝ} {x : HCPolySupport.Vec d} {k : Fin d} {c : ℝ} (hF : DifferentiableAt ℝ F x) (hupd : ∀ (t : ℝ), F (Function.update x k t) = h t) (hh : HasDerivAt h c (x k)) :
coordDeriv F k x = c

Coordinate derivatives are one-dimensional derivatives. If restricting a field differentiable at x to the kth coordinate line through x produces the one-dimensional function h, then the kth coordinate derivative of the field at x is the derivative of h at x k.

The index blocks of the telescoping #

The coordinates strictly below the level m.

Equations
Instances For

    The coordinates at or above the level m.

    Equations
    Instances For

      No coordinate lies below level 0.

      Every coordinate lies at or above level 0.

      Every coordinate lies below level d.

      No coordinate lies at or above level d.

      The level-k upper block is the level-(k+1) upper block with k restored.

      The level-(k+1) lower block is the level-k lower block with k adjoined.

      The one-dimensional primitive of the difference #

      The primitive G(t) = ∫_{-T}^{t}(a − b) of the difference of the two one-dimensional densities.

      Equations
      Instances For

        Fundamental theorem of calculus for the primitive: G' = a − b.

        theorem Algsuperdiff.Section3.Provider.Corrector.deriv_kernelPrimitive {a b : ℝ → ℝ} {T : ℝ} (ha : Continuous a) (hb : Continuous b) :
        deriv (kernelPrimitive a b T) = fun (t : ℝ) => a t - b t

        The primitive of a difference of smooth densities is smooth.

        A continuous function vanishing for T ≤ |s| is integrable: it is supported in the compact interval [-T, T].

        theorem Algsuperdiff.Section3.Provider.Corrector.kernelPrimitive_eq_zero_of_le {a b : ℝ → ℝ} {T : ℝ} (ha : Continuous a) (hb : Continuous b) (haT : ∀ (s : ℝ), T ≤ |s| → a s = 0) (hbT : ∀ (s : ℝ), T ≤ |s| → b s = 0) (ha1 : ∫ (s : ℝ), a s = 1) (hb1 : ∫ (s : ℝ), b s = 1) {t : ℝ} (ht : T ≤ |t|) :
        kernelPrimitive a b T t = 0

        The primitive vanishes outside (-T, T). To the left of -T the integrand vanishes identically; to the right of T the integral over [-T, T] is the full integral of a − b, which is 1 − 1 = 0.

        The tensor densities and the divergence kernel #

        The tensor-product density χ_a(x) = ∏ᵢ a(xᵢ).

        Equations
        Instances For

          The interpolating density at level m: the first m coordinates carry the density b, the remaining coordinates carry the density a.

          Equations
          • One or more equations did not get rendered due to their size.
          Instances For
            theorem Algsuperdiff.Section3.Provider.Corrector.mixedDensity_apply {d : ℕ} (a b : ℝ → ℝ) (m : ℕ) (x : HCPolySupport.Vec d) :
            mixedDensity a b m x = (∏ i ∈ idxBelow d m, b (x i)) * ∏ i ∈ idxAbove d m, a (x i)

            At level 0 the interpolating density is χ_a.

            At level d the interpolating density is χ_b.

            The divergence kernel. Its kth component carries the primitive G in the kth coordinate, the density b in the coordinates below k and the density a in the coordinates above k.

            Equations
            • One or more equations did not get rendered due to their size.
            Instances For
              theorem Algsuperdiff.Section3.Provider.Corrector.divKernel_apply {d : ℕ} (a b : ℝ → ℝ) (T : ℝ) (x : HCPolySupport.Vec d) (k : Fin d) :
              divKernel a b T x k = (kernelPrimitive a b T (x k) * ∏ i ∈ idxBelow d ↑k, b (x i)) * ∏ i ∈ idxAbove d (↑k + 1), a (x i)
              theorem Algsuperdiff.Section3.Provider.Corrector.contDiff_divKernel_apply {d : ℕ} {a b : ℝ → ℝ} {T : ℝ} (ha : ContDiff ℝ (↑⊤) a) (hb : ContDiff ℝ (↑⊤) b) (k : Fin d) :
              ContDiff ℝ ↑⊤ fun (x : HCPolySupport.Vec d) => divKernel a b T x k

              Every component of the divergence kernel is smooth.

              theorem Algsuperdiff.Section3.Provider.Corrector.divKernel_apply_eq_zero_of_le {d : ℕ} {a b : ℝ → ℝ} {T : ℝ} (ha : Continuous a) (hb : Continuous b) (haT : ∀ (s : ℝ), T ≤ |s| → a s = 0) (hbT : ∀ (s : ℝ), T ≤ |s| → b s = 0) (ha1 : ∫ (s : ℝ), a s = 1) (hb1 : ∫ (s : ℝ), b s = 1) (hT : 0 < T) {x : HCPolySupport.Vec d} (hx : T ≤ ‖x‖) (k : Fin d) :
              divKernel a b T x k = 0

              The divergence kernel vanishes outside the closed sup-norm ball of radius T: some coordinate of x then has modulus at least T, and whichever of the three factors sits at that coordinate vanishes.

              theorem Algsuperdiff.Section3.Provider.Corrector.hasCompactSupport_divKernel_apply {d : ℕ} {a b : ℝ → ℝ} {T : ℝ} (ha : Continuous a) (hb : Continuous b) (haT : ∀ (s : ℝ), T ≤ |s| → a s = 0) (hbT : ∀ (s : ℝ), T ≤ |s| → b s = 0) (ha1 : ∫ (s : ℝ), a s = 1) (hb1 : ∫ (s : ℝ), b s = 1) (hT : 0 < T) (k : Fin d) :

              Every component of the divergence kernel is compactly supported.

              The telescoping divergence identity #

              theorem Algsuperdiff.Section3.Provider.Corrector.coordDeriv_divKernel_apply {d : ℕ} {a b : ℝ → ℝ} {T : ℝ} (ha : ContDiff ℝ (↑⊤) a) (hb : ContDiff ℝ (↑⊤) b) (k : Fin d) (x : HCPolySupport.Vec d) :
              coordDeriv (fun (y : HCPolySupport.Vec d) => divKernel a b T y k) k x = ((a (x k) - b (x k)) * ∏ i ∈ idxBelow d ↑k, b (x i)) * ∏ i ∈ idxAbove d (↑k + 1), a (x i)

              The kth coordinate derivative of the kth component. Only the factor G(x_k) depends on the coordinate x_k, and G' = a − b.

              theorem Algsuperdiff.Section3.Provider.Corrector.coordDeriv_divKernel_apply_eq_sub {d : ℕ} {a b : ℝ → ℝ} {T : ℝ} (ha : ContDiff ℝ (↑⊤) a) (hb : ContDiff ℝ (↑⊤) b) (k : Fin d) (x : HCPolySupport.Vec d) :
              coordDeriv (fun (y : HCPolySupport.Vec d) => divKernel a b T y k) k x = mixedDensity a b (↑k) x - mixedDensity a b (↑k + 1) x

              The kth coordinate derivative is one telescoping step.

              theorem Algsuperdiff.Section3.Provider.Corrector.coordDeriv_sum_divKernel {d : ℕ} {a b : ℝ → ℝ} {T : ℝ} (ha : ContDiff ℝ (↑⊤) a) (hb : ContDiff ℝ (↑⊤) b) (x : HCPolySupport.Vec d) :
              ∑ k : Fin d, coordDeriv (fun (y : HCPolySupport.Vec d) => divKernel a b T y k) k x = tensorDensity a x - tensorDensity b x

              The divergence identity. The divergence of the explicit smooth compactly supported vector field divKernel a b T is the difference of the two tensor-product densities:

              Σ_k ∂_k g_k(x) = ∏ᵢ a(xᵢ) − ∏ᵢ b(xᵢ).

              Only smoothness of the two one-dimensional densities is used; support and unit mass enter nowhere.

              The two-scale instance #

              theorem Algsuperdiff.Section3.Provider.Corrector.contDiff_divKernel_scaledBump_apply {d : ℕ} {ε R : ℝ} (hε : 0 < ε) (hR : 0 < R) (k : Fin d) :
              ContDiff ℝ ↑⊤ fun (x : HCPolySupport.Vec d) => divKernel (scaledBump hε) (scaledBump hR) (ε + R) x k

              Every component of the two-scale divergence kernel is smooth.

              Every component of the two-scale divergence kernel is compactly supported in the closed sup-norm ball of radius ε + R.

              theorem Algsuperdiff.Section3.Provider.Corrector.coordDeriv_sum_divKernel_scaledBump {d : ℕ} {ε R : ℝ} (hε : 0 < ε) (hR : 0 < R) (x : HCPolySupport.Vec d) :
              ∑ k : Fin d, coordDeriv (fun (y : HCPolySupport.Vec d) => divKernel (scaledBump hε) (scaledBump hR) (ε + R) y k) k x = productDensity d hε x - productDensity d hR x

              The two-scale divergence identity. The difference of the product densities at the scales ε and R is the divergence of the explicit smooth vector field divKernel (scaledBump hε) (scaledBump hR) (ε + R), whose components are supported in the closed sup-norm ball of radius ε + R.