Who this is for: You already know what a group, a ring, and a field are (and you've seen finite fields Fp, EC groups G, and polynomials in Plonk/IPA). This module fills in everything else used in Modules 01–09—especially vector spaces, modules, quotient rings, CRT, and cyclotomic rings—slowly, intuitively, and with concrete examples.
1. From Groups/Fields to Vector Spaces
You know a fieldF (like R, Q, or Fp) is a place where you can add, subtract, multiply, and divide by any nonzero element.
A vector spaceV over a field F is simply a set of "vectors" where you can:
Add two vectors: u+v∈V, and
Scale a vector by any scalar from the field: c⋅v∈V for c∈F,
subject to the usual arithmetic rules (distributivity, associativity, 0 vector).
The classic example is Rn (lists of n real numbers) or Fpn (lists of n scalars in Plonk!).
1.1 Linear Combinations, Span, and Linear Independence
Given vectors b1,…,bk∈V:
A linear combination is any expression c1b1+c2b2+⋯+ckbk where ci∈F.
The span of {b1,…,bk} is the set of all possible linear combinations.
The vectors are linearly independent if the only way to make c1b1+⋯+ckbk=0 is by choosing all c1=c2=⋯=ck=0.
Intuition: None of the vectors is "redundant"—you can't build any bi out of the others.
1.2 Basis and Dimension
A set {b1,…,bn} is a basis of V if:
It spans V (every vector in V can be built from it), AND
It is linearly independent (every vector in V is built in exactly one unique way!).
The number of vectors in a basis is the dimensiondim(V)=n.
In Rn, the standard basis is e1=(1,0,…,0)T,…,en=(0,…,0,1)T.
Matrix view: Put the basis vectors b1,…,bn as the columns of an n×n matrix B. Then building a vector c1b1+⋯+cnbn is just the matrix-vector product Bc! Because B is a basis, B is invertible (det(B)=0).
1.3 Inner Products, Orthogonality, and Projections
In Rn, we also have geometry—lengths and angles—coming from the dot product (inner product):
⟨u,v⟩=i=1∑nuivi=uTv.
Length (Euclidean / ℓ2 norm):∥v∥2=⟨v,v⟩.
Orthogonal (perpendicular):u⊥v means ⟨u,v⟩=0.
Projection: Given a vector w and a direction u=0, how much of w points along u?
proju(w)=⟨u,u⟩⟨w,u⟩⋅u.
Notice why that works: if you subtract proju(w) from w, the leftover vector w′=w−proju(w) satisfies ⟨w′,u⟩=0 (it is perpendicular to u)!
(This exact formula is the core of Gram-Schmidt Orthogonalization in Module 01!)
1.4 Determinant as Volume
For an n×n matrix B over R:
det(B)=0 means the columns are linearly dependent (they collapse into a lower-dimensional flat space—zero volume!).
∣det(B)∣ is literally the n-dimensional volume of the parallelogram/box spanned by the columns of B!
Check in 2D: for (3002), the box is a 3×2 rectangle of area 6=∣det(B)∣.
If you shear a rectangle by adding a multiple of one column to another—e.g. (3032)—the area stays 6 (base×height)! That's why integer column operations don't change a lattice's determinant!
2. Modules: "Vector Spaces" Over a Ring
What happens if you take the definition of a vector space over a field F, and replace the field F with a ringR (where you can add, subtract, and multiply scalars, but you usually CANNOT divide)?
That structure is called an R-module!
Every vector space is a module (just a module over a field).
Zn is a Z-module (you can add integer vectors and multiply them by integers, like 3v, not by 1/2).
A lattice L(B)={Bz:z∈Zn} is a Z-module inside Rn!
In Module 03, Rqm is an Rq-module (vectors of m polynomials, scaled by polynomials in Rq).
Why does "no division" make modules totally different from vector spaces?
Look at 1 dimension:
Over R, ANY nonzero number (say 2) is a basis of R1, because you can reach 1 by scaling 2 by 1/2.
Over Z, {2} does NOT span Z! You can only reach even numbers 2Z. And {2,3} spans Z (since 3−2=1), even though 2 and 3 are not independent (3⋅2+(−2)⋅3=0)!
Over Zn, you can only change from one basis B1 to another basis B2 via a matrix U whose inverse U−1 ALSO has integer entries—i.e. U∈GLn(Z), meaning det(U)=±1!
(That is why Module 01 makes such a big deal about unimodular matrices!)
3. Kernels, Images, and Quotient Structures
In your Plonk/EC work, you already use modular arithmetic Z/qZ (integers mod q). Let's unify how quotients work for groups, rings, and polynomials, because lattice crypto uses all three constantly.
3.1 Kernel and Image of a Linear Map
Suppose A∈Zqn×m is a matrix mapping m-vectors to n-vectors: f(x)=Ax(modq).
Kernel (nullspace):ker(f)={x∈Zm:Ax≡0(modq)} (all inputs that map to zero!).
Notice: if x1 and x2 produce the same output Ax1≡Ax2(modq), then their difference x1−x2 is in ker(f)!
(That's literally why finding a collision in an Ajtai commitment Ax1=Ax2 gives a nonzero vector in the kernel lattice Λq⊥(A)=ker(f)!)
First Isomorphism Theorem (in plain English):
If a homomorphism f:G→H hits everything in H (surjective), then collapsing everything in ker(f) to 0 gives an exact 1-to-1 copy of H:
G/ker(f)≅H.
Example: For f:Zm→Zqn defined by f(x)=Axmodq (assuming A has full rank n):
The quotient Zm/Λq⊥(A) has the exact same size as Zqn, which is qn!
That's why det(Λq⊥(A))=qn in Module 02!
3.2 Quotient Rings: From Z/qZ to R[X]/(f(X))
Recall how Z/qZ is built:
Start with the ring Z, pick a modulus q, and declare q≡0.
Every integer reduces to its remainder in {0,1,…,q−1} (or balanced [−q/2,q/2)).
When is Z/qZ a field? If and only if q is prime! If q is composite (say q=6), then 2⋅3≡0(mod6) even though 2=0 and 3=0—we call 2 and 3zero divisors, and neither has a multiplicative inverse mod 6.
Now do the exact same thing with a polynomial ring!
Start with the polynomial ring Z[X] (polynomials with integer coefficients) or Fq[X] (polynomials with coefficients mod q).
Pick a monic polynomial f(X) of degree d, and consider the quotient ring:
S=(f(X))Fq[X].
What does "modding out by (f(X))" mean concretely?
Declare f(X)≡0, and compute every polynomial expression modulo f(X) (polynomial long division!).
Every element of S has a unique remainder of degree <d:
a(X)=a0+a1X+⋯+ad−1Xd−1.
Addition: Add coefficients mod q.
Multiplication: Multiply two polynomials normally, then divide by f(X) and take the remainder!
Example 1: Complex Numbers C≅R[X]/(X2+1)
You already know a quotient ring in disguise!
Take R[X]/(X2+1). Setting X2+1≡0 means X2≡−1.
Call X by the letter i: every remainder is a+bi, and (a+bi)(c+di)=(ac−bd)+(ad+bc)i!
Example 2: Irreducible vs. Reducible (Extension Fields vs. Zero Divisors!)
Just like Z/qZ depends on whether q is prime or composite, Fq[X]/(f(X)) depends on whether f(X)factors modulo q:
If f(X) is irreducible over Fq (cannot be factored into smaller-degree polynomials mod q):
Then Fq[X]/(f(X)) is a field of size qd, written Fqd! Every nonzero polynomial has an inverse (found via Extended Euclidean Algorithm!).
Example:X2+1 has no roots in F3 (02+1=1, 12+1=2, 22+1=2), so F3[X]/(X2+1)≅F9 is a 9-element field!
If f(X) factors over Fq, say f(X)=g(X)h(X)(modq):
Then g(X)≡0 and h(X)≡0, yet g(X)⋅h(X)=f(X)≡0 in the quotient ring!
So g(X) and h(X) are zero divisors and are not invertible!
Example: Over F5, X2+1≡(X−2)(X+2)(mod5). So in F5[X]/(X2+1), (X−2)(X+2)≡0(mod5)!
5. The Chinese Remainder Theorem (CRT) — For Integers and Polynomials!
Remember the CRT for integers?
If m=p1⋅p2 for coprime p1,p2 (like 15=3⋅5), then knowing xmod15 is completely equivalent to knowing (xmod3,xmod5):
Z/15Z≅Z/3Z×Z/5Z,
and addition/multiplication mod 15 happens independently in each slot!
Now apply the exact same theorem to polynomials!
Suppose f(X) factors modulo q into distinct irreducible polynomials:
f(X)≡f0(X)⋅f1(X)⋯fk−1(X)(modq).
Then by the Polynomial Chinese Remainder Theorem:
(f(X))Fq[X]≅(f0(X))Fq[X]×(f1(X))Fq[X]×⋯×(fk−1(X))Fq[X]!
Look at the two extreme cases you already know (or will use in Modules 03–08):
Complete splitting into degree-1 factors (fj(X)=X−rj):
Notice that reducing a polynomial a(X) modulo (X−rj) is literally just evaluating a(rj)!
So when Xd−1=∏j=0d−1(X−ωj) over Fq (like in Plonk!):
(Xd−1)Fq[X]≅d copiesFq×Fq×⋯×Fq=Fqd,
and the CRT isomorphism a(X)↦(a(ω0),a(ω1),…,a(ωd−1)) is literally the FFT / NTT!
Partial splitting into k factors of degree d/k:
Each factor Fq[X]/(fj(X)) is an extension field Fqd/k, so:
(f(X))Fq[X]≅(Fqd/k)k!
Wait: why is an element a(X) invertible in this product ring iff all k slots are nonzero?
Because in a product of fields F0×⋯×Fk−1, (s0,…,sk−1) has an inverse (s0−1,…,sk−1−1)if and only if every single sj=0! If even one slot sj=0, it has no inverse and is a zero divisor!
6. Cyclotomic Polynomials & Cyclotomic Rings
Now let's demystify the single most famous ring in lattice cryptography:
R=(Xd+1)Z[X],where d=2k is a power of 2.
6.1 What Does "Cyclotomic" Mean?
"Cyclotomic" literally means "circle-dividing" (from Greek kyklos + temnein).
Consider the complex unit circle ∣z∣=1. The solutions to zn=1 are n evenly spaced points around the circle: 1,e2πi/n,e4πi/n,….
A root ζ is a primitive n-th root of unity if ζn=1 and no smaller positive power equals 1 (think of a generator of the cyclic group of n-th roots!).
The n-th cyclotomic polynomialΦn(X) is the monic polynomial whose roots are only the primitive n-th roots of unity:
Φn(X)=1≤k≤ngcd(k,n)=1∏(X−e2πik/n).
Remarkably, Φn(X) always has integer coefficients and is irreducible over Q!
Now check n=2d=2k+1 (a power of 2)!
A (2d)-th root of unity satisfies X2d−1=(Xd−1)(Xd+1)=0.
The roots of Xd−1 are NOT primitive (2d)-th roots (their d-th power is already 1).
The remaining d roots—all the odd powers ζ1,ζ3,ζ5,…,ζ2d−1—are ALL the primitive (2d)-th roots, and they are the exact roots of Xd+1!
So for power-of-2 d:
Φ2d(X)=Xd+1!
6.2 Why Lattice Crypto Loves R=Z[X]/(Xd+1)
Simple reduction rule:Xd≡−1 (called negacyclic wrapping—if a term overflows past degree d−1, wrap it around with a minus sign!).
Power-of-2 FFT / NTT: Because 2d is a power of 2, multiplying polynomials mod (Xd+1,q) uses a super clean radix-2 NTT in O(dlogd) time!
Nice geometry: Unlike other rings where reducing mod f(X) blows up coefficients wildly (e.g., Xd−X−1 causes Fibonacci-like coefficient growth), reducing mod Xd+1 only flips signs (+→-), keeping coefficients short!
In Module 03 you will see two scary-sounding terms from algebraic number theory—both are actually very concrete:
Canonical embedding σ(a): Since Xd+1 has d complex roots ζ0,…,ζd−1 on the unit circle, just evaluate the polynomial a(X) at all d complex roots:
σ(a)=(a(ζ0),a(ζ1),…,a(ζd−1))∈Cd.
Why bother? Because evaluating at roots turns polynomial multiplication into pointwise multiplication in Cd, making it easy to bound how big ∥a⋅b∥2 can get!
Galois automorphisms σk: An "automorphism" of a ring R is just a symmetry map R→R that preserves addition and multiplication.
For any odd integer k (so gcd(k,2d)=1), substituting X↦Xk sends every (2d)-th root of unity to another (2d)-th root of unity, and satisfies (Xk)d+1=(Xd)k+1=(−1)k+1=−1+1=0!
So the substitution map:
σk(a(X))=a(Xk)mod(Xd+1)
is a valid ring symmetry! In particular, k=−1 (σ−1(X)=X−1=−Xd−1) acts just like complex conjugation, reversing and negating coefficients 1…d−1 so that the constant term of a⋅σ−1(b) equals the dot product ⟨a,b⟩!
Quick Self-Check Exercises
Vector Space vs. Module: Explain in one sentence why {2} is a basis for R (as a 1D R-vector space), while {2} is not a basis for Z (as a Z-module).
Projections: Let u=(3,4)T and w=(5,0)T in R2. Compute proju(w) and verify that w−proju(w) is perpendicular to u.
Quotient Rings: In S=F7[X]/(X2+1):
Compute (2+3X)(1+4X) modulo (X2+1,7).
Is S a field? (Hint: check whether x2≡−1≡6(mod7) has any solution in F7!)
Zero Divisors via CRT: In F5[X]/(X2+1), we saw X2+1≡(X−2)(X+2)(mod5). Find the CRT representation (a(2),a(−2))∈F5×F5 for a(X)=1+2X, and check whether a(X) is invertible in F5[X]/(X2+1).
Cyclotomic Wrap-Around: In R=Z[X]/(X4+1), simplify (1+X3)⋅X2 and compute σ−1(3+2X−X2+4X3).