BioDeviceHub

Nyquist Sampling Rate Calculator

Check whether a sampling rate is high enough for a signal, find the minimum rate required, and see the false frequency that appears when the signal is undersampled.

Formula

fs,min⁡=2 fmax⁡f_{s,\min} = 2\,f_{\max}
fN=fs2f_N = \dfrac{f_s}{2}
falias=∣ f−fs⋅round⁡ ⁣(ffs)∣f_{\text{alias}} = \left|\,f - f_s\cdot\operatorname{round}\!\left(\dfrac{f}{f_s}\right)\right|
ff
a frequency present in the signal
fsf_s
sampling rate
alias\text{alias}
the frequency at which an undersampled component appears

How it works

A signal can be reconstructed from its samples only if it is sampled faster than twice its highest frequency. Half the sampling rate is the Nyquist frequency, the highest frequency the sampled data can represent.

Anything above the Nyquist frequency does not vanish. It folds back and appears as a lower, false frequency that cannot be told apart from real signal afterwards. This is why an analogue anti-aliasing filter sits in front of the converter in every acquisition system.

Worked example

A signal with content up to 150 Hz is sampled at 250 Hz.

  1. Minimum rate = 2 × 150 Hz = 300 Hz, so 250 Hz is too slow.
  2. Nyquist frequency = 250 / 2 = 125 Hz.
  3. Alias = | 150 − 250 × 1 | = 100 Hz.

The 150 Hz component appears as a false 100 Hz signal. Sampling at 500 Hz, the rate recommended for diagnostic ECG, avoids it.

These are the values the calculator opens with, so you can check its output against this example.

Assumptions

  • The highest frequency entered really is the highest present, which in practice requires a filter to enforce.
  • Ideal sampling at uniform intervals.

Common mistakes

  • Sampling at exactly twice the signal frequency. Real systems need a margin above the minimum because filters are not ideal.
  • Relying on digital filtering to remove aliasing. It has to be prevented before sampling.
  • Judging the required rate from the signal of interest alone and forgetting higher-frequency noise and interference.

Related equipment

Service documentation, failure modes and parts for the instruments this calculation is used with.