
From:  Damian Harty 
Subject:  RE: I Need Help.. 
Date:  Fri, 22 Nov 2013 17:09:19 +0000 
**********example*********** l = rows(original_data); a = fft(original_data); < perform an FFT with the default options for i = (1:l) if i >9 a(i) = 0; < zero the results of the FFT for all but the first 9 values endif endfor b = fft(ec); < another fft of something called ec – what is that? for i = (1:l) if i > 1 b(i) = 0; < zero everything except the 0Hz (DC) term endif endfor c = real(ifft(b)); < this should, I think, return the DC value of signal ec c(1); d = real(ifft(a))*2c(1); < inverse fourier of the manipulated fft, only the first 9 terms *********************************
There are some quirks with FFTs. I find it a bit strange that only the real values are used, I would have used the magnitude of the FFT returns and not the real parts. Multiplying by 2 is necessary because the fft contains information mirrored about zero; terms at zero and the Nyquist frequency don’t need multiplying by 2 but all the others do. See, for example, Numerical Recipes on this matter.
I’m not sure how much of that you knew already, apologies if I have only helped with the obvious bits.
Unresolved for me is
1) Why only use the real part of the results? 2) Why use the DC part from another signal?
Damian CONFIDENTIAL: The information contained in this email communication is confidential information intended only for the use of the addressee. Unauthorized use, disclosure or copying of this communication is strictly prohibited and may be unlawful. If you have received this communication in error, please notify us immediately by return email and destroy all copies of this communication, including all attachments. 
[Prev in Thread]  Current Thread  [Next in Thread] 