Aberration Fitting

Aberration Surface Gradients

The cross-correlation vector shifts w(k)\vec{w}(\vec{k}) we computed in Cross-Correlation of Virtual Bright-Field Images are given by the gradient of the aberration surface χ(k)\chi(\vec{k}) Lupini et al., 2016

w(k)=χ(k),\vec{w}(\vec{k}) = \nabla \chi(\vec{k}),

where k\vec{k} is the 2D Fourier space coordinate (spatial frequency) and the aberration surface can be expressed using the following expansion Ophus et al., 2016

χ(k)=2πλm,n(λ  k)m+1m+1(Cm,nxcos[n×atan2(ky,kx)]+Cm,nysin[n×atan2(ky,kx)]),\begin{aligned} \chi(\vec{k}) = \frac{2\pi}{\lambda} \sum_{m,n} \frac{\left(\lambda \; |\vec{k}| \right)^{m+1}}{m+1} \Big( & C_{m,n}^x \cos{\left[n \times \mathrm{atan2}\left(k_y, k_x\right) \right]} + \Big. \\ \Big. & C_{m,n}^y \sin{\left[n \times \mathrm{atan2}\left(k_y, k_x\right) \right]}\Big), \end{aligned}

where λ is the (relativistically-corrected) electron wavelength, Cm,nx/yC_{m,n}^{x/y} are the Cartesian aberration coefficients of radial order m+1m+1 and angular order nn in units of ångströms.

Figure 1 investigates the effect of common aberrations and microscope geometry variations, away from the ground-truth values (relative rotation angle = -15°, and defocus = 1.5μm), on the apparent image shifts of virtual BF images and the aligned virtual BF stack.

Source:py4DSTEM Parallax Fitting Notebook
Common aberrations and microscope geometry effects on tcBF-STEM.
Notice the relative robustness of the aligned BF stack when the rotation_angle and defocus sliders are moved slightly away from their ground-truth values.
Other aberrations, such as astigmatism and coma, introduce more pronnounced effects.

Figure 1:Common aberrations and microscope geometry effects on tcBF-STEM. Notice the relative robustness of the aligned BF stack when the rotation_angle and defocus sliders are moved slightly away from their ground-truth values. Other aberrations, such as astigmatism and coma, introduce more pronnounced effects.

Aberration Fitting

Equations (1) and (2) form a linear system of equations suggesting that, given the measured vector shifts w(k)\vec{w}(\vec{k}), the aberration coefficients Cm,nx/yC_{m,n}^{x/y}, and hence χ(k)\chi(\vec{k}), can be estimated.

Specifically, we perform the following steps: Varnavides et al., 2023

  1. Estimate a 2x2 affine transformation, HH^(k,k)H\equiv\hat{H}(\vec{k},\vec{k}'), which maps the initial BF pixel positions, Vv(k)V\equiv\vec{v}(\vec{k}'), to the measured vector shifts, Ww(k)W\equiv\vec{w}(\vec{k}):
H=(VTV)1VTW.H = \left( V^T V\right)^{-1} V^T W.
  1. Decompose the affine transform into radial, PP, and rotational, UU, components – from which the passive rotation θ can be estimated:
H=UP,U=[cos(θ)sin(θ)sin(θ)cos(θ)].\begin{aligned} H &= U P, \\ U &= \begin{bmatrix} \cos(\theta) & \sin(\theta) \\ -\sin(\theta) & \cos(\theta) \end{bmatrix}. \end{aligned}
  1. Passively-rotate the Fourier coordinate system:
k(kx,ky)(kxcos(θ)+kysin(θ),kycos(θ)kxsin(θ)).\vec{k}'\equiv \left(k_x,k_y\right) \to \left(k_x \cos(\theta) + k_y \sin(\theta), k_y \cos(\theta) - k_x \sin(\theta)\right).
  1. Evaluate the linear system given by Equations (1) and (2) on k\vec{k}' to estimate aberration coefficients Cm,nx/yC_{m,n}^{x/y} up to speficied radial and angular orders Cowley, 1979Lupini et al., 2010Lupini et al., 2016

Figure 2 performs the least-squares fit for various radial and angular orders, and plots a comparison between the measured and predicted vector shifts using the following py4DSTEM snippet:

parallax = parallax.aberration_fit(
    fit_BF_shifts=True,
    fit_aberrations_max_radial_order=2,
    fit_aberrations_max_angular_order=0,
)
Source:py4DSTEM Parallax Fitting Notebook
Least-squares tcBF-STEM aberration fitting.
Notice how the fit is robust against including higher orders in the aberration expansion, despite the ground-truth shifts including only defocus.

Figure 2:Least-squares tcBF-STEM aberration fitting. Notice how the fit is robust against including higher orders in the aberration expansion, despite the ground-truth shifts including only defocus.

References
  1. Lupini, A. R., Chi, M., & Jesse, S. (2016). Rapid aberration measurement with pixelated detectors. Journal of Microscopy, 263(1), 43–50. https://doi.org/10.1111/jmi.12372
  2. Ophus, C., Rasool, H. I., Linck, M., Zettl, A., & Ciston, J. (2016). Automatic software correction of residual aberrations in reconstructed HRTEM exit waves of crystalline samples. Advanced Structural and Chemical Imaging, 2, 1–10. https://doi.org/10.1186/s40679-016-0030-1
  3. Varnavides, G., Ribet, S. M., Zeltmann, S. E., Yu, Y., Savitzky, B. H., Dravid, V. P., Scott, M. C., & Ophus, C. (2023). Iterative phase retrieval algorithms for scanning transmission electron microscopy. arXiv Preprint arXiv:2309.05250. https://doi.org/10.48550/arXiv.2309.05250
  4. Cowley, J. (1979). Coherent interference in convergent-beam electron diffraction and shadow imaging. Ultramicroscopy, 4(4), 435–449. https://doi.org/10.1016/S0304-3991(79)80021-2
  5. Lupini, A. R., Wang, P., Nellist, P. D., Kirkland, A. I., & Pennycook, S. J. (2010). Aberration measurement using the Ronchigram contrast transfer function. Ultramicroscopy, 110(7), 891–898. https://doi.org/10.1016/j.ultramic.2010.04.006