1

I have a time series of air temperatures, that are measured in degrees C and the frequency of the signal is monthly. I compute the power spectra of the time series as:

L = length(temp);
NFFT = 2^nextpow2(L); % Next power of 2 from length of y
Y = fft(temp,NFFT)/L;
Fs = 1; % one sample per month
f = Fs/2*linspace(0,1,NFFT/2+1); % frequency 
Pxx = 2*abs(Y(1:NFFT/2+1)); % power

% Plot single-sided amplitude spectrum.
plot(f,Pxx,'-k'); 
xlabel('Frequency (c/month)'); % cycles per unit time

which results in the following plot.

enter image description here

What should the units be for the yaxis? Should it be ^{o}C?

The range of the time series is approx 20, so I guess 10 would work as the amplitude...

Emma Tebbs
  • 1,457
  • 2
  • 17
  • 29
  • Have you seen http://stackoverflow.com/questions/1523814/units-of-a-fourier-transform-fft-when-doing-spectral-analysis-of-a-signal ? Also, I think the x-axis units should be 1/month, not C/month (eg, the temperature goes up and down every day, whether it's reported in F or C, it's still a 1 day cycle). – tom10 Jan 13 '16 at 21:28
  • Thanks. The c/month refers to cycles per month. In this case it is 0.083 cycles per month, which is approx one cycle per year – Emma Tebbs Jan 13 '16 at 21:40
  • Sorry to be picky, but since your other unit is "C", of the three items on the x-axis not to spell out fully, "cycles" is probably not the best choice. – tom10 Jan 13 '16 at 22:29
  • Since there's an arbitrary factor freedom between `fft` and `ifft` from the mathematical definition (the important thing is that F(F^-1(...)) should give you a factor of 1/2pi total), it's often meaningless to assign a specific unit to the Fourier transform. So you could use "arbitrary units" for that. – Andras Deak -- Слава Україні Jan 13 '16 at 22:56
  • @tom10 makes sense. I will change it accordingly. – Emma Tebbs Jan 14 '16 at 10:43

1 Answers1

1

Let's say the original axes were T (vertical) and t (horizontal); after the transform, they are Y and X.

You correctly found that the units of X are reciprocals of the units of t. This is necessary for formulas like exp(2*pi*i*t*X) to make sense: the product t*X must be unitless.

Parseval's identity can be used to infer the units on the vertical axis. According to it,

(T units)2 (t units) = (Y units)2 (X units)

hence Y units = (T units) (t units). In your case this is degree-times-second, but this is better expressed as degree-per-frequency unit.

Indeed, the function produced by Fourier transform is amplitude density, expressing how much oscillation is there in every particular frequency range.

  • Thanks for the answer. So, the y-axis in my case could be |P(f)|(degC) where f stands for 'frequency' - thus representing degC per unit frequency, and so at the peak demonstartes 10 degC at that particular frequency? Or should I just write it as 'amplitude density' or |P(f)| ? – Emma Tebbs Jan 14 '16 at 10:57
  • "Amplitude density" is easier to swallow than the weird units. By the way, what I wrote is based on the understanding that the variable of your horizontal axis is continuous (as the line graph suggests). If you had it discrete, with a column for each frequency, then the units would be simply degrees. It's the same distinction as between discrete and continuous random variables: probabilities vs probability density. –  Jan 14 '16 at 14:36