You are on page 1of 3

Warning! Due to system upgrades, ni.

com may be unavailable from 8:00 PM Friday, February 5 - 3:30 AM CST Sunday, February 07

Aliasing and Sampling at Frequencies Above the Nyquist Frequency


Publish Date: Nov 18, 2014
Overview

Return to Fundamentals of High-Speed Digitizers (http://zone.ni.com/devzone/cda/tut/p/id/3408)


This tutorial recommends tips and techniques for using National Instruments high-speed digitizers to build the most effective data
sampling system possible. In this tutorial, you will learn fundamental information about the underlying theory of sampling with a
high speed digitizer and various methods to optimize the performance of your data sampling. This section of the tutorial covers the
topics below.

Table of Contents

1. Aliasing
2. Undersampling and Oversampling
3. Undersampling to Obtain Frequencies Above the Nyquist Frequency
1. Aliasing

One of the limitations of discrete-time sampling is an effect called aliasing.

Figure 1. Wagon wheel


An example of aliasing can be seen in old movies, especially when watching wagon wheels on old Western films. Recall that
occasionally the wheels appeared as if they going in reverse, even as the wagon would speed up. This phenomenon occurs as the
rate of the wagon wheel's spokes spinning approaches the rate of the sampler (the camera operating at about 30 frames per
second).
The same thing happens in data acquisition between the sampler and the signal we are sampling.
The Nyquist Theorem (http://zone.ni.com/devzone/cda/tut/p/id/2709) states that you need 2 samples per cycle of your input
signal to define it. Thus, you can accurately measure the frequency of a signal with frequency f as long as you are sampling it at
greater than 2f. If you try to measure the frequency of signals having a frequency above f with a sampler operating at 2f, you will
alias the signal, or create false images of this signal at frequencies below f. These false frequencies will appear as mirror images
of the original frequency around the Nyquist frequency. This situation is called "aliasing back" or "folding back" and can be seen in
Figure 2 below.

1/3

www.ni.com

Figure 2. Frequency versus amplitude plot showing an aliased signal, fa, which occurs due to "aliasing back" from the
original signal of 70MHz
where
R (sampling rate) = 100MS/s
fs (signal being sampled = 70MHz
fN (the Nyquist frequency) = 50MHz
fa (aliased frequency) = 30MHz
The frequency of the aliased signal can be found from the following simple equation:
fa = |R*n - fs|
where n is the closest integer multiple of the sampling rate (R) to the signal being aliased (fs).

Although sampling at twice the Nyquist frequency will ensure that you measure the correct frequency of your signal, it will not be
sufficient to capture the shape of the waveform. If the shape of the waveform is desired, you should sample at a rate
approximately 10 times the Nyquist theory.
You can interactively view the effects of aliasing on a signal by running this LabVIEW Player enabled (
http://zone.ni.com/devzone/explprog.nsf/webmain/D6837AB4364512D486256937005B5927?OpenDocument)Example (
http://zone.ni.com/devzone/cda/epd/p/id/1267) (
http://zone.ni.com/devzone/explprog.nsf/webmain/D6837AB4364512D486256937005B5927?OpenDocument).
The LabVIEW Player allows you to run VIs from your web browser and can be downloaded for free.
The problem of aliasing can often be eliminated by using an anti-alias filter (
http://digital.ni.com/public.nsf/3efedde4322fef19862567740067f3cc/68f14e8e26b3d101862569350069e0b9?OpenDocument).
2. Undersampling and Oversampling

Undersampling is essentially sampling too slowly, or sampling at a rate below the Nyquist frequency for a particular signal of
interest. Undersampling leads to aliasing and the original signal cannot be properly reconstructed. However, undersampling also
requires less memory, so it may be useful in certain applications, see "Undersampling to Obtain Frequencies Above the Nyquist
Frequency" below.
Oversampling is sampling at a rate beyond twice the highest frequency component of interest in the signal and is usually desired.
Because real-world signals are not perfectly filtered and often contain frequency components greater than the Nyquist frequency,
oversampling can be used to increase the foldover frequency (one half the sampling rate) so that these unwanted components of
the signal do not alias into the passband. Oversampling is also necessary when trying to capture fast edges, transients, and
one-time events.
3. Undersampling to Obtain Frequencies Above the Nyquist Frequency

Suppose that you would like to sample a signal with a primary, strong signal at 70MHz for an extended period of time. If you were
to set this frequency as the Nyquist frequency then you would want to sample at 140MHz in order to accurately measure the
frequency of your signal. However, the maximum limit of your PCI bus is 133MHz and sampling at 140MHz will fill your input buffer
too quickly, how then can you accurately measure your signal?

2/3

www.ni.com

too quickly, how then can you accurately measure your signal?
You can overcome the effects of aliasing on your signal if you understand how your sampled signal will appear. However, this
technique must be used with caution. The signal you are measuring should be strong with no other strong frequency components
close to it on the frequency spectrum. Additionally, it is highly advisable to sample as nearly as possible to twice the Nyquist
frequency in order to not bring in frequency components of integer multiples of your original signal. Following these cautions will
ensure that the signal you are attempting to sample is not polluted by an aliased signal from another frequency.
Suppose you are sampling your 70MHz signal with a digitizer that has a maximum sampling rate of 100 megasamples per second
(MS/s) and a bandwidth of 100MHz, this situation has been set up in Figure 2. If you are sampling at 100MS/s then your Nyquist
frequency is 50MHz. Thus, the 70MHz signal that you are sampling will be aliased back and appear as an image at 30MHz (70 is
20 greater than the Nyquist frequency of 50 and so the aliased signal will occur as a mirror image at 20 less than 50, or 30). Now,
by placing a high-pass, external filter of 60MHz upon the incoming signal, all real frequency components below 60MHz will be
attenuated and all that will be left is the aliased image at 30MHz of the real signal at 70MHz. Because the bandwidth of the
digitizer is 100MHz, the 70MHz signal and its aliased image will both have the same, slightly attenuated magnitude which should
be easy to recognize.
Related Links:
Fundamentals of High-Speed Digitizers (http://zone.ni.com/devzone/cda/tut/p/id/3408)
The Fundamentals of FFT-Based Signal Analysis and Measurement in LabVIEW and LabWindows/CVI (
http://zone.ni.com/devzone/cda/tut/p/id/4278)
Utilizing Deep Memory on High-Speed Digitizers and Oscilloscopes (http://zone.ni.com/devzone/cda/tut/p/id/4734)

PRODUCT

SUPPORT

COMPANY

Order status and history (http://www.ni.com/status/)

Submit a service request (


https://sine.ni.com/srm/app/myServiceRequests)

About National Instruments (http://www.ni.com/compa

Order by part number (


http://sine.ni.com/apps/utf8/nios.store?action=purchase_form)

Events (http://www.ni.com/events/)
Manuals (http://www.ni.com/manuals/)
Careers (http://www.ni.com/careers/)

Activate a product (
http://sine.ni.com/myproducts/app/main.xhtml?lang=en)

Drivers (http://www.ni.com/downloads/drivers/)
Alliance Partners (http://www.ni.com/alliance/)

Order and payment information (http://www.ni.com/how-to-buy/)

MISSION
NI equips engineers and scientists with systems that accelerate productivity, innovation, and discovery.

(http://twitter.com/niglobal)
http://www.linkedin.com/company/3433?trk=tyah)

(http://www.facebook.com/NationalInstruments)
(http://www.ni.com/rss/)

(http://www.youtube.com/nationalins

Contact Us (http://www.ni.com/contact-us/)

(//privacy.truste.com/privacy-seal/National-Instruments-Corporation/validation?rid=bc6daa8f-7051-4eea-b7b5-fb24dcd96d95)
Legal (http://www.ni.com/legal/) | National Instruments. All rights reserved. | Site map (
http://www.ni.com/help/map.htm)

3/3

www.ni.com

You might also like