University of Limerick
Landers_2023_TGYM.pdf (1.74 MB)

TEMGYM Advanced: Software for electron lens aberrations and parallelised  electron ray tracing

Download (1.74 MB)
journal contribution
posted on 2023-05-29, 14:36 authored by David LandersDavid Landers, IAN CLANCYIAN CLANCY, Rafal E. Dunin-Borkowski, Andrew Stewart

Characterisation of the electron beams trajectory in an electron microscope is possible in a few select commercial software packages, but these tools and their source code are not available in a free and accessible manner. This paper introduces the free and open-source software TEMGYM Advanced, which implements ray tracing methods that calculate the path of electrons through a magnetic or electrostatic lens and allow evaluation of the first-order properties and third-order geometric aberrations. Validation of the aberration coefficient calculations is performed by implementing two independent methods – the aberration integral and differential algebra (DA) methods and by comparing the results of each. This paper also demonstrates parallelised electron ray tracing through a series of magnetic components, which enables near real-time generation of a physically accurate beam-spot including aberrations and brings closer the realisation of a digital twin of an electron microscope. TEMGYM  Advanced represents a valuable resource for the electron microscopy community, providing an accessible and open source means of characterising electron lenses. This software utilises the Python programming language to complement the growing ecosystem of free and open-source software within the electron microscopy community, and to facilitate the application of machine learning to an electron microscope digital twin for instrument  automation. The software is available under GNU Public License number Three (GPL 3). 



Ultramicroscopy, 2023, 250, 113738



Other Funding information

The research was supported by the Irish Research Council EPSPG/2019/509 and the Ernst Ruska-Centre for Microscopy and Spectroscopy with Electrons (ER-C)

Department or School

  • Physics

Usage metrics

    University of Limerick


    No categories selected