AFTD Auto-Formalizing Theoretical Domains

is_k_ary_legendre_pair

def

Two sequences A and B of length ℓ form a k-ary Legendre pair if all their values are k-th roots of unity and PAF(A, s) + PAF(B, s) = -2 for all nonzero lags s.

Statement

def is_k_ary_legendre_pair (k : ℕ) {ℓ : ℕ} [NeZero ℓ] (A B : Fin ℓ → ℂ) : Prop
Defined in
arXiv:2611.31067, Section 1
Verified
26 Nov 2026
Axioms
none listed

Read back from the Lean

Given a natural number k, a natural number ℓ with typeclass instance [NeZero ℓ] (asserting ℓ ≠ 0), and two sequences A, B : Fin ℓ → ℂ, is_k_ary_legendre_pair k A B asserts that all of the following hold: 1. For every j : Fin ℓ, A j is a k-th root of unity in ℂ (that is, there exists u : rootsOfUnity k ℂ such that u coerced to ℂ equals A j). 2. For every j : Fin ℓ, B j is a k-th root of unity in ℂ (there exists u : rootsOfUnity k ℂ such that u coerced to ℂ equals B j). 3. For every s : Fin ℓ with s ≠ 0, the sum over all j : Fin ℓ of A j * star (A (j + s)) plus the sum over all j : Fin ℓ of B j * star (B (j + s)) equals -2 (where + is addition in Fin ℓ, i.e., addition modulo ℓ, and star is the complex conjugate).

Written by a model that saw only the Lean, never the English above. If the two disagree, that is worth a challenge.

Lean source view module on GitHub

/-- Two sequences A, B : Fin ℓ → ℂ form a k-ary Legendre pair if both are k-ary and their periodic autocorrelations sum to -2 for all nonzero lags. -/
def is_k_ary_legendre_pair (k : ℕ) {ℓ : ℕ} [NeZero ℓ] (A B : Fin ℓ → ℂ) : Prop := (∀ j : Fin ℓ, ∃ u : rootsOfUnity k ℂ, ((u : ℂˣ) : ℂ) = A j) ∧
   (∀ j : Fin ℓ, ∃ u : rootsOfUnity k ℂ, ((u : ℂˣ) : ℂ) = B j) ∧
   (∀ s : Fin ℓ, s ≠ 0 →
     (∑ j : Fin ℓ, A j * star (A (j + s))) +
     (∑ j : Fin ℓ, B j * star (B (j + s))) = -2)
See it in the graphDiscuss this resultChallenge it