0% found this document useful (0 votes)
204 views6 pages

Cooley Tukey An Algorithm For The Machine Calculation of Complex Fourier Series Math of Comp 1965

This document summarizes an algorithm for efficiently calculating complex Fourier series using fewer than 2N log2 N operations, where N is the number of data points. The algorithm expresses indices in the Fourier series calculation in terms of the binary representation of the indices. It then iteratively calculates intermediate arrays based on successive bits, requiring only a single data storage array of size N. For binary computers, choosing N as a power of 2 provides additional computational advantages.

Uploaded by

Luiss delgado
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
204 views6 pages

Cooley Tukey An Algorithm For The Machine Calculation of Complex Fourier Series Math of Comp 1965

This document summarizes an algorithm for efficiently calculating complex Fourier series using fewer than 2N log2 N operations, where N is the number of data points. The algorithm expresses indices in the Fourier series calculation in terms of the binary representation of the indices. It then iteratively calculates intermediate arrays based on successive bits, requiring only a single data storage array of size N. For binary computers, choosing N as a power of 2 provides additional computational advantages.

Uploaded by

Luiss delgado
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 6

An Algorithm for the Machine Calculation of Complex Fourier Series

Author(s): James W. Cooley and John W. Tukey


Source: Mathematics of Computation, Vol. 19, No. 90 (Apr., 1965), pp. 297-301
Published by: American Mathematical Society
Stable URL: http://www.jstor.org/stable/2003354 .
Accessed: 23/08/2013 05:12

Your use of the JSTOR archive indicates your acceptance of the Terms & Conditions of Use, available at .
http://www.jstor.org/page/info/about/policies/terms.jsp

.
JSTOR is a not-for-profit service that helps scholars, researchers, and students discover, use, and build upon a wide range of
content in a trusted digital archive. We use information technology and tools to increase productivity and facilitate new forms
of scholarship. For more information about JSTOR, please contact [email protected].

American Mathematical Society is collaborating with JSTOR to digitize, preserve and extend access to
Mathematics of Computation.

http://www.jstor.org

This content downloaded from 130.235.201.198 on Fri, 23 Aug 2013 05:12:16 AM


All use subject to JSTOR Terms and Conditions
An Algorithm for the Machine Calculation of
Complex Fourier Series
By James W. Cooleyand John W. Tukey
An efficient method for the calculation of the interactions of a 2' factorial ex-
periment was introduced by Yates and is widely known by his name. The generaliza-
tion to 3' was given by Box et al. [1]. Good [2] generalized these methods and gave
elegant algorithms for which one class of applications is the calculation of Fourier
series. In their full generality, Good's methods are applicable to certain problems in
which one must multiply an N-vector by an N X N matrix which can be factored
into m sparse matrices, where m is proportional to log N. This results inmaprocedure
requiring a number of operations proportional to N log N rather than N2. These
methods are applied here to the calculation of complex Fourier series. They are
useful in situations where the number of data points is, or can be chosen to be, a
highly composite number. The algorithm is here derived and presented in a rather
different form. Attention is given to the choice of N. It is also shown how special
advantage can be obtained in the use of a binary computer with N = 2' and how
the entire calculation can be performed within the array of N data storage locations
used for the given Fourier coefficients.
Consider the problem of calculating the complex Fourier series
N-1
(1) X(j) = EA(k)-Wjk, j = 0 1, * ,N- 1,
k=0

where the given Fourier coefficients A (k) are complex and W is the principal
Nth root of unity,
(2) W = e2TiIN

A straightforward calculation using (1) would require N2 operations where "opera-


tion" means, as it will throughout this note, a complex multiplication followed by a
complex addition.
The algorithm described here iterates on the array of given complex Fourier
amplitudes and yields the result in less than 2N log2 N operations without requiring
more data storage than is required for the given array A. To derive the algorithm,
suppose N is a composite, i.e., N -r-r2 . Then let the indices in (1) be expressed

j -
jirl + jo , O= 0, 1, , r,
X - 1, Ji 0, 1, Xr2- 1,
(3)
k = kir2+ ko, ko = 0 1 ,**X r2 - 1, kl-O 1, *** r,-1
Then, one can write
(4) X(j1, jo) - E EA(k1, ko).Wjklr2WjkO.
kA ki

Received August 17, 1964. Research in part at Princeton University under the sponsorship
of the Army Research Office (Durham). The authors wish to thank Richard Garwin for his
essential role in communication and encouragement.
297

This content downloaded from 130.235.201.198 on Fri, 23 Aug 2013 05:12:16 AM


All use subject to JSTOR Terms and Conditions
298 JAMES W. COOLEY AND JOHN W. TUKEY

Since
(5) WjkTr2 = WJokir2

the innersum, over k1, dependsonly on jo and koand can be defined as a new array,
(6) Al(jo, ko) -E A(k1, ko).W1okir2.

The result can then be written


(7) X(ji, jo) - EAi(jo, ko) . W(jlrl+o)ko.
ko

There are N elements in the array AI, each requiringri operations,giving a total
of Nrl operationsto obtain A1. Similarly, it takes Nr2 operationsto calculate X
from Al. Therefore,this two-stepalgorithm,given by (6) and (7), requiresa total
of
(8) T = N(r, + r2)
operations.
It is easy to see how successiveapplicationsof the above procedure,startingwith
its applicationto (6), give an m-step algorithmrequiring
(9) T =N(ri+r2+ - +rm)
operations,where
(10) N = rlor2 .. rm.

If rj = sjtj with sj I tj > 1, then sj + tj < rj unless sj = tj= 2, when sj + ty = rj.


In general,then, using as many factorsas possibleprovidesa minimumto (9), but
factorsof 2 can be combinedin pairswithout loss. If we are able to chooseN to be
highly composite,we may make very real gains. If all rj are equal to r, then, from
(10) we have
(11) m=logN
and the total numberof operationsis
(12) T(r) = rNlogrN.
If N = rmst
nt, , then we find that
T
- = M.ar+ news+ p. t +***,
(13) N
log2 N mlog2
= r + n-log2 s + p log2 t +

so that
T
N log2 N

is a weightedmean of the quantities


r s t
log2r log2 S log2 t'

This content downloaded from 130.235.201.198 on Fri, 23 Aug 2013 05:12:16 AM


All use subject to JSTOR Terms and Conditions
MACHINE CALCULATION OF COMPLEX FOURIER SERIES 299

whose values run as follows


r
r4 log2r
2 2.00
3 1.88
4 2.00
5 2.15
6 2.31
7 2.49
8 2.67
9 2.82
10 3.01.
The use of r, 3 is formally most efficient, but the gain is only about 6% over
-

the use of 2 or 4, which have other advantages. If necessary, the use of rj up to 10


con increase the number of computations by no more than 50%. Accordingly, we
can find "highly composite" values of N within a few percent of any given large
number.
Whenever possible, the use of N == rmwith r = 2 or 4 offers important advantages
for computers with binary arithmetic, both in addressing and in multiplication
economy.
The algorithm with r 2 is derived by expressing the indices in the form

(14) j jm-1r2m-1 + + ji 2 + jo
k- kmI-,2m`l + *** + k .2 + ko,

where j, and k, are equal to 0 or 1 and are the contents of the respective bit positions
in the binary representation of j and k. All arrays will now be written as functions
of the bits of their indices. With this convention (I) is written

(15) X(jm_1X***Xjo) =EE***EA(k^m_1


ko k1 km-1
*** ko)- ?
where the sums are over k, - 0, 1. Since
(16) Wikm- 12m-1 = Wjokm 1.2m14

the innermost sum of (15), over km-,, depends only on jo, km_2,
2ko* **, and can
be written
(17) A,(jo, km-2, ... Iko)
, = EA(km-, ...X ko) .WJokmJ-I.2m
km-1

Proceeding-to the next innermost sum, over km-2, and so on, and using
(18) W1km l_.2m-1 = W(j -i21-'+.- .+jo)kmmj2m-l

one obtains successive arrays,

Aj(jo X *X Xj- iIl km-,-) X ... X ko)

( 19) ~~EA l-,(jo, * - si-2 km-, I .. 7 ko) W(jja- 21-l+ Ad+o)


kmj-l2nM-1
km-a

for 1, 2, - m.

This content downloaded from 130.235.201.198 on Fri, 23 Aug 2013 05:12:16 AM


All use subject to JSTOR Terms and Conditions
300 JAMES W. COOLEY AND JOHN W. TUKEY

Writingout the sum this appearsas


Al(jo, ..**, j1-1 km-l~
X- *...*, ko)

0, km-,-,), ko)
(20) Ail-(jo , i,-2,
4+. (-1
,
)Jl-ijiZ-2Al- (jo , ..., )j 2, 1, km-i-i * ko)

W(jj_3.21-3+...+,^o).2m-1) jl-1 = O. 1.

Accordingto the indexing convention, this is stored in a location whose index is

(21) io 2rn1 + . + j I, 2m-' + km-_.2 2 + --- + ko.

It can be seen in (20) that only the two storagelocationswith indiceshaving 0 and
1 in the 2" bit position are involved in the computation.Parallel computationis
permittedsince the operationdescribedby (20) can be carriedout with all values of
Jo, ...*, j1-2, and ko X km.. , simultaneously. In some applications* it is con-
venient to use (20) to expressAl in terms of Al,2 giving what is equivalentto an
algorithm with r = 4.
The last array calculatedgives the desiredFouriersums,
(22) X(jm1 X,* jo) - Am(joX jm-i)
in such an order that the index of an X must have its binary bitj put inireverse
orderto yield its index in the arrayAm,.
In some applications,where Fouriersums are to be evaluated twice, the above
procedurecould be programmedso that no bit-inversionis necessary.For example,
considerthe solutionof the differenceequation,
(23) aX(j + 1) + bX(j) + cX(j - 1) = F(j).
The present method could be first applied to calculate the Fourieramplitudesof
F(j) from the formula

(24) B(k) - Z F(j)W-6k.

The Fourieramplitudesof the solution are, then,

(25) A(k) =ark B(k)


a~+ b + CW-k

The B(k) and A (k) arrays are in bit-invertedorder, but with an obvious modifi-
cation of (20), A (k) can be used to yield the solutionwith correctindexing.
A computerprogramfor the IBM 7094 has been written which calculatesthree-
dimensionalFouriersums by the above method.The computingtime taken for com-
puting three-dimensional2a X 2" X 2c arraysof data points was as follows:
* A multiple-processing circuit using this algorithm was designed by R. E. Miller and S.
Winograd of the IBM Watson Research Center. In this case r = 4 was found to be most practi-
cal.

This content downloaded from 130.235.201.198 on Fri, 23 Aug 2013 05:12:16 AM


All use subject to JSTOR Terms and Conditions
MACHINE CALCULATION OF COMPLEX FOURIER SERIES 301

a b c No. Pts. Time (minutes)


4 4 3 21 .02
11 0 0 21 .02
4 4 4 212 .04
12 0 0 212 07
5 4 4 213 .10
5 5 3 213 .12
13 0 0 213 .13
IBM Watson Research Center
Yorktown Heights, New York
Bell Telephone Laboratories,
Murray Hill, New Jersey
Princeton University
Princeton, New Jersey
1. G. E. P. Box, L. R. CONNOR, W. R. COUSINS, 0. L. DAVIES (Ed.), F. R. HIRNSWORTH &
G. P. SILITTO, The Design and Analysis of Industrial Experiments, Oliver & Boyd, Edinburgh,
1954.
2. I. J. GOOD,"The interaction algorithm and practical Fourier series," J. Roy. Statist.
Soc. Ser. B. v. 20, 1958, P. 361-372; Addendum, V. 22, 1960, P. 372-375. MR 21 S1674; MR 23
S A4231. 58p.3132Adedmv.2,16,p37-7.M 21174MR3

This content downloaded from 130.235.201.198 on Fri, 23 Aug 2013 05:12:16 AM


All use subject to JSTOR Terms and Conditions

You might also like