energy_filter_step_sum_integral
For a finite set of integers, real weights w, and positive h, the integral of the sum of w(i) times the indicator of [i/h,(i+1)/h) equals the sum of the weights divided by h.
Statement
theorem energy_filter_step_sum_integral (s : Finset ℤ) (w : ℤ → ℝ) (h : ℝ) (hh : 0 < h) : (∫ x : ℝ, ∑ i ∈ s, (Set.Ico ((i:ℝ)/h) (((i:ℝ)+1)/h)).indicator (fun _ : ℝ => w i) x) = (∑ i ∈ s, w i) / h
- Source
- OP-892: centered binomial fourth-mass asymptotic via rescaled step functions and dominated convergence.
- Verified
- 14 Nov 2026
- Axioms
Classical.choiceQuot.soundpropext- Used by 3
- energy_filter_centered_binomial_fourth_step_integralFor k≥1, the integral of the fourth power of the centered binomial weight at floor(√k x) equals the finite sum of the fourth powers over…
- energy_filter_step_sum_eq_floorIf a real function on the integers vanishes outside a finite set, then the corresponding finite sum of interval indicators of width 1/h at…
- energy_filter_centered_kernel_step_integralFor k≥1 and integer shifts u,v,w, the integral of the four shifted binomial weights at floor(√k x) equals their integer sum divided by √k.
The proof, explained
The proof exchanges the integral and the finite sum, which is justified by showing that each indicator summand is integrable. It then evaluates each integral individually: since the interval $[i/h, (i+1)/h)$ has length $1/h$, integrating the constant weight $w(i)$ over it produces $w(i)/h$. Finally, distributing the division by $h$ across the sum matches the two sides term by term.
For each integer $i$, the summand $x \mapsto \mathbf{1}_{[i/h, (i+1)/h)}(x) w(i)$ is integrable on $\mathbb{R}$.
An indicator function of an integrable function on a measurable set is integrable on the whole space (`MeasureTheory.IntegrableOn.integrable_indicator`). The half-open interval $[i/h, (i+1)/h)$ is measurable (`measurableSet_Ico`), and any constant function is integrable on a set of finite measure (`MeasureTheory.integrableOn_const`), which applies here because bounded intervals have finite Lebesgue measure (`Real.volume_Ico`).
uses
MeasureTheory.IntegrableOn.integrable_indicator,measurableSet_Ico,MeasureTheory.integrableOn_const,Real.volume_Icohave hf (i : ℤ) : MeasureTheory.Integrable (fun x : ℝ => (Set.Ico ((i:ℝ)/h) (((i:ℝ)+1)/h)).indicator (fun _ : ℝ => w i) x) := by apply MeasureTheory.IntegrableOn.integrable_indicator _ measurableSet_Ico exact MeasureTheory.integrableOn_const (by simp [Real.volume_Ico])
The integral of the sum equals the sum of the integrals, and dividing by $h$ distributes across the sum.
Because each summand is integrable, the integral and the finite sum can be interchanged (`MeasureTheory.integral_finsetSum`). On the right-hand side, dividing the sum by $h$ distributes across each summand (`Finset.sum_div`).
uses
MeasureTheory.integral_finsetSum,Finset.sum_divrw [MeasureTheory.integral_finsetSum s (fun i hi => hf i), Finset.sum_div]
It suffices to show that for each $i \in s$, the integral of the $i$-th term equals $w(i)/h$.
By sum congruence (`Finset.sum_congr`), two finite sums over the same set agree if their summands agree for each index $i \in s$.
uses
Finset.sum_congrapply Finset.sum_congr rfl intro i hi
The interval endpoints satisfy $i/h \le (i+1)/h$.
Since $h > 0$, dividing by $h$ preserves the inequality $i \le i + 1$.
have hab : (i:ℝ)/h ≤ ((i:ℝ)+1)/h := by gcongr; linarith
For each $i \in s$, the integral of the indicator term equals $w(i)/h$.
The integral of the constant $w(i)$ over the measurable interval $[i/h, (i+1)/h)$ is the product of its Lebesgue measure and $w(i)$ (`MeasureTheory.integral_indicator_const`, `measurableSet_Ico`). Since $i/h \le (i+1)/h$, this measure is $((i+1)/h - i/h)$ (`Real.volume_real_Ico_of_le`). Replacing scalar multiplication with real multiplication (`smul_eq_mul`), clearing denominators (`field_simp`), and simplifying the polynomial expression (`ring`) reduces $((i+1)/h - i/h) \cdot w(i)$ to $w(i)/h$.
uses
MeasureTheory.integral_indicator_const,measurableSet_Ico,Real.volume_real_Ico_of_le,smul_eq_mulrw [MeasureTheory.integral_indicator_const _ measurableSet_Ico, Real.volume_real_Ico_of_le hab] simp only [smul_eq_mul] field_simp ring
MeasureTheory.IntegrableOn.integrable_indicator- If a function is integrable on a measurable set $s$, then its indicator function on $s$ is integrable on the whole space.
MeasureTheory.integral_indicator_const- The integral of a constant $c$ on a measurable set $s$ is the real measure of $s$ multiplied by $c$.
MeasureTheory.integrableOn_const- A constant function is integrable on any set of finite measure.
MeasureTheory.integral_finsetSum- The integral of a finite sum of integrable functions equals the sum of their integrals.
measurableSet_Ico- A half-open interval $[a, b)$ is a measurable set.
Real.volume_Ico- The Lebesgue measure of a half-open interval $[a, b)$ is $\max(b - a, 0)$ as an extended non-negative real.
Real.volume_real_Ico_of_le- If $a \le b$, the real-valued Lebesgue measure of $[a, b)$ is $b - a$.
Finset.sum_div- Dividing a finite sum by a scalar distributes across each term of the sum: $(\sum_{i \in s} f(i)) / a = \sum_{i \in s} (f(i) / a)$.
Finset.sum_congr- Two finite sums over the same index set are equal if their summands are equal at every index.
smul_eq_mul- Scalar multiplication of real numbers is standard real multiplication: $a \bullet b = a * b$.
Written by a model (gemini-3.8-flash) from the Lean proof and the goal states Lean reported at each step. Lean verified the proof; this explanation is a reading aid and is not itself machine-checked.
Lean source view module on GitHub
Choose a tactic — a marked line — to see the goals Lean had before and after it, as in Lean’s infoview. Step with ← → or j k.
theorem energy_filter_step_sum_integral (s : Finset ℤ) (w : ℤ → ℝ) (h : ℝ) (hh : 0 < h) : (∫ x : ℝ, ∑ i ∈ s, (Set.Ico ((i:ℝ)/h) (((i:ℝ)+1)/h)).indicator (fun _ : ℝ => w i) x) = (∑ i ∈ s, w i) / h := by have hf (i : ℤ) : MeasureTheory.Integrable (fun x : ℝ => (Set.Ico ((i:ℝ)/h) (((i:ℝ)+1)/h)).indicator (fun _ : ℝ => w i) x) := by apply MeasureTheory.IntegrableOn.integrable_indicator _ measurableSet_Ico exact MeasureTheory.integrableOn_const (by simp [Real.volume_Ico]) rw [MeasureTheory.integral_finsetSum s (fun i hi => hf i), Finset.sum_div] apply Finset.sum_congr rfl intro i hi have hab : (i:ℝ)/h ≤ ((i:ℝ)+1)/h := by gcongr; linarith rw [MeasureTheory.integral_indicator_const _ measurableSet_Ico, Real.volume_real_Ico_of_le hab] simp only [smul_eq_mul] field_simp ring