Nyquist Sampling Calculator
Work out the minimum sampling frequency a signal needs, or the highest signal frequency a given sampling rate can handle, using the Nyquist sampling theorem fs ≥ 2 fmax.
Inputs
Result
Step-by-step working
Formula
- fs(min) = 2 fmax
- fmax = fs / 2
The Nyquist sampling theorem says a signal can be reconstructed from its samples only while it contains nothing above half the sampling rate. One cycle needs at least two samples to be recognisable, so the sampling frequency fs must be at least twice the highest frequency fmax present in the signal; half the sampling rate is called the Nyquist frequency.
Sampling exactly at that limit is not a sensible design target. A real converter puts an anti-aliasing filter in front of the sampler to remove everything above fs / 2 before it is sampled, and that filter needs a transition band, so the sampling rate is normally chosen well above twice the highest frequency of interest. Clock jitter, noise and an imperfect filter all eat into any margin, and anything above the Nyquist frequency folds back into the band as an alias rather than disappearing.
About this calculation
The Nyquist–Shannon sampling theorem says that a signal must be sampled at least twice per cycle of its highest frequency component — fs ≥ 2 × fmax — if it is to be reconstructed without loss. Sample more slowly and content above half the sample rate (the Nyquist frequency) folds back to a lower frequency, which is aliasing: the whistle in a badly sampled audio recording, or a rotating wheel that appears to turn backwards.
Assumptions and limits
- The input must be band-limited. A signal with energy above fmax aliases however fast it is sampled, so an analogue anti-alias filter is needed ahead of the converter.
- Sampling at exactly 2 × fmax is the mathematical minimum, requiring perfect filtering. Real designs leave headroom, which is why audio is sampled at 44.1 kHz or 48 kHz for a 20 kHz band.
- The theorem says nothing about amplitude accuracy: how finely the samples are measured is a separate question, covered by ADC resolution.
A worked example
Speech and music are treated as occupying up to about 20 kHz, so the minimum rate is 40 kS/s; CD audio's 44.1 kS/s leaves a 2.05 kHz guard band for the anti-alias filter, which cannot be built with an infinitely sharp cutoff.
See also ADC Resolution and Frequency / Period.