A set of guided exercises for classroom or self-study use. Each one introduces a different aspect of the Fourier transform and the relevant tools in the app. Try to predict the outcome before clicking Compute or Apply.
Exercise 0 — Build a chessboard from Fourier-space pixels
Create an empty image (top toolbar → New). With the paint brush in panel 2, place pixels in Fourier space. Can you create a chessboard pattern in real space?
Exercise 1 — High-, low-, band-pass and directional filters
Load an image. Apply high-pass, low-pass and band-pass filters, as well as directional and line filters from the panel-2 tool column. Try to first predict the effect of each filter on the real-space image before clicking Apply.
Exercise 2 — Restore an image with the Fourier eraser
Load the restauration_512.png image. Inspect it in
Fourier space (panel 2). Use the eraser tool to
remove suspicious peaks there and observe how the real-space image
changes.
Exercise 3 — Intact vs anisotropic EM images
Load intact and anisotropic electron microscopy images. Inspect them both in real space (panel 1) and in Fourier space (panel 2). What distinguishes the two in each domain?
Exercise 4 — Lattice filtering of crystals and periodic scenes
Load the 2d_protein_crystal and Polyhead_virus
images. Use the Lattice filter to obtain the protein
maps.
Then load the Biozentrum_Basel_Eyes image. In Fourier
space, use the lattice filter to either keep only the periodic
content, or to delete the periodic content (toggle
Erase outside lattice). Compare the two results.
Exercise 5 — Denoise a noisy apple with the lattice filter
Load a noisy apple image. Are you able to use the lattice filter to remove the noise? This requires precision in positioning the basis vectors.
Exercise 6 — Convolution theorem with Andreas
Load andreas_1024.png (-> g). Use a lattice filter with vectors
(4, 0) and (0, 4), and a 1-pixel mask
radius. Explain the effect using the convolution theorem.
Then create an empty image with the "New image" function (1024 size -> h).
Use the paint brush to manually place a few pixels into it (pixel value 1, diameters 1).
Convolute that newly created image with Andreas (Math calculation: i = g * h). Inspect the result.
Correlate the result with Andreas (Math calculation: j = i × g).
High-pass flatten the cross-correlation map j (Band pass filter in Fourier space, inner diameter 50, erase pixels outside of band).
Run a peak search on the high-pass filtered cross-correlation map and create a list of peaks.
Inspect the peaks in real space and Fourier space. Do they correspond to the pixels you placed in the image? Can you use the peak list to
extract particles (128-pixel size) from the convoluted map i into a new slot? Do the extracted particles look like Andreas?
Use in Fourier space the lattice filter (smooth edge: 0, diameter 1, lattice vectors (4,0) and (0,4)) to obtain the average particle from the extracted particles.
Does it look like Andreas?
Exercise 7 — Phase ramp and the shift theorem
Load an image. Create a phase ramp in a different slot (panel-2 tool column). Look at it in Fourier space in the "Amplitude and Phase" mode.
Multiply this phase ramp with the Fourier transform of the image using Math calculation. What do you observe to happen with the image?
Exercise 8 — Real-space convolution vs Fourier multiplication
Load Fourier_text and Fourier_word and use
the Math calculation function to convolute them in
real space. Adjust the histogram to visualise the highest peaks.
Alternatively, multiply their Fourier transforms in Fourier space. Compare the results — they should match up to a constant factor.
Exercise 9 — Cross-correlation, picking and lattice averaging
Load a single particle protein image (a) and a particle
template (b). Cross-correlate them with
c = a × b using Math calculation.
Apply a high-pass to the cross-correlation map
c with inner radius 100.
Run peak search on the cross-correlation map
c. Inspect the picked particles on a.
Extract 64-pixel particles from a into
slot d.
Use a lattice filter with exactly (16, 0) and
(0, 16) on d to obtain the average
particle (not rotationally aligned).
Exercise 10 — Helix synthesis
Load an image of a fibril cross-section into a buffer (a)
and use the Amyloid function template to create a fibril projection image with that cross-section.
Alternatively, draw a cross-section with the paint brush and create a fibril from that.
Can you create a synthetic fibril image that in Fourier space resembles the Fourier transform of a real fibril image, especially concerning the reflection line at 4.75 Å?
Exercise 11 — CTF FIT: measuring defocus and astigmatism
This exercise uses the Exercise_11-CTF data set: twelve
simulated cryo-EM micrographs (Example_….mrc) available
from the example-image loader. Each is 1024 × 1024 pixels at
2 Å/pixel, imaged at 300 kV with
Cs = 2.7 mm, and each was generated with a
known defocus and astigmatism (the ground truth is listed in
ctf_ground_truth.csv, and the file names encode the mean
defocus and the astigmatism, e.g. Example_325nm_50nm.mrc).
The goal is to recover those values with the CTF FIT tool
and check how close the fit gets.
Load one of the examples into a buffer and press the up-arrow to compute its
Fourier transform — you should see Thon rings in panel 2. Confirm the
pixel size shown under panel 1 reads 2 Å (double-click it
to edit if needed); the fit relies on it for the frequency scale.
Activate CTF FIT (the CTF / FIT icon in
panel 2). Enter 300 kV and 2.7 mm, select the
input buffer, set the resolution band (start with a lower limit of about
30 Å and an upper limit of about 4 Å),
and press Execute. Read the fitted defocus and
astigmatism reported in the window and compare them with the
ground-truth value for that image.
Inspect the composite that appears on the Fourier side of the buffer: the right half is the fitted CTF, the top-left quarter the original transform, and the bottom-left quarter its astigmatism-aware radial average. In a good fit the rings line up continuously across the vertical midline, and the elliptical rings of the radial average match the raw rings above it.
Now experiment:
- Change the resolution band. What happens if you include only very low frequencies, or push the upper limit past where the rings are still visible?
- Try a high-defocus example (e.g.
Example_5000nm_0nm.mrc) and a strongly astigmatic one (e.g.Example_300nm_200nm.mrc). Which parameter is easier to measure, and why? - Note that CTF FIT reports astigmatism as the full peak-to-peak difference df1 − df2, while the values it copies into the CTF SIM fields use CTF SIM's amplitude (half-difference) convention. Feed the fitted values into CTF SIM and confirm the simulated rings reproduce the ones you measured.
Exercise 12 — CTF SIM: generation with amplitude contrast and beam tilt
Choose an empty image buffer.
Use the CTF SIM tool (the CTF / SIM icon in panel 2) to create a CTF with different defocus settings. How does the defocus affect the CTF in Fourier space and the PSF in real space?
Then, try to generate CTFs with different values of energy spread (try 3eV for LaB6, 0.7 for FEG, 0.3 for coldFEG, 0.1 for monochromator electron sources). Try different opening angles (0.1 mrad, 0.5 mrad, 1 mrad), which correspond to how parallel the beam is in illuminating the sample.
How do the energy spread and opening angle affect the CTF in Fourier space and the PSF in real space? How do these parameters affect the Thon rings in Fourier space, or the coherence of the PSF in real space?
Finally, try different values of amplitude contrast and beam tilt. Inspect the resulting CTF in Fourier space, and in real space. How do the amplitude contrast and beam tilt affect the CTF?
The real-space correspondent of the CTF is a point spread function (PSF). How do the amplitude contrast and beam tilt affect the PSF?
Try to generate a CTF with these parameters: 300 kV, 500 nm underfocus, 67 nm astigmatism, 5 mrad beam tilt. You will see a CTF with near perfect Thon rings, but the real-space PSF will be very anisotropic. This anisotropy in real space is called the "coma" and is a direct consequence of the beam tilt. If you have beam tilt in your microscope and correct it by setting (wrong) astigmatism parameters in the CTF, you will see that the Thon rings become round but now your microscope is misaligned and the PSF becomes distorted. In such cases, the correct solution is a Zemlin Tableaux acquisition and correction of the beam tilt, not a CTF astigmatism correction.