help-gsl
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Help-gsl] Quick FFT question


From: Inigo Aldazabal Mensa
Subject: Re: [Help-gsl] Quick FFT question
Date: Wed, 23 Jul 2008 10:06:37 +0200
User-agent: KMail/1.9.5

El Martes, 22 de Julio de 2008 18:37, Nghia Ho escribió:
> Hi,
>
> I need to implement an algorithm that makes use of the FFT to do some
> basic signal processing. Basically, given an array of numbers I would
> like to extract the coefficients of the N lowest frequency components.
>
> The GSL document says the results are laid out such that index from 0 to
> N/2 are the positive frequencies and the rest are negative. My
> mathematical knowledge of FFT is limited so please bare with me on the
> next question. I see the real values are the same for both
> positive/negative side, but imaginary values flip.

This is so because your input signal is Real (I mean, Real numbers). In 
this case the values form the positive/negative frequencies are complex 
conjugate of each other, as you say. See eg[1] for more info and 
references.

> So if I take the 
> magnitude (|Re + Imz|) of the first N values of the positive side would
> that give me what I want?
>

I don't know what exactly do you mean by |Re + Imz|,   but if you take  the 
modulus of the complex number,   |z|=sqrt(a*a+b*b), being z=a+ j b, 
j=sqrt(-1), this |z| will be equal for each semiaxis, i.e |z(w)|=|z(-w)|, 
and gives you the frequency spectra for your signal. For this see 
e.g. "The Scientist and Engineer's Guide to Digital Signal Processing"
By Steven W. Smith, Ph.D., chapter 8, specifically section "Polar Notation" 
[2]. If you are new to DFT take a look to  the whole chapter, and also to 
the next one "Applications of the DFT", it will be worth it.

[1]http://en.wikipedia.org/wiki/Discrete_Fourier_transform#The_real-input_DFT 
[2]http://www.dspguide.com/ch8/8.htm





reply via email to

[Prev in Thread] Current Thread [Next in Thread]