When I was writing general purpose DSP algorithms, this was one of the most asked questions so I thought I would discuss the subject.

When performing a Fourier transform on a sine wave of magnitude +/- 1 then the output would represent the two phasors each of magnitude 0.5 that sum together to give the original sine wave.

However when performing an N point discrete Fourier transform (DFT or FFT) on the same, but now discrete, sine wave then the results are scaled by the factor N.

As an example, if you perform a 512 point DFT or FFT on a sine wave of magnitude +/- 1 then the un-scaled output phasors will have magnitude +/- 256.

While this is a minor inconvenience when using a floating point processor, it can be a major issue when using fixed point processing because of the overflow and scaling issues. Maybe fixed point programming should be the subject of a future blog ;-)

## No comments:

## Post a Comment