At the moment I can step through the frequency band of interest and take samples to estimate relative power at various frequencies. But this is slow. Is it effective to center myself in the band of interest, make sure my sample rate is high, and do an FFT instead? I'm just wanting to efficiently get relative power levels for frequencies throughout a band.

  • $\begingroup$ An FFT will get you the power across the entire band that you sampled (see Parseval's theorem); but I don't see how that saves you anything versus calculating the mean square in the time domain (unless you take advantage of knowing your signal is only in a smaller range of bins, then that could be a very good approach). If you happen to be dealing with "pure" tones there is an easier method to get the power of individual frequencies based on estimating magnitude. $\endgroup$ – Dan Boschen Jul 9 '16 at 17:45
  • $\begingroup$ @DanBoschen - What I'm hoping is that the FFT method will be simple - sample and calculate the fft, with the output array being relative strengths for each bin. As opposed to moving to a new frequency, sampling and calculating power, and repeating for each freq I want to monitor. Is that the case? $\endgroup$ – horse hair Jul 9 '16 at 18:03
  • $\begingroup$ It depends how your waveform of interest is distributed across bins. The total power of the signal that is sampled as derived from your FFT will be the sum of the squares of the magnitude of each bin. (With perhaps a proportional scaling.) If your signal is only significant across a few bins then this would be simple- but you would need to know which bins. $\endgroup$ – Dan Boschen Jul 9 '16 at 18:06

As far as I understand your question, you want to estimate the PSD in a large bandwidth.

What you're currently doing is tuning to one part of that bandwidth, receive samples at a low sampling rate, calculate the power in that small bandwidth, retune, and repeat.

So, yes, using a larger sampling rate will obviously reduce the time you need to sense a large bandwidth: A larger sampling rate will give you more spectral information.

The DFT->square method is one classical spectrum estimator. So, yes, instead of tuning $N$ times to receive an $N$th of the overall bandwidth $B$ by sampling at a rate of $\frac BN$, you could just as well sample with a rate of $B$, and calculate $N$-point DFTs in the same time. Since sampling the same time at rate $B$ gives you $N$ times the samples of sampling at $\frac BN$, the information would be the same (Nyquist/Shannon).

You might want to look into other spectral estimators, too – but for now, I don't really see a big disadvantage in simply using the DFT with an appropriate Window – and given the fact that neither the analog nor the digital filters on the RTL dongle probably are overly fantastic, I think you can just stick with a Hann window and be fine.


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.