Aliasing

Summary: When a signal is sampled at some sampling rate, the maximum frequency that sample can represent is twice the sampling rate. In images, the sampling rate is the pixel size. Thus, the pixel size sets an upper bound on the best resolution achievable for a given set of images.

Aliasing

In the physical world, signals are continuous. The pressure waves which make up sound vary smoothly between high and low pressure; light waves which form images vary from light to dark, etc. However, computers must represent these signals with discrete samples. When we sample a signal, we take measurements of that signal at evenly spaced positions in space or time.

For a concrete example, consider the samples below:

Seven dots, clearly arranged along a single cycle of a sine wave

By eye, it seems obvious that these samples come from a simple sine wave which oscillates once:

The seven points are connected by a sine wave which oscillates once

However, these samples are explained just as well by a wave which oscillates seven times:

The same seven points are now connected with a sine wave which oscillates seven times

or thirteen times:

The same seven points are connected by a wave which oscillates thirteen times

Indeed, there are in fact an infinite family of waves which perfectly fit any finite set of samples. There is no way of knowing which of these infinite waves truly gave rise to the samples we observe, so by convention we select the lowest-frequency wave which fits the observed data. However, what happens when there really is high-frequency information in our images which our samples cannot capture?

Nyquist Frequency

Say you collect an image of some object using a camera sensor which is 12 Å wide and has 6 pixels. Your pixel size is therefore 2 Å. Put another way, you are sampling the incoming image with a sampling rate of 12A˚\frac{1}{2 \AA} , or one sample for every two Å. If your object is a sine wave which oscillates with a frequency of 112A˚\frac{1}{12 \AA{}}, the image is unambiguous:

The same set of points are shown twice. At top, they are connected by a sine wave which oscillates once. On the bottom, they are connected by steps at the height of each sample, and a dotted wave which oscillates once.

There are plenty of samples along the entire wave to accurate capture its shape. What happens when the wave’s frequency increases?

The wave at the top now oscillates twice, and the steps at the bottom also oscillate twice. The dotted wave is correct, also oscillating twice.

When you image an object with a wavelength of 6 Å, the result is still correct. The exact position of the object relative to the pixels has imposed some asymmetry in the image, but if the object shifted left or right the result would again be symmetric.

What about an object with even higher frequency?

The wave at the top now oscillates four times. At the bottom, the steps only oscillate twice, so the dotted wave only oscillates twice as well. The phase of the steps and dotted wave are also flipped.

When the object has a wavelength of 3 Å, the samples line up perfectly with samples from a 6 Å wave as well. Because we always take the lowest frequency wave that explain our data, we incorrectly interpret our image as resulting from a 6 Å wave. This incorrect result is called “aliasing” and is an important effect in SPA.

The frequency beyond which aliasing occurs is called the Nyquist frequency, and is half the sampling frequency.

fNyquist=12×fsampling=2×1pixel sizef_{\mathrm{Nyquist}} = \frac{1}{2} \times f_{\mathrm{sampling}} = 2 \times \frac{1}{\mathrm{pixel\ size}}

Put another way, any spatial features in the object which are smaller than twice the pixel size will be aliased in the image. This results in the commonly quoted maximum resolution for a particle stack of twice the image pixel size.

Frequencies faster than the Nyquist frequency alias to the frequency below Nyquist and the same distance away from it. This operation is commonly described as “folding over” the Nyquist frequency. Note also that in the 3 Å wavelength example above, the aliased 6 Å wave has opposite phase. This is another property of aliasing: the “folding” operation also flips the phase of the aliased wave.

An arrow pointing up at a frequency of 0.6 times the sampling frequency is "folde" across the Nyquist frequency to become an arrow pointing down (representing a phase shift) at 0.4 times the sampling frequency

The phase flipping here is a property of all discrete representations of continuous signals. It is distinct from the specific mechanism of phase inversion that occurs in the electron microscope, which is modeled by the CTF.

In the animation below, the moment the true frequency crosses the Nyquist frequency the aliased wave begins to decrease in frequency, rather than increase, since it is folding over the Nyquist frequency.

CTF Aliasing

Just as particle images are represented with pixels in real space, their Fourier transform is represented with pixels in Fourier space. The box in Fourier space is the same size as the box in real space, but each pixel represents a certain range of frequencies rather than a certain region of space. Specifically,

1 Fourier pixel=1N×pixel size\mathrm{1\ Fourier\ pixel} = \frac{1}{N \times \mathrm{pixel\ size}}

where N is the box size in pixels and the pixel size is the size of a pixel in the real space image. For instance, if a particle is represented with a box of 128 pixels which each represent 2 Å, the Fourier space particle image has a Nyquist frequency of 12×128A˚1=1256A˚1\frac{1}{2 \times 128} \mathrm{\AA{}^{-1}} = \frac{1}{256} \mathrm{\AA{}^{-1}}. If the CTF oscillates with a frequency greater than this, the contrast transfer function will be aliased.

Consider the true contrast transfer function of an image collected in a typical electron microscope used in single-particle analysis (300 kV, 2.7 Cs) with 2 µm defocus.

A graph of the contrast transfer function

However, we cannot capture the full, continuous contrast transfer function. We must model it from our images, which are sampled using discrete Fourier pixels. If the Fourier pixels are small, the resulting image of the contrast transfer function may look like this:

The sane CTF as above, but discretely sampled. A the highest frequencies the amplitude is slightly off, but the overall signal is correct.

At the higher frequencies there is some disruption of the amplitude, but the representation is mostly accurate. However, if the Fourier pixels are too large, the contrast transfer function will be significantly aliased.

The same CTF as above, but now the sampling rate is too low to accurately capture the CTF.

In this rather extreme example, the contrast transfer function modeled from the image (black) is significantly different from the true contrast transfer function (grey), especially past approximately 4 Å. This happens because in this region the contrast transfer function starts oscillating more quickly than the Nyquist limit of the Fourier space image. The high-frequency contrast transfer function oscillations are therefore aliased to incorrect lower frequencies.

This effect is more pronounced with:

  • higher defocus values, which increase the true oscillation rate of the CTF,

  • smaller pixel sizes, which increase the real space Nyquist limit, requiring the Fourier image to represent a larger region of the CTF, and

  • smaller box sizes, which reduce the sampling rate in Fourier space.

Since defocus cannot be changed after acquisition, if significant CTF aliasing is observed, the remaining means of removing it are therefore

  • downsampling, which “zooms in” on a subregion of the CTF by removing higher frequencies, or

  • using a larger box which gives more pixels in Fourier space to represent the CTF.

Four graphs of the CTF are shown. At the top is the continuous CTF. Below that, the aliased CTF shown previously. Third from the top, the aliased CTF is shown for a downsampled image. This produces a CTF which only extends to around 4 Å, where aliasing is not significant. Finally, the CTF is shown from a bigger box. The larger box means the CTF has more samples, reducing aliasing.

Of course, the problem of contrast transfer function aliasing is often rendered moot by the poor signal-to-noise ratio of cryo-EM data. For instance, even the severely-aliased example above more-or-less correctly models data up to the resolution to which the CTF fits the data well.

Last updated