EMsoft is an open source package for the simulation of electron diffraction patterns and images for both SEM and TEM modalities. The package has been under development since the late 1990's and is currently available as version 3.1 from a GitHub repository [1]. The main component of the package is a source code library of functions and subroutines that cover crystallography, symmetry, electron scattering factors, geometry, rotation representations, basic image filters, defect displacement fields, reciprocal space sampling schemes, and so on. The code is mostly written in fortran-90, with occasional routines making use of the C-bindings that are available in fortran-2003. A second library covers routines used to read and write files in the open source HDF5 (Hierarchical Data Format) file format [2], which is the default format for all computational results. At the time of writing of this abstract, more than 200, 000 lines of source code have been written, about half of which are available via the source code repository. An attempt has been made to make use of modern software development tools. The package build process is controlled by the open source CMake package, a flexible environment for the automated creation of Makefiles (on UNIX-based platforms). To compile EMsoft, a Software Developer Kit (SDK) must first be generated; this SDK currently consists of the following packages: CMake, HDF5, CLFor-tran, jsonfortran, and fftw, and is built first as a sand-boxed set of libraries. The EMsoft package links against the SDK; during standard package builds, two libraries are generated, one containing a large number of fortran-90 modules, the other containing all the code that employs the HDF5 libraries. To maintain a reliable code base, test routines are being developed to exercise all components of EMsoft during a nightly automated build for Mac OS X (open source gfortran compiler) and Windows 10 (commercial ifort compiler). The majority of programs in the EMsoft package receive their input via fortran name list files, a standard fortran IO mechanism that allows for lists of name-value pairs to be read using a single read command. Alternatively, some programs are also capable of reading the JSON format (JavaScript Object Notation), which essentially allows for similar lists of name-value pairs to be read. To maintain the history of a particular simulation, all input parameter files are automatically made part of the HDF5 output files, so that the user can always reconstruct the input parameters used for that simulation. One of the main guiding principles behind the design of the EMsoft package is the notion that electron scattering in SEM and TEM is described by basically the same physics; the main differences are the microscope accelerating voltage, which is a factor of ten smaller in SEM than in TEM, and the placement of the detectors. An additional distinction, the use of bulk samples for SEM and thin foils for TEM, is becoming less important, now that characterization modalities are available to study TEM foils in the SEM; transmission Kikuchi diffraction (TKD) is one such technique that has seen increased attention in recent years. The core modules of EMsoft have been written in a way that is independent of the imaging or diffraction modality for which they are being used. For instance, a single routine is used to generate the multi-beam dynamical matrix for TEM (e.g., CBED or STEM-DCI) and SEM (e.g., ECP or ECCI) simulations. Similarly, the implementation of the Bethe potentials to reduce the size of the dynamical matrix is independent of the modality for which the routine is being used. In addition to the Bloch wave eigenvalue approach to dynamical scattering, EMsoft also implements the 212
CITATION STYLE
Singh, S., Ram, F., & De Graef, M. (2017). EMsoft: open source software for electron diffraction/image simulations. Microscopy and Microanalysis, 23(S1), 212–213. https://doi.org/10.1017/s143192761700174x
Mendeley helps you to discover research relevant for your work.