AFTD Auto-Formalizing Theoretical Domains

op861_fourier_cube_identity

theoremverified

For a complex-valued function on a finite abelian group, the sum over all additive characters of the cube of its Fourier sum equals the order of the group times the sum of f(x)f(y)f(−x−y) over ordered pairs x,y.

Statement

theorem op861_fourier_cube_identity (G : Type*) [AddCommGroup G] [Fintype G] [DecidableEq G] (f : G → ℂ) :
    (∑ χ : AddChar G ℂ, (∑ x : G, f x * χ x) ^ 3) =
      (Fintype.card G : ℂ) * ∑ x : G, ∑ y : G, f x * f y * f (-x-y)
Source
Finite character orthogonality, used for op861_ternary_crossing_pairs_dense.
Verified
18 Nov 2026
Axioms
Classical.choiceQuot.soundpropext
Used by 2
  • op861_order_three_zero_sum_upperIn a finite abelian group where three times every element is zero, for every finite subset S, three times the group order times the number…
  • op861_ternary_crossing_pairs_denseFor every positive d and every subset S of the d-dimensional ternary vector space with twice its size equal to 3^d+1, there are at least…

The proof, explained

The proof expands the cube of the Fourier sum for each character into a triple sum over group elements x, y, z ∈ G, using the homomorphism property χ(x)χ(y)χ(z) = χ(x+y+z). Interchanging the order of summation brings the sum over all additive characters χ to the innermost position. By character orthogonality, this inner sum equals |G| when x+y+z = 0 and vanishes otherwise. Collapsing the sum over z to the unique non-zero term z = -x-y yields |G| times the sum of f(x)f(y)f(-x-y) over all pairs x, y.

  1. The sum over all characters of the cubed Fourier sum expands to a quadruple sum: ∑_χ (∑_x f(x)χ(x))³ = ∑_χ ∑_x ∑_y ∑_z f(x)f(y)f(z) χ(x+y+z).

    We enable classical logic and expand the cube (∑_x f(x)χ(x))³ into a triple sum over x, y, z ∈ G using distributivity (pow_succ, pow_zero, Finset.sum_mul, Finset.mul_sum). For each additive character χ, the homomorphism property χ(x+y+z) = χ(x)χ(y)χ(z) (AddChar.map_add_eq_mul) combines the character factors, and ring commutativity rearranges the product into (f(x)f(y)f(z)) χ(x+y+z).

    lines 6–20

    uses Finset.sum_congr, pow_succ, pow_zero, Finset.sum_mul, Finset.mul_sum, AddChar.map_add_eq_mul

      classical
      calc
        _ = ∑ χ : AddChar G ℂ, ∑ x : G, ∑ y : G, ∑ z : G,
            (f x * f y * f z) * χ (x+y+z) := by
          apply Finset.sum_congr rfl
          intro χ hχ
          simp only [pow_succ, pow_zero, Finset.sum_mul, Finset.mul_sum]
          apply Finset.sum_congr rfl
          intro x hx
          apply Finset.sum_congr rfl
          intro y hy
          apply Finset.sum_congr rfl
          intro z hz
          rw [AddChar.map_add_eq_mul, AddChar.map_add_eq_mul]
          ring
  2. Interchanging the order of summation brings the character sum inside: ∑_χ ∑_x ∑_y ∑_z f(x)f(y)f(z) χ(x+y+z) = ∑_x ∑_y ∑_z f(x)f(y)f(z) ∑_χ χ(x+y+z).

    Using distributivity (Finset.mul_sum), the coefficient f(x)f(y)f(z) is factored out of the character summation. Applying Fubini's theorem for finite sums (Finset.sum_comm) repeatedly interchanges the sum over characters with the sums over x, y, and z, placing the character sum innermost.

    lines 21–30

    uses Finset.mul_sum, Finset.sum_comm, Finset.sum_congr

        _ = ∑ x : G, ∑ y : G, ∑ z : G,
            (f x * f y * f z) * ∑ χ : AddChar G ℂ, χ (x+y+z) := by
          simp only [Finset.mul_sum]
          rw [Finset.sum_comm]
          apply Finset.sum_congr rfl
          intro x hx
          rw [Finset.sum_comm]
          apply Finset.sum_congr rfl
          intro y hy
          rw [Finset.sum_comm]
  3. Evaluating the character sum by orthogonality and collapsing the sum over z to z = -x-y establishes the identity: ∑_x ∑_y ∑_z f(x)f(y)f(z) ∑_χ χ(x+y+z) = |G| ∑_x ∑_y f(x)f(y)f(-x-y).

    By the orthogonality relation for additive characters (AddChar.sum_apply_eq_ite), the inner sum ∑_χ χ(x+y+z) equals |G| if x+y+z = 0 and 0 otherwise. In G, x+y+z = 0 is equivalent to z = -x-y (add_comm, add_eq_zero_iff_eq_neg, sub_eq_add_neg). Thus, for fixed x and y, the sum over z vanishes everywhere except at z = -x-y. Applying Finset.sum_eq_single collapses the sum over z to f(x)f(y)f(-x-y) * |G|. Finally, factoring |G| out of the sums over x and y completes the equality.

    lines 31–48

    uses AddChar.sum_apply_eq_ite, Finset.mul_sum, Finset.sum_congr, add_comm, add_eq_zero_iff_eq_neg, sub_eq_add_neg, mul_ite, mul_zero, Finset.sum_eq_single

        _ = _ := by
          simp_rw [AddChar.sum_apply_eq_ite]
          rw [Finset.mul_sum]
          apply Finset.sum_congr rfl
          intro x hx
          rw [Finset.mul_sum]
          apply Finset.sum_congr rfl
          intro y hy
          have heq (z : G) : x + y + z = 0 ↔ z = -x-y := by
            rw [add_comm (x+y) z, add_eq_zero_iff_eq_neg]
            simp [sub_eq_add_neg, add_comm]
          simp only [heq, mul_ite, mul_zero]
          rw [Finset.sum_eq_single (-x-y)]
          · simp
            ring
          · intro z hz hne
            simp [hne]
          · simp
AddChar.map_add_eq_mul
An additive character is a homomorphism from an additive group to a multiplicative group, so χ(x + y) = χ(x)χ(y).
AddChar.sum_apply_eq_ite
Orthogonality of additive characters: the sum of χ(a) over all additive characters χ equals the group cardinality |G| if a = 0, and 0 otherwise.
Finset.mul_sum
Finset left-distributivity: multiplying a scalar by a finite sum equals summing the products of the scalar with each term.
Finset.sum_congr
Finset congruence: two finite sums over the same set are equal if their summands agree on every element.
Finset.sum_comm
Fubini's theorem for finite sums: the order of two finite summations can be exchanged.
Finset.sum_eq_single
If a summand vanishes at all elements except possibly a single element a, the finite sum reduces to the value at a.
Finset.sum_mul
Finset right-distributivity: a finite sum multiplied by a scalar equals summing each term multiplied by the scalar.
add_comm
Addition is commutative: a + b = b + a.
add_eq_zero_iff_eq_neg
In an additive group, a + b = 0 if and only if a = -b.
mul_ite
Multiplication distributes over an if-then-else conditional expression: a * (if P then b else c) = if P then a * b else a * c.
mul_zero
Multiplication of any element by zero is zero: a * 0 = 0.
pow_succ
The (n + 1)-st power of an element equals its n-th power multiplied by the element: a ^ (n + 1) = a ^ n * a.
pow_zero
Any element raised to the zeroth power is the identity: a ^ 0 = 1.
sub_eq_add_neg
Subtraction is defined as adding the additive inverse: a - 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

open scoped BigOperatorstheorem op861_fourier_cube_identity (G : Type*) [AddCommGroup G] [Fintype G] [DecidableEq G] (f : G → ℂ) :    (∑ χ : AddChar G ℂ, (∑ x : G, f x * χ x) ^ 3) =      (Fintype.card G : ℂ) * ∑ x : G, ∑ y : G, f x * f y * f (-x-y) := by  classical  calc    _ = ∑ χ : AddChar G ℂ, ∑ x : G, ∑ y : G, ∑ z : G,        (f x * f y * f z) * χ (x+y+z) := by      apply Finset.sum_congr rfl      intro χ hχ      simp only [pow_succ, pow_zero, Finset.sum_mul, Finset.mul_sum]      apply Finset.sum_congr rfl      intro x hx      apply Finset.sum_congr rfl      intro y hy      apply Finset.sum_congr rfl      intro z hz      rw [AddChar.map_add_eq_mul, AddChar.map_add_eq_mul]      ring    _ = ∑ x : G, ∑ y : G, ∑ z : G,        (f x * f y * f z) * ∑ χ : AddChar G ℂ, χ (x+y+z) := by      simp only [Finset.mul_sum]      rw [Finset.sum_comm]      apply Finset.sum_congr rfl      intro x hx      rw [Finset.sum_comm]      apply Finset.sum_congr rfl      intro y hy      rw [Finset.sum_comm]    _ = _ := by      simp_rw [AddChar.sum_apply_eq_ite]      rw [Finset.mul_sum]      apply Finset.sum_congr rfl      intro x hx      rw [Finset.mul_sum]      apply Finset.sum_congr rfl      intro y hy      have heq (z : G) : x + y + z = 0 ↔ z = -x-y := by        rw [add_comm (x+y) z, add_eq_zero_iff_eq_neg]        simp [sub_eq_add_neg, add_comm]      simp only [heq, mul_ite, mul_zero]      rw [Finset.sum_eq_single (-x-y)]      · simp        ring      · intro z hz hne        simp [hne]      · simp
See it in the graphDiscuss this resultChallenge it