[Numpy-discussion] zoom FFT with numpy?

Charles R Harris charlesr.harris at gmail.com
Wed Mar 14 23:40:10 EDT 2007


On 3/14/07, Ray S <subscriber100 at rjs.org> wrote:
>
> We'd like to do what most call a "zoom FFT"; we only are interested
> in the frequencies of say, 6kHZ to 9kHz with a given N, and so the
> computations from DC to 6kHz are wasted CPU time.
> Can this be done without additional numpy pre-filtering computations?
>
> If explicit filtering is needed to "baseband" the data, is it worth
> it? It sounds like we need to generate cosine data once for each band
> and N, then multiple with the data for each FFT.
>
> Has anyone coded this up before? I couldn't find any references other
> than http://www.dsprelated.com/showmessage/38917/1.php
> and http://www.numerix-dsp.com/siglib/examples/test_zft.c (which uses
> Numerix).


Sounds like you want to save cpu cycles. How much you can save will depend
on the ratio of the bandwidth to the nyquist. Generally, it is easiest to
just fft, but if the band is very narrow and time matters, you might try:

1) explicit multipy by the transform matrix but only use a few rows.
2) frequency shift, {low pass}, and downsample
3) just downsample and fix up the aliasing

Much depends on the length of the data run and what the signal to noise is.
Google indicates that the zoom fft is 2 without the low pass, which is fine
if you don't need optimum s/n in the result. Should be easy to cook up your
own routine.

Chuck
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/numpy-discussion/attachments/20070314/f82105ec/attachment.html>


More information about the NumPy-Discussion mailing list