





Study with the several resources on Docsity
Earn points by helping other students or get them with a premium plan
This page cannot be seen from the preview
Don't miss anything!






Consider two polynomials: A(x) = a 0 + a 1 x + · · · + an− 1 xn−^1 and B(x) = b 0 + b 1 x + · · · + bn− 1 xn−^1. Let their product be C(x) = c 0 + c 1 x + · · · + c 2 n− 2 x^2 n−^2. For all 0 ≤ 2 n − 2, the coefficient ck of C(x) is: ck = a 0 bk + a 1 bk− 1 + · · · + akb 0 = i∑ = 0^ k aibk−i. (Assume that, for i ≥ n, ai and bi are zero.)
Takes O(n^2 ) multiplications.
A polynomial of degree d is uniquely characterized by its values at d + 1 distinct points. Let x 0 , x 1 ,... , x 2 n− 2 be 2n − 1 distinct points. Let A(x 0 ), A(x 1 ),... , A(x 2 n− 2 ) be the values of the polynomial A(x) at these 2n − 1 points. Let B(x 0 ), B(x 1 ),... , B(x 2 n− 2 ) be the values of the polynomial B(x) at these 2n − 1 points. Then, the values of the product polynomial C(x) at these 2n − 1 points is : C(xi) = A(xi) × B(xi) for 0 ≤ i ≤ 2 n − 2.
Assume that the number of coefficients N is a power of 2.
Express A(x) as: [a 0 + a 2 x^2 + · · · + aN − 2 xN^ −^2 ] + x [a 1 + a 3 x^2 + · · · + aN − 1 xN^ −^2 ]
Let Ae(x^2 ) = a 0 + a 2 x^2 + · · · + aN − 2 xN^ −^2. Let Ao(x^2 ) = a 1 + a 3 x^2 + · · · + aN − 1 xN^ −^2. Then, A(x) = Ae(x^2 ) + x Ao(x^2 ). Suppose the points are such that xj = − xN 2 +j for 0 ≤ j ≤ N 2 − 1: symmetry.
Number of multiplications reduces by a factor of 2. Evaluating Ae(x^2 ) same problem with half the number of coefficients and half the number of points. Need points that satisfy the symmetry property recursively.
Consider the equation xN^ − 1 = 0. N distinct roots expressible as : 1 , ω, ω^2 ,... , ωN^ −^1 ω = e^2 πN^ i: principal N -th root of unity.
Let xi = ωi^ for 0 ≤ i ≤ N − 1. Properties of a principal N -th root of unity.:
If w is a principal N -th root of unity, w^2 is a principal N 2 th- root of unity.
To form the R, the values of the product polynomial C(x) at the N points ωj^ for 0 ≤ j ≤ N − 1.
FFTEvaluation(A(x), ω, U ). FFTEvaluation(B(x), ω, V ). For 0 ≤ j N − 1 do: R[j] = U [j] × V [j].
FFT evaluates the polynomial A(x) at 1, ω, ω^2 ,... , ωN^ −^1. A is the vector of coefficients of A(x). Result in vector U. Let W be the N × N matrix whose (j, k)-th entry is ωjk. Vector U with values of polynomial A(x) at 1, ω, ω^2 ,... , ωN^ −^1 is: W × A = U.
Values of the product C(x) of A(x) and B(x) in the vector R. Let C be the vector of (unknown) coefficients of C(x). Then, W × C = R
To get C given R: C = W−^1 R
Let: WIjk = ( ω^1 )jk. for 0 ≤ j, k ≤ N − 1. Form the product of W with WI: (W × WI)jk = 0 if j 6 = k. (W × WI)jk = N if j = k. Conclude that: W−^1 = (^) N^1 WI.