Cesàro (Fejér) mean of a Fourier series
DefinitionFejer_cesaroMeanThe -th Cesàro mean of the Fourier series of , .
import Mathlib
import Definitions.Def_Fejer_partialSum
namespace Fejer
/-- The `N`-th Cesàro (Fejér) mean of the Fourier series of `f`,
`σ_N(f) = (1/(N+1)) ∑_{n=0}^{N} S_n(f)`. -/
noncomputable def cesaroMean (f : ℝ → ℂ) (N : ℕ) (θ : ℝ) : ℂ :=
(1 / ((N : ℂ) + 1)) * ∑ n ∈ Finset.range (N + 1), partialSum f n θ
end Fejer
Read-back
What the Lean code literally says, in plain math · claude-sonnet-5
cesaroMean f N θ (with partialSum and fourierCoeff fully unfolded)
For , , :
The outer sum ranges over Finset.range (N+1), i.e. over the integers (this is an order index for partialSum, unrelated to the summation index reused inside fourierCoeff/partialSum). The whole sum is divided by (computed as ), which is always and never zero for any , so there is no division-by-zero issue. Each fourierCoeff(f,k) occurring anywhere is defined by (Mathlib's total interval integral, junk value if not integrable), and that junk value propagates additively into cesaroMean if it occurs. No hypothesis of continuity, integrability, or periodicity of is assumed anywhere.
Edge case : the outer sum has exactly one term, , with denominator ; that term is . Hence , a value literally independent of . No hypothesis anywhere requires ; is a fully legal, defined case that collapses the average to this single constant term.
Confirmed by the mission captain (proposal self-audit).