HuntsvilleEngineers mark
HE Reference Shelf — huntsvilleengineers.com
The Reference Shelf · Analysis & Transforms

Nyquist-Shannon sampling theorem and aliasing

Sample faster than twice the highest frequency in the signal and the samples hold everything; sample slower and the high frequencies don't disappear — they come back wearing a lower frequency's name.

Also known as: Nyquist–Shannon sampling theorem · sampling theorem · Nyquist rate · aliasing · Nyquist frequency · Nyquist-Shannon sampling theorem · Nyquist criterion (sampling) · frequency folding · anti-aliasing

The formula

The theorem: if x(t) contains no frequency components at or above B hertz, then

f_s > 2·B

is sufficient to determine x(t) completely from its samples — the sample train carries the entire waveform, not an approximation of it [1].

Two terms that get swapped constantly and shouldn't be:

Nyquist rate = 2·B — a property of the signal: the minimum rate that can capture it.

Nyquist frequency = f_s / 2 — a property of the digitizer: the highest frequency this sample rate can represent [1].

What an out-of-band tone turns into (the aliasing formula):

f_apparent = | f − k·f_s |, with k the integer that puts the result between 0 and f_s/2 — every input frequency lands somewhere in the first Nyquist band, invited or not [7].

Perfect reconstruction, when the condition holds (Whittaker–Shannon interpolation, T = 1/f_s):

x(t) = Σ x(n·T) · sinc( (t − n·T)/T ), where sinc(u) = sin(π·u)/(π·u) — hang one sinc on every sample and sum; the original waveform reappears exactly, between the samples included [1]. (Checked numerically: a 3 Hz sine sampled at 10 S/s rebuilds to within 2·10⁻⁴ using ±2000 terms.)

Where you meet it

  • Setting up a vibration DAQ on a test stand. The analysis band goes to 2 kHz, so the sample rate goes to at least 4 kS/s — and the fielded convention is f_s = 2.56·f_max, 5,120 S/s, because the anti-alias filter needs room to roll off between the band edge and f_s/2. That 2.56 is not superstition; it's the guard band, standardized into nearly every vibration front end.
  • A strain channel logged at 50 S/s that shows a slow, clean 10 Hz wobble nobody can explain mechanically. Line hum at 60 Hz folds across the 25 Hz Nyquist frequency: |60 − 1·50| = 10 Hz. The "structural response" is the facility's power wiring.
  • A switching-supply clock at 1.02 MHz leaking into an ADC sampled at 1 MS/s. It shows up as a 20 kHz tone drifting through the passband — in-band, plausible-looking, and completely fictitious. This is the alias that survives design review, because 20 kHz was on the requirements sheet and 1.02 MHz wasn't.
  • The review board question: "justify your sample rate." The wrong answer is the theorem alone. The right answer is the theorem plus the anti-alias filter's attenuation at f_s/2, plus what's actually present above the band of interest — because the ADC will digitize whatever reaches it, spec'd or not.

How it works

Sampling multiplies the signal by an impulse train, and the spectral picture is the whole story: the signal's spectrum gets copied at every multiple of f_s. If the original spectrum is narrower than f_s/2, the copies don't touch and a low-pass filter can pull the original back out untouched. If it's wider, the copies overlap, and the overlapped region is a sum you cannot un-sum. That is aliasing, and it is permanent — no post-processing, no resampling, no filter applied after the ADC recovers what folded in. The information was destroyed at the sampling instant.

The folding behaves like a mirror at f_s/2. Run the input frequency upward and the apparent frequency climbs to f_s/2, reflects, comes back down to zero at f_s, and repeats. Verified numerically:

900 Hz sampled at 1 kS/s  →  appears at 100 Hz  (and phase-inverted: the samples of
                              sin(2π·900·t) equal the samples of −sin(2π·100·t))
 60 Hz sampled at 100 S/s →  appears at 40 Hz
 70 kHz sampled at 48 kS/s →  appears at 22 kHz

The phase inversion on odd-zone reflections is why an aliased resonance in a transfer-function measurement doesn't just sit at the wrong frequency — it points the wrong way.

The gotchas that matter in practice:

  • The anti-alias filter must be analog and ahead of the converter. Digital filtering happens after sampling; by then the folding is done. Every proper DAQ channel has an analog low-pass in front of the ADC for exactly this reason, and every "we'll clean it up in software" plan for aliased data is a plan to clean up something that no longer exists.
  • Brick-wall filters don't exist, so 2·B is a floor, not a design point. A real filter needs octaves to fall. An 8th-order Butterworth cut off at 1 kHz is down 112 dB at 5 kHz (checked) — so a 10 kS/s rate behind it works. Drop the rate to 2.5 kS/s and that same filter is only ~16 dB down at the new 1.25 kHz Nyquist frequency (checked), and strong out-of-band content walks right in. Even a full octave of guard band buys only ~24 dB from a 4th-order filter, ~48 dB from an 8th; the 56 dB a 4th-order delivers takes 5× the cutoff. Sample rate buys filter simplicity; filter order buys sample rate. You pay one of them.
  • Sampling at exactly 2·B fails on paper and on the bench. A sine at exactly f_s/2 sampled at its zero crossings produces all zeros — the strict inequality in the theorem is doing real work [1]. In practice the last usable frequency sits comfortably below Nyquist, which is why CD audio put Nyquist at 22.05 kHz for a 20 kHz band and vibration systems use the 2.56 ratio.
  • Nothing physical is truly bandlimited. A bandlimited signal must run forever in time; real signals start and stop, so their spectra never actually terminate. The theorem's condition is an engineering approximation you enforce with the anti-alias filter — the filter doesn't just protect the measurement, it manufactures the hypothesis the theorem needs.
  • Undersampling on purpose is legitimate. The requirement is really f_s > 2·(bandwidth), not twice the highest frequency, provided the band sits cleanly inside one Nyquist zone. RF and IF digitizers alias a 70 MHz IF down on purpose; Kotelnikov's original 1933 paper already treated the bandpass case [3]. Deliberate aliasing is a tool. Accidental aliasing is a corrupted test.
  • The bench check: if a tone in your data might be an alias, change the sample rate a few percent and re-acquire. Real signals stay put; aliases move by k times your change. Two minutes, and it has settled arguments that re-running a full test article shake would not.

The mistake people actually make is trusting the instrument's headline rate. A DAQ "capable of 2 MS/s" multiplexed across 16 channels is sampling each channel at 125 kS/s, and if the anti-alias filters are fixed wideband to support the headline number, every channel is now an aliasing risk at the reduced rate. Read the filter spec, not the brochure.

History

The mathematics arrived long before the engineering needed it. In 1915, E. T. Whittaker, working on interpolation theory in Edinburgh, showed that a function whose spectrum is limited can be threaded exactly through equally spaced table values by a sum of sinc functions — he called it the cardinal function, and his "tabular interval" is our sampling interval [1][3]. No radio in sight; he was solving a table-lookup problem.

The engineering half started at Bell Labs. Harry Nyquist, a Swedish-born engineer studying telegraph transmission, published "Certain Topics in Telegraph Transmission Theory" in 1928, showing that a channel of bandwidth B supports up to 2·B independent pulses per second [1][9]. Nyquist never posed the reconstruction problem — his was a telegraph result, not a sampling theorem — but he had isolated the fundamental role of the 1/(2·B) interval [2][3].

The first person to state the sampling theorem precisely, as communication engineering, was Vladimir Kotelnikov, a 25-year-old Soviet engineer, in a 1933 paper prepared for the First All-Union Conference on Questions of Communications in Moscow — seven theorems, lowpass and bandpass both [3][4][5]. Published in Russian in a military communications volume, it went essentially unread in the West for decades; Russian literature still calls this Kotelnikov's theorem [1][5]. Herbert Raabe rediscovered the result independently in his 1939 Berlin dissertation [2][3].

Claude Shannon stated the theorem as Theorem 13 of his 1948 "A Mathematical Theory of Communication" and proved it in "Communication in the Presence of Noise," published in January 1949 — a manuscript he had substantially in hand around 1940, held up by the war [1][3][6]. Shannon claimed no priority: he noted the result had appeared among mathematicians but not in communication theory, and he named the 1/(2·W) spacing the "Nyquist interval" himself, which is how Nyquist's name got welded onto a theorem he never stated [3]. The word "alias" came a year later, from John Tukey and Richard Hamming's 1949 Bell Labs work on noise spectra; Blackman and Tukey put it into the open literature in 1958 [7][8]. Four countries, five decades, one theorem — and the name still depends on which side of it you learned first.

Related tools

  • /tools/adc-resolution — bits set the amplitude floor; Nyquist sets the frequency ceiling. A converter spec is both.
  • /tools/snr-enob — quantization noise is spread across the band from 0 to f_s/2; oversampling widens the band the noise dilutes into
  • /tools/rc-filter — the simplest anti-alias filter, and the reason a one-pole rolloff rarely suffices at low oversampling ratios
  • /tools/frequency-period — sample interval T = 1/f_s, the quantity the whole theorem is priced in
  • /tools/rms-peak — an aliased tone still contributes true RMS; the level is right and the frequency is a lie
  • /tools/vibration-natural-freq — know your structure's modes before you pick f_max, or the alias check comes later and costs more
  • /tools/crest-factor — sharp transients carry energy far above the analysis band, exactly the content the anti-alias filter has to catch

Sources

  1. https://en.wikipedia.org/wiki/Nyquist%E2%80%93Shannon_sampling_theorem
  2. https://ieeexplore.ieee.org/document/755459
  3. https://sites.bu.edu/mark/files/2018/02/196.pdf
  4. https://en.wikipedia.org/wiki/Vladimir_Kotelnikov
  5. https://www.comsol.com/blogs/the-origin-story-of-the-sampling-theorem-and-vladimir-kotelnikov
  6. https://www.historyofinformation.com/detail.php?id=61
  7. https://en.wikipedia.org/wiki/Aliasing
  8. http://www.stat.uchicago.edu/~pmcc/reports/tukey.pdf
  9. https://en.wikipedia.org/wiki/Harry_Nyquist

Written by HE in our own words from the cited sources — engineering judgment included, your stamp still required. All entries →

★ The Reference Shelf

Reading is free. The shelf is for cardholders.

Your library card is an email address: pin it to your shelf, print the card, take the FE/PE quick-reference pack, read the Huntsville history. The shelf remembers what you reach for.

Already on the list? Enter with your subscribed email →