Re: Discrete Fourier Transform
- To: mathgroup at smc.vnet.net
- Subject: [mg44882] Re: Discrete Fourier Transform
- From: David Wood <me at floyd.attbi.com>
- Date: Fri, 5 Dec 2003 05:31:52 -0500 (EST)
- References: <bm0juq$prl$1@smc.vnet.net>
- Sender: owner-wri-mathgroup at wolfram.com
Katie Neish <cdneish at interchange.ubc.ca> wrote: > I am attempting to perform a discrete Fourier transform on a time series > using Mathematica 4.0. (I'd like to determine the period of the signal.) > Unfortunately, I noticed that I cannot control the frequency resolution of > this transform. I also have no idea what units the frequency is in. > Do you know of any way to get around the problem? Assume the data were acquired at uniform time intervals (say, once every 1/10th of a second) for a total time T seconds, say 10 sec. The units of frequency in Mathematica's DFT become 1/T: the second...100th elements of the DFT output array are the complex amplitudes at frequencies 1/T, 2/T,... up to (N-1)/T = 99/T. Note that the returned values are at ordinary frequencies nu (e.g., Hz if seconds are used), not angular frequencies omega. As usual, since the Fourier transform of a real function is complex, you need to construct the power spectrum: if the DFT vector is ddft, you'd need something like pwr = Chop[Conjugate[dft] dft] to produce a vector (again, length 100) containing the power spectrum of the original signal. A peak at, say, the 41st element (corresponding to the frequency 40/T) would correspond to a period of T/40, then. -- David M. Wood, Dept. of Physics, Colorado School of Mines, Golden, CO 80401 Phone: (303) 273-3853; Fax: (303) 273-3919 http://www.mines.edu/Academic/physics/people/pages/wood.html