Got Questions? Get Answers.
Discover MakerZone

MATLAB and Simulink resources for Arduino, LEGO, and Raspberry Pi

Learn more

Discover what MATLAB® can do for your career.

Opportunities for recent engineering grads.

Apply Today

Thread Subject:
FFT of signal segments

Subject: FFT of signal segments

From: Dave Brackett

Date: 20 Oct, 2008 14:01:18

Message: 1 of 4

Hi, I have written some code to do a FFT based on this example but with a Hann window:
http://www.mathworks.com/support/tech-notes/1700/1702.html

I am basically doing a STFT (short time FT) and comparing frequencies and power over time. So I am splitting up a recorded signal into many segments and computing a FFT on each.

The thing that I am finding curious though is that the more segments that I split the signal into, the greater the power in the FFT for each segment. Should this be the case? I would have thought the opposite should be observed because of the reduction in power that windowing causes.

Because I am using a Hann window, I have divided the FFT magnitude by 0.5 which is the coherent gain scaling factor.
I could post my code here but as it is based on the example at the above link it probably would only serve to confuse.

If someone could clarify what I should expect to see when splitting the signal into several segments as compared to 1 segment, with regards to the power, that would be useful. Thanks.

Subject: FFT of signal segments

From: Steve Amphlett

Date: 20 Oct, 2008 14:40:17

Message: 2 of 4

"Dave Brackett" <davebrackett@hotmail.com> wrote in message <gdi2ve$cud$1@fred.mathworks.com>...
> Hi, I have written some code to do a FFT based on this example but with a Hann window:
> http://www.mathworks.com/support/tech-notes/1700/1702.html
>
> I am basically doing a STFT (short time FT) and comparing frequencies and power over time. So I am splitting up a recorded signal into many segments and computing a FFT on each.
>
> The thing that I am finding curious though is that the more segments that I split the signal into, the greater the power in the FFT for each segment. Should this be the case? I would have thought the opposite should be observed because of the reduction in power that windowing causes.
>
> Because I am using a Hann window, I have divided the FFT magnitude by 0.5 which is the coherent gain scaling factor.
> I could post my code here but as it is based on the example at the above link it probably would only serve to confuse.
>
> If someone could clarify what I should expect to see when splitting the signal into several segments as compared to 1 segment, with regards to the power, that would be useful. Thanks.

Your 0.5 will correct the amplitude. For energy correction, use sqrt(3/8). Most people would express the correction the other way up:

Multiply by 2 for amplitude, sqrt(8/3) for energy.

Subject: FFT of signal segments

From: Dave

Date: 20 Oct, 2008 14:50:45

Message: 3 of 4

On Oct 20, 3:40=A0pm, "Steve Amphlett" <Firstname.Lastn...@Where-I-
Work.com> wrote:
> "Dave Brackett" <davebrack...@hotmail.com> wrote in message <gdi2ve$cu...=
@fred.mathworks.com>...
> > Hi, I have written some code to do a FFT based on this example but with=
 a Hann window:
> >http://www.mathworks.com/support/tech-notes/1700/1702.html
>
> > I am basically doing a STFT (short time FT) and comparing frequencies a=
nd power over time. So I am splitting up a recorded signal into many segmen=
ts and computing a FFT on each.
>
> > The thing that I am finding curious though is that the more segments th=
at I split the signal into, the greater the power in the FFT for each segme=
nt. Should this be the case? I would have thought the opposite should be ob=
served because of the reduction in power that windowing causes.
>
> > Because I am using a Hann window, I have divided the FFT magnitude by 0=
.5 which is the coherent gain scaling factor.
> > I could post my code here but as it is based on the example at the abov=
e link it probably would only serve to confuse.
>
> > If someone could clarify what I should expect to see when splitting the=
 signal into several segments as compared to 1 segment, with regards to the=
 power, that would be useful. Thanks.
>
> Your 0.5 will correct the amplitude. =A0For energy correction, use sqrt(3=
/8). =A0Most people would express the correction the other way up:
>
> Multiply by 2 for amplitude, sqrt(8/3) for energy.


just to clarify, is the correction of energy the one to use when
plotting power?

also, I don't think the problem of the different FFT peak magnitudes
is to do with this correction factor as this just scales it by the
same amount.
cheers.

Subject: FFT of signal segments

From: Steve Amphlett

Date: 20 Oct, 2008 21:29:02

Message: 4 of 4

<snip, correction factors...


> > Your 0.5 will correct the amplitude. =A0For energy correction, use sqrt(3=
> /8). =A0Most people would express the correction the other way up:
> >
> > Multiply by 2 for amplitude, sqrt(8/3) for energy.
>
>
> just to clarify, is the correction of energy the one to use when
> plotting power?
>
> also, I don't think the problem of the different FFT peak magnitudes
> is to do with this correction factor as this just scales it by the
> same amount.
> cheers.

If you integrate the hanning window, you'll get the amplitude correction. If you integrate the square of the window, you'll get the energy correction.

Which correction you use is your choice and depends on your application. In the software that I write, I use amplitude for all plots of dB (I do acoustics) vs frequency. But anything that involves summation to get an overall level will require energy correction.

Tags for this Thread

What are tags?

A tag is like a keyword or category label associated with each thread. Tags make it easier for you to find threads of interest.

Anyone can tag a thread. Tags are public and visible to everyone.

Contact us