Skip to main content

Traceon

Traceon is a Python library designed for the modeling of electron microscopes.

Traceon features a Boundary Element Method (BEM) solver that computes electrostatic and magnetostatic fields for accurate particle tracing. By relying on the BEM rather than FEM, Traceon offers notable improvements in speed and accuracy compared to most commercial alternatives. It supports both radially symmetric and fully 3D geometries, while leveraging advanced axial field interpolations to greatly speed up the particle tracing.

Wait, is this commercial?

The core of Traceon is completely free to use and open source, and distributed under the MPL 2.0 license. The software downloaded when using pip install traceon does not include any closed source software. There is a commercial package called traceon_pro which builds on the traceon package to provide a more capable library.

Feature Traceon Traceon Pro
Parametric mesher ✅ ✅
Plot module ✅ ✅
Radial symmetric solver (electrostatic, magnetostatic) ✅ ✅
Radial symmetric particle tracer ✅ ✅
Radial symmetric axial interpolation (fast tracing) ✅ ✅
3D direct solver (electrostatic, magnetostatic) ✅
3D solver using fast multipole method ✅
3D particle tracing ✅
3D axial interpolation (fast tracing) ✅
Coulomb interaction ✅

Documentation

Website

Examples

API documentation v0.10.0

API documentation v0.9.0

Installation

Install using the Python package manager:

pip install traceon

The installation is known to work on Linux, Windows and Mac OS. Please reach out to me if you have any installation problems.

Validations

To ensure the accuracy of the package, different problems from the literature have been analyzed using this software. See /validation directory for more information. The validations can easily be executed from the command line, for example:

python3 ./validation/edwards2007.py --help
python3 ./validation/capacitance-sphere.py --help
etc...

License

MPL 2.0

Help! I have a problem!

Don't worry. You can reach me.

Open an issue

Send me an email

Gallery

Image of 3D deflector Image of Dohi mirror Image of Einzel lens traces

Release notes

v0.10.0

  • Make Field a GeometricObject (which can be moved, rotated, etc)
  • Introduce FieldSuperposition class to represent summation of arbitrary fields
  • Add type hints throughout codebase
  • Add initial support for couloumb interactions while tracing (pro only)

Breaking changes

  • Tracer.__call__ now takes velocities with unit m/s instead of eV

v0.9.0

  • Add permanent magnets
  • Small improvements to geometry module (add annulus methods)
  • More general rotations for GeometricObject
  • Various bug fixes and improvements

Breaking changes

  • FieldRadialAxial was moved from solver.py to field.py

v0.8.0

  • New plotting module (charge density, equipotential lines)
  • Automatic orientation of normal vectors
  • Geometry functions for extruding/revolving edges of surfaces
  • Tracing of particles other than electrons (charge, mass as input)
  • Various bug fixes and improvements

Breaking changes:

  • Call P.show() after P.plot_mesh() to show figures
  • Normal vectors should be oriented automatically (please check if this works correctly for your geometry)

v0.7.0

  • Generate structured, high quality meshes using the new parametric mesher (drop GMSH)
  • Consistenly use 3D points and geometries throughout codebase
  • Add support for Fast Multipole Method (Traceon Pro)
  • Add support for Mac OS on x64
  • Big improvements to code quality, testing, infrastructure
  • Drop dependency on GSL

v0.6.0:

  • New methods to integrate triangle potential and field contribution over a triangle
  • Fix 3D convergence issues by more accurately calculating neighbouring triangle interactions
  • Fix error calculation in particle tracing
  • Introduce logging module to control verbosity of printing
  • Clean up unit tests
  • Remove higher order (curved) triangle support, in preparation of parametric meshers and improved FFM implementation

v0.5.0:

  • Add preliminary support for magnetostatics
  • Improve and generalize mesh class (allow import/export)
  • Make consistent use of SI units

v0.4.0:

  • Introduce Fast Multipole Method (FMM) for large 3D problems
  • Compute 3D radial expansion coefficients using analytical formulas
  • Further speed up computation of 3D radial expansion coefficients
  • Big code quality improvement of validation/ files

v0.3.0:

  • Use adaptive integration using GNU Scientific Library (GSL)
  • Add support for boundary constraint
  • Use Vedo for better plotting capabilities
  • Use higher order triangle elements for 3D (curved triangles)
  • Precompute jacobians/positions for better performance
  • First implementation of element splitting based on charges (work in progress)

v0.2.0:

  • Use higher order charge distribution on line elements in radial symmetry
  • Use higher order line elements (polynomials) in radial symmetry
  • Better integration techniques, especially with regards to the logarithmic singularities

v0.1.0:

  • Uses the powerful GMSH library for meshing
  • Solve for surface charge distribution using BEM
  • General 3D geometries and radially symmetric geometries
  • Dielectrics
  • Floating conductors
  • Accurate electron tracing using adaptive time steps
  • Field/potential calculation by integration over surface charges
  • Fast field/potential calculation by radial series expansion
  • Superposition of electrostatic fields

Metadata

Release files for traceon 0.10.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for traceon 0.10.0
File Size Uploaded
traceon-0.10.0.tar.gz 95.5 kB Details

Built distributions (wheels)

Table of built distributions (wheels) for traceon 0.10.0
File Interpreter ABI Platform
traceon-0.10.0-cp37-abi3-win_amd64.whl CPython 3.7 abi3 Windows x86-64 Details
traceon-0.10.0-cp37-abi3-manylinux_2_31_x86_64.whl CPython 3.7 abi3 Linux glibc 2.31+ x86-64 Details
traceon-0.10.0-cp37-abi3-macosx_13_0_x86_64.whl CPython 3.7 abi3 macOS 13.0+ x86-64 Details

Total release size: 571.5 kB

Release files / traceon-0.10.0.tar.gz

Download URL traceon-0.10.0.tar.gz
Size 95.5 kB
Tags Source
SHA-256 checksum
How to use checksums
440ef2ebc020791805a6a1f164a41ea1fa3d3655ab459f16f15d24af62a09104
BLAKE2b-256 checksum
How to use checksums
cafa8baba09943ad0bb08a575b29b90e09038d1053bc55d327a6a8b59084eb08
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.1.0 CPython/3.8.18

Release files / traceon-0.10.0-cp37-abi3-win_amd64.whl

Download URL traceon-0.10.0-cp37-abi3-win_amd64.whl
Size 180.3 kB
Tags CPython 3.7 Windows x86-64 abi3
SHA-256 checksum
How to use checksums
68427d89ec69f4c21ba509b99be7fd374abec66c9ec396ce3aac7d93af25a5ff
BLAKE2b-256 checksum
How to use checksums
a6ca40c6e939aefd06d6141647e484a32e2918ecc8cf3cbfffc080d24ff9142c
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.1.0 CPython/3.8.18

Release files / traceon-0.10.0-cp37-abi3-manylinux_2_31_x86_64.whl

Download URL traceon-0.10.0-cp37-abi3-manylinux_2_31_x86_64.whl
Size 165.6 kB
Tags CPython 3.7 Linux glibc 2.31+ x86-64 abi3
SHA-256 checksum
How to use checksums
12c3165a565961e7f8176649ae4ca5d87f689a71df748ae367372b1de52425ca
BLAKE2b-256 checksum
How to use checksums
8e09066c9b867949d91cbf17733bc21a344cb646be0af7bed11cc2039d96d5de
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.1.0 CPython/3.8.18

Release files / traceon-0.10.0-cp37-abi3-macosx_13_0_x86_64.whl

Download URL traceon-0.10.0-cp37-abi3-macosx_13_0_x86_64.whl
Size 130.1 kB
Tags CPython 3.7 abi3 macOS 13.0+ x86-64
SHA-256 checksum
How to use checksums
e2db4059a3f738668ab17dc7da7452d9af855ef86cf67ae492aacf965b62652e
BLAKE2b-256 checksum
How to use checksums
162083ee11f78b2b4b9e235ae816f0693f2c200157cc47f3506fbdba3554ae15
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.1.0 CPython/3.8.18
Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page