Documentation

Mathlib.Analysis.Fourier.ZMod

Fourier theory on ZMod N #

Basic definitions and properties of the discrete Fourier transform for functions on ZMod N (taking values in an arbitrary -vector space).

Main definitions and results #

noncomputable def ZMod.dft {N : } [NeZero N] {E : Type u_1} [AddCommGroup E] [Module E] :
(ZMod NE) ≃ₗ[] ZMod NE

The discrete Fourier transform on ℤ / N ℤ (with the counting measure), bundled as a linear equivalence. Denoted as 𝓕 within the ZMod namespace.

Equations

The discrete Fourier transform on ℤ / N ℤ (with the counting measure), bundled as a linear equivalence. Denoted as 𝓕 within the ZMod namespace.

Equations

The inverse Fourier transform on ZMod N.

Equations
theorem ZMod.dft_apply {N : } [NeZero N] {E : Type u_1} [AddCommGroup E] [Module E] (Φ : ZMod NE) (k : ZMod N) :
dft Φ k = j : ZMod N, stdAddChar (-(j * k)) Φ j
theorem ZMod.dft_def {N : } [NeZero N] {E : Type u_1} [AddCommGroup E] [Module E] (Φ : ZMod NE) :
dft Φ = fun (k : ZMod N) => j : ZMod N, stdAddChar (-(j * k)) Φ j
theorem ZMod.invDFT_apply {N : } [NeZero N] {E : Type u_1} [AddCommGroup E] [Module E] (Ψ : ZMod NE) (k : ZMod N) :
dft.symm Ψ k = (↑N)⁻¹ j : ZMod N, stdAddChar (j * k) Ψ j
theorem ZMod.invDFT_def {N : } [NeZero N] {E : Type u_1} [AddCommGroup E] [Module E] (Ψ : ZMod NE) :
dft.symm Ψ = fun (k : ZMod N) => (↑N)⁻¹ j : ZMod N, stdAddChar (j * k) Ψ j
theorem ZMod.invDFT_apply' {N : } [NeZero N] {E : Type u_1} [AddCommGroup E] [Module E] (Ψ : ZMod NE) (k : ZMod N) :
dft.symm Ψ k = (↑N)⁻¹ dft Ψ (-k)
theorem ZMod.invDFT_def' {N : } [NeZero N] {E : Type u_1} [AddCommGroup E] [Module E] (Ψ : ZMod NE) :
dft.symm Ψ = fun (k : ZMod N) => (↑N)⁻¹ dft Ψ (-k)
theorem ZMod.dft_apply_zero {N : } [NeZero N] {E : Type u_1} [AddCommGroup E] [Module E] (Φ : ZMod NE) :
dft Φ 0 = j : ZMod N, Φ j

The discrete Fourier transform agrees with the general one (assuming the target space is a complete normed space).

Compatibility with scalar multiplication #

These lemmas are more general than LinearEquiv.map_mul etc, since they allow any scalars that commute with the -action, rather than just itself.

theorem ZMod.dft_const_smul {N : } [NeZero N] {E : Type u_1} [AddCommGroup E] [Module E] {R : Type u_2} [DistribSMul R E] [SMulCommClass R E] (r : R) (Φ : ZMod NE) :
dft (r Φ) = r dft Φ
theorem ZMod.dft_smul_const {N : } [NeZero N] {E : Type u_1} [AddCommGroup E] [Module E] {R : Type u_2} [Ring R] [Module R] [Module R E] [IsScalarTower R E] (Φ : ZMod NR) (e : E) :
(dft fun (j : ZMod N) => Φ j e) = fun (k : ZMod N) => dft Φ k e
theorem ZMod.dft_const_mul {N : } [NeZero N] {R : Type u_2} [Ring R] [Algebra R] (r : R) (Φ : ZMod NR) :
(dft fun (j : ZMod N) => r * Φ j) = fun (k : ZMod N) => r * dft Φ k
theorem ZMod.dft_mul_const {N : } [NeZero N] {R : Type u_2} [Ring R] [Algebra R] (Φ : ZMod NR) (r : R) :
(dft fun (j : ZMod N) => Φ j * r) = fun (k : ZMod N) => dft Φ k * r
theorem ZMod.dft_comp_neg {N : } [NeZero N] {E : Type u_1} [AddCommGroup E] [Module E] (Φ : ZMod NE) :
(dft fun (j : ZMod N) => Φ (-j)) = fun (k : ZMod N) => dft Φ (-k)
theorem ZMod.dft_dft {N : } [NeZero N] {E : Type u_1} [AddCommGroup E] [Module E] (Φ : ZMod NE) :
dft (dft Φ) = fun (j : ZMod N) => N Φ (-j)

Fourier inversion formula, discrete case.

theorem ZMod.dft_comp_unitMul {N : } [NeZero N] {E : Type u_1} [AddCommGroup E] [Module E] (Φ : ZMod NE) (u : (ZMod N)ˣ) (k : ZMod N) :
dft (fun (j : ZMod N) => Φ (u * j)) k = dft Φ (u⁻¹ * k)
theorem ZMod.dft_even_iff {N : } [NeZero N] {Φ : ZMod N} :

The discrete Fourier transform of Φ is even if and only if Φ itself is.

theorem ZMod.dft_odd_iff {N : } [NeZero N] {Φ : ZMod N} :

The discrete Fourier transform of Φ is odd if and only if Φ itself is.

For a primitive Dirichlet character χ, the Fourier transform of χ is a constant multiple of χ⁻¹ (and the constant is essentially the Gauss sum).