We discuss the fast Fourier transform in a finite field F with size p.
For w∈F, and n∈F+, define
Mw,n≐11...1ww2wnw2w4w2n.........wn−1w2(n−1)wn(n−1).If the following two conditions hold:
- n is some power of 2 and;
- wn=1 in the finite field.
Then ∀x≐(x1,x2,...,xn)∈Fn, we can compute
Mw,nx=11...1ww2wnw2w4w2n.........wn−1w2(n−1)wn(n−1)x1x2...xnin O(nlogn) time.
Proof. If n=2, then the claim holds trivially.
Otherwise, let d=n/2=2k−1 and v=w2. The odd columns of the first d rows of the matrix Mw,n constitutes
111w2w4w2dw4w8w4d............wn−2w2(n−2)wd(n−2)=111vv2vdv2v4v2d............vd−1v2(d−1)vd(d−1)=Mv,d.By assumption, for even numbers i=2,4,...,(n−2), we have i⋅d=1 in the finite field. Hence, the odd columns of the last d rows of Mw,n is
111w2(d+1)w2(d+2)w2(d+d)w4(d+1)w4(d+2)w4(d+d)............w(n−2)(d+1)w(n−2)(d+2)w(n−2)(d+d)=111w2w4w2dw4w8w4d............wn−2w2(n−2)wd(n−2)=Mv,d.Let xo,xe∈Fd be the vectors obtained by the odd and even dimensions of x respectively. By our construction,
- d is some power of 2 and;
- vd=wn=1.
Hence, by induction hypothesis we can compute Mv,dxo in O(dlogd)=O(nlogn) time.
Next, consider the even columns of the first d rows of the matrix Mw,n constitutes
ww2wdw3w6w3dw5w10w5d............wn−1w2(n−1)wd(n−1)=w...w2......wd111w2w4w2dw4w8w4d............wn−2w2(n−2)wd(n−2)=w...w2......wdMv,dSimilarly, the even columns of the last d rows of the matrix Mw,n constitutes
wd+1...wd+2......wd+dMv,d=(−1)w...w2......wdMv,d.The equality comes from that wd=wn/2=−1. By induction hypothesis, we can compute Mv,dxe in O(nlogn) time.
Finally, the first d dimensions of Mw,nx equals
Mv,dxo+w...w2......wdMv,dxe,which can be computed in O(nlogn)+O(nlogn)+O(n)=O(nlogn) time.
The last d dimensions of Mw,nx equals
Mv,dxo−w...w2......wdMv,dxe,which can also be computed in O(nlogn)+O(nlogn)+O(n)=O(nlogn) time.
□