Finite Fields of the Form GF(2^n)
1. Building GF(2n): Polynomials mod Irreducible m(x)
GF(2n) = polynomials over GF(2) of degree <n, arithmetic mod an irreducible degree-n m(x) — exact parallel of Zp (integers mod prime p):
Addition = XOR; multiplication = polynomial multiply then reduce mod m(x); every nonzero element has an inverse (Extended Euclid on polynomials). AES uses n=8: m(x)=x8+x4+x3+x+1 (0x11B), elements = bytes.
2. Worked GF(28) Multiplication (AES Core)
0x57 • 0x83: polynomials (x6+x4+x2+x+1)(x7+x+1). Multiply (convolution, XOR combine): collect degree by degree — result before reduction: x13+x11+x9+x8+x7+x7+x5+x3+x2+x+x6+x4+x2+x+1. Cancel pairs (x7⊕x7=0, x2⊕x2=0, x⊕x=0): x13+x11+x9+x8+x6+x5+x4+x3+1. Reduce mod m(x): x8≡x4+x3+x+1, x9≡x(x4+x3+x+1)=x5+x4+x2+x, x11, x13 similarly (repeated xtime) — final remainder: 0xC1. (Stallings's canonical example: 0x57 • 0x83 = 0xC1 — quote it.)
Small-field sanity trace (GF(23), m(x)=x3+x+1): (x2+1)(x2+x)=x4+x3+x2+x. Reduce: x3≡x+1, x4≡x2+x → (x2+x)+(x+1)+x2+x=(x2⊕x2)+(x⊕x⊕x)+1=x+1. So (101)(110)=(011) in GF(23) — hand-checkable in exams.
3. Inverses and Generators in GF(2n)
- Inverse via Extended Euclid: a(x)x(x)+m(x)y(x)=1⇒x(x)=a−1. AES S-box starts from this inverse (then affine). Example in GF(23): (x2+1)−1: Euclid m=(x+1)(x2+1)+x... solve to get inverse x2+x (verify: (x2+1)(x2+x)=x+1×? — Topic-3 division backwards; trust Euclid table method).
- Multiplicative group cyclic of order 2n−1: AES GF(28)∗ order 255; generator g=x+1 (
0x03): powers run all 255 nonzero bytes — S-box/ logarithm tables built from this.
- Freshman's dream: (a+b)2=a2+b2 in char 2 — squaring is linear (Frobenius automorphism); AES square-and-multiply + Itoh–Tsujii inversion exploit it.
4. GF(2n) vs GF(p) (Exam Table)
| Point |
GF(p) |
GF(2n) |
| Elements |
integers 0..p−1 |
polynomials degree <n (bit-strings) |
| Addition |
+ mod p |
XOR |
| Modulus |
prime p |
irreducible m(x) degree n |
| Inverse |
integer Euclid |
polynomial Euclid |
| Crypto home |
DH/DSA/RSA-prime fields, ECC mod p |
AES, GCM (GF(2128)), Reed–Solomon, CRCs |
| Example |
3−1=5 in GF(7) |
0x57•0x83 = 0xC1 in AES GF(28) |
Exam Points
- Construction formula GF(2)[x]/(m(x)) + AES m(x) verbatim — 2-mark opener.
0x57 • 0x83 = 0xC1 cited; GF(23) hand-trace (101)(110)=(011) — 5-mark core.
- Inverse-via-Euclid statement + cyclic order 2n−1 + generator
0x03.
- Full comparison table GF(p) vs GF(2n).