Electronic – Sampling frequency required to detect peaks

digital-logicfftsignalspectrum

I am processing a signal in the digital domain and I have to detect "peaks" in it, e.g. by finding local maxima formed by three consecutive values. (More sophisticated criteria could be used like setting a minimum peak height or peak width.)

If I know the behavior of the signal spectrum, is there a way to choose the sampling frequency to make sure not to miss a peak ? Is there theory about this ? Is there a relation to the Nyquist limit ?

Best Answer

In principle, if your input signal is strictly band-limited, and has no content above some frequency F, then it can be perfectly reconstructed from samples taken at sampling frequency fs, if fs > 2 F. This is the Nyquist-Shannon limit. If you can perfectly reconstruct the signal, you ought to be able to find some way to perfectly identify the peaks.

In practice, it's rare to actually be able to create a perfect reconstruction. Either because the input signal isn't truly band-limited (it has some tail beyond what we think of as the bandwidth), or because the sampling process has some noise, or jitter, or errors, or because we don't want to go to the trouble of using sinc interpolation in the reconstruction, which is what's needed to properly reconstruct a signal from minimal samples.

I think you will want to oversample by at least 2x - 4x, but how much is needed will depend on how much math you're willing to put in to the reconstruction. Unfortunately I can't point you to any particular methods of finding peaks using minimum sampling rate.

Edit

As Kortuk points out, the length of time you sample for (number of samples) will also affect your ability to reconstruct a signal perfectly. Even if you are looking for time-domain peaks rather than frequency-domain peaks, this could come in to play. However if your sample period is smaller than the resolution you want for determining the peak time, you should be okay.