# If we FFT a signal with number of points far less than the length of the signal, the result is unreliable?

For example, there is a very long-term observation and I cut the signal at a sampling rate of 10 into many segments of 1e6-point length. I wanna check the time-varying characteristics of the spectrum, so I fft each segment and compare their spectrum.

When doing the fft for each 1e6-point segment, in case of y = fft(x, 2^nextpow2(1e6)=1048576), we get the spectrum at freqs = 0 : 9.5367e-06 : 5 Hz. But it's time-consuming and I don't wanna store such big data.

So what if y = fft(x, 1024)? Do I get the CORRECT spectrum for freqs = 0 : 0.0098 : 5 Hz?

• Depends on whether or not the signal is stationary, and what kind of result you are looking to get from using an FFT. Sep 28 '15 at 16:38
• @hotpaw2 I modified the question and added some details. Sep 28 '15 at 17:06

As per the Matlab help, y = fft(x, 1024) where length(x) > 1024 will result in just taking the FFT of x(1:1024).

So if talking the FFT of just the first 1024 samples of your 1,000,000 point signal is OK, then sure, what you say is correct.

The simple answer to your question, if I'm understanding you correctly, is yes. If you take an FFT of length 1024 with a sample rate of 10, you would get frequency bins spaced roughly 0.0098 Hz apart.

Now your question about whether this is reliable is a bit subjective; it depends on what kind of frequency resolution you need. The shorter your FFT size, the worse your frequency resolution gets. Basically, you should pick the shortest FFT size that allows you to extract the information you need from the spectral data.