Rader's FFT algorithm: Difference between revisions

Content deleted Content added
Fredrik (talk | contribs)
m dab prime
Fredrik (talk | contribs)
Line 22:
:<math>b_q = e^{-\frac{2\pi i}{n} g^{-q} }.</math>
 
Since ''n''&ndash;1 is composite, this convolution can be performed directly via the [[convolution theorem]] and more conventional FFT algorithms. However, that may not be efficient if ''n''&ndash;1 itself has large prime factors, requiring recursive use of Rader's algorithm. Instead, one can compute a length-(''n''&ndash;1) cyclic convolution exactly by zero-padding it to a length of at least 2(''n''&ndash;1)&ndash;1, say to a [[power of two]], which can then be evaluated in O(''n'' log ''n'') time without the recursive application of Rader's algorithm.
 
This algorithm, then, requires O(''n'') additions plus O(''n'' log ''n'') time for the convolution. In practice, the O(''n'') additions can often be performed by absorbing the additions into the convolution: if the convolution is performed by a pair of FFTs, then the sum of ''x''<sub>''k''</sub> is given by the DC (0th) output of the FFT of ''a''<sub>''q''</sub>, and ''x''<sub>0</sub> can be added to all the outputs by adding it to the DC term of the convolution prior to the inverse FFT. Still, this algorithm requires intrinsically more operations than FFTs of nearby composite sizes, and typically takes 3&ndash;10 times as long in practice.