Instrumentation

Nyquist and aliasing: how fast to sample sensor data

After reading, you can set a sampling rate from your analysis band, recognise a false low-frequency peak caused by aliasing, and see why slow PLC or SCADA logs fall short for spectra.

In short
  • The sampling rate must be at least twice the highest frequency of interest, or components fold back into the spectrum.
  • Practical FFT analysers commonly sample at about 2.56 times the highest analysed frequency, as a margin.
  • PLC polling and historian compression add aliasing-like distortion and cannot replace high-rate vibration acquisition.

The Nyquist limit: fs and fmax

When you digitise a signal, the sampling rate fs sets the time between samples. The Nyquist–Shannon sampling theorem states that if the highest frequency in a signal is fmax, the sampling rate must be at least twice fmax for the signal to be reconstructed without distortion. That threshold is the Nyquist limit. In a digital measurement, fs/2 is the highest frequency that can be represented correctly.

When the condition is not met, the error is not only cosmetic. A false peak appears in the spectrum at a wrong frequency. High-frequency content you never intended to measure can fold down into the low-frequency range you are looking at. The theorem assumes a band-limited signal. Real sensor outputs always contain some high-frequency noise, so the limiting has to be done by an analogue filter before sampling.

Aliasing: how a frequency folds back

In sampled data, a component above fs/2 looks identical to a lower frequency. The apparent frequency is |f − k·fs|, where k is the integer nearest to f/fs. This effect is called aliasing, or frequency folding.

Two examples make the rule concrete. A 60 Hz vibration sampled at 50 Hz gives k = 1 and an apparent frequency of |60 − 50| = 10 Hz. A pulsation at 0.9 Hz read once per second has fs = 1 Hz, so the apparent frequency is |0.9 − 1| = 0.1 Hz. In both cases the data suggests a low-frequency event that is not in the signal.

Filter before the converter

Aliasing cannot be undone after sampling. For that reason, the anti-aliasing filter must be analogue and placed before the converter. It attenuates components above the band of interest before they are sampled. A digital filter applied later in software cannot remove an alias that has already been created.

Downsampling follows the same logic. Before you keep only every nth sample, apply a low-pass filter that removes content above the new Nyquist limit. Otherwise, high-frequency content folds into the new, lower band. The cut-off frequency should sit above the band of interest but below fs/2. If it is set too low, the analysis band itself is attenuated; if it is set too high, components near fs/2 fold down without being removed.

Hidden folding in PLC and historian data

A separate problem appears in the data path. A PLC or SCADA system reads values at fixed intervals. For example, with a one-second polling period, samples taken once per second can only represent changes below 0.5 Hz faithfully. Historian deadband or compression adds further distortion: it stores a new value only when the signal has changed enough, so the stored series is no longer a regular sampling of the process. The result can look like aliasing.

For that reason, do not build a high-frequency spectrum from slowly polled data. The effective sampling rate depends on every link in the acquisition chain, not only on the sensor.

Choosing the sampling rate

A practical rule starts with the highest frequency of interest, fmax, and sets fs from it. For spectra, FFT analysers commonly use fs of about 2.56 × fmax. That leaves a margin above the theoretical Nyquist minimum. If you also want to see the shape of the waveform, a rate of 5 to 10 times fmax is more suitable. For example, with fmax = 400 Hz, fs = 2.56 × 400 = 1 024 Hz, so fs/2 = 512 Hz. The transition band of the anti-aliasing filter must fit between 400 Hz and 512 Hz.

Choosing a band much wider than the fault frequencies you need also means more data and a higher fs than necessary, so limit the band to the frequencies of interest.

After you choose, check the spectrum near fs/2 and confirm it is flat or low there. Significant energy close to fs/2 can mean real content near the limit, or an anti-aliasing filter that is too gentle. Until you understand the cause, do not draw conclusions from data near fs/2.

A first check on your own system

Before you install a new measurement, write down the existing settings: the channel, the read or sampling rate, whether there is an analogue filter, and whether the historian compresses the data. Then run a small test. Connect a reference signal of known frequency, such as a function generator, and check that its peak appears where it should. If a peak moves when you change fs, it is most likely an alias.

This check matters when the data later feed machine learning or spectral diagnosis. Verify the measurement chain first, then choose the analysis method. Record the test results with the reference frequency, the chosen fs, the peak seen and an explanation of any difference. The record can then serve as a comparison after later changes to the system.

Frequently asked

Must the sampling rate be twice the highest frequency?

It must be at least twice the highest frequency of interest; that is the Nyquist limit. Practical FFT analysis commonly uses about 2.56 times the highest analysed frequency. For analysis up to 1 kHz, that gives about 2 560 Hz, so fs/2 is 1 280 Hz. Components above that limit must be attenuated by an analogue anti-aliasing filter before sampling.

Is a PLC or historian log enough for vibration analysis?

Usually not for spectra. SCADA polling and historian storage generally sample far too slowly for vibration frequencies, and deadband storage is not regular sampling. Vibration analysis needs a dedicated high-rate acquisition, an analogue anti-aliasing filter and documented settings.

Sources and further reading

Pilot steps in this guide are proposed engineering workflows. Examples do not constitute measured field performance.

Questions on this topic