Ef is a software for simulation of charged particles dynamics. It's primary areas of application are accelerator science and plasma physics.
Single particle in uniform magnetic field;
Widening of a ribbon beam during the propagation
Ribbon beam in uniform magnetic field
Potential of electron beam inside conducting tube;
Volt-Ampere characteristic of a planar diode
Ef focuses on non-relativistic energies. Particular emphasis is placed on low-energy beams, such that can be found in ion sources and electron guns. A motivation behind the program, the scope and the general goals are discussed here.
Particles dynamics is traced under action of external electromagnetic fields. Particle self-interaction is taken into account with particle-in-cell method. Detailed description of the mathematical model can be found here.
Attention is given to integration with CAD software to allow for simulation of complex real-life experimental setups. An experimental plugin for FreeCAD exists.
Ef is a free software -- it's source code is open and avaible for modification and redistribution. Python (this one) and C++ versions are available. Python version is easy to install and experiment with. It's speed should be sufficient to perform example computations and small-scale simulations but for large-scale simulations C++ version is the choice.
Current features are described in detail in appropriate wiki sections, as well as installation procedure. Some usage examples are also given.
It's advisable to use a virtual python environment:
virtualenv --python=python3 ef_venv
. ef_venv/bin/activate
EF is not available in pypi yet, install from github:
pip install 'git+https://github.com/epicf/ef_python.git'
Start simulation defined by my_config.conf:
ef my_config.conf
Continue simulation from hdf5 file my_0005.h5:
ef my_0005.h5
git clone https://github.com/epicf/ef_python.git
cd ef_python
virtualenv --python=python3 venv
. venv/bin/activate
pip install -r requirements.txt
pip install -e .
Install pytest:
pip install pytest pytest-mock
Run fast unittests:
pytest
Run more tests (including slower examples)
pytest -m 'not (slow)'
Run every test (including slow simulation examples)
pytest -m ''
More python versions and test types.
- Install tox:
pip install tox
- Run
tox
Can also run in parallel with detox
.
Start simulation defined by my_config.conf:
ef my_config.conf
Continue simulation from hdf5 file my_0005.h5:
ef my_0005.h5