Documentation

CslibFrontier.Crypto.Computational.SIS.Polynomial

Polynomial interpretation of negacyclic coefficient vectors #

For n ≠ 0, the ring Negacyclic R n represents R[X]/(X^n + 1) on coefficient vectors. This module identifies it with Mathlib's canonical quotient AdjoinRoot (X^n + 1) as an R-algebra, for positive n over a nontrivial commutative ring. No primality or irreducibility assumption is needed. The positive-dimension restriction matters: at n = 0 the quotient is R[X]/(2), while Negacyclic R 0 is the zero ring, a chosen zero-dimensional extension. Matrix-vector products, such as the Module-SIS map read through ofCoeffs_comp_moduleSISMap, transport entrywise to the quotient.

Main definitions #

Main results #

References #

Original supporting representation algebra for the coefficient model in SIS.Module.

noncomputable def Cslib.Crypto.negacyclicEquiv {R : Type u_1} [CommRing R] [Nontrivial R] {n : ℕ} (hn : n ≠ 0) :

For positive n, Negacyclic R n is Mathlib's canonical quotient R[X]/(X^n + 1): an element is the polynomial with its coefficients, taken modulo X^n + 1.

theorem Cslib.Crypto.negacyclicEquiv_apply {R : Type u_1} [CommRing R] [Nontrivial R] {n : ℕ} (hn : n ≠ 0) (a : Negacyclic R n) :
(negacyclicEquiv hn) a = ∑ i : Fin n, (algebraMap R (AdjoinRoot (Polynomial.X ^ n + 1))) (a.coeffs i) * AdjoinRoot.root (Polynomial.X ^ n + 1) ^ ↑i

The quotient representative is the usual polynomial evaluation at the residue of X.

theorem Cslib.Crypto.negacyclicEquiv_mulVec {R : Type u_1} [CommRing R] [Nontrivial R] {n : ℕ} (hn : n ≠ 0) {d k : ℕ} (A : Matrix (Fin d) (Fin k) (Negacyclic R n)) (z : Fin k → Negacyclic R n) :

Matrix-vector products over Negacyclic R n map entrywise to the quotient ring.