Code simulating various STM techniques, especially for tilting tips (depending on ProkopHapala/ProbeParticleModel ) This is implementation of efficient and simple model for simulation of High-resolution scanning tunneling microscopy (STM). Normall STM simulations using Chen's approximattion is part of the code as well
- BEWARE - after repairing misteake in d-orbitals the results for FePc are different. We are investigating it.
- currently developed Python3/C++ version of the PPSTM code:
- works in python3.12, matplotlib, cpp>=4.4.8 (look at wiki instruction for problems with MAC compilation), PyQt5 (for GUI ),for some parts ASE and GPAW are imporatant;
- Part of the code regarding simulations with tilting tips is depending on the PPAFM developed by Prokop Hapala and co. (https://github.com/Probe-Particle/ppafm), you can easilly install it with
pip install ppafm>=0.2.0a3.
For easy introduction to this code and its functionalities, try Graphic User Interface (GUI) or PPSTM_simple.py script.
Constant current simulations are now available through const_cur_tutorial.ipynb jupyter notebook from npz or xsf. There is also former Mathematica notebook which works only with xsf.
Documentation is here at Wiki.
It can also simulate IETS images of molecules, if the imaging mechanism is driven by the amplitude of the IETS peak.
A simple setup with CONDA Conda on Linux is:.
conda env create -f environment.yml
conda activate ppstm
python -m ipykernel install --user --name=ppstmMore details can be found on a dedicated Wikipage.
After activating the ppstm-dev environment, you can run the test suite with:
pytest tests -vThis runs all tests in verbose mode.
Measure code coverage to identify untested code paths.
To show coverage statistics by file and list lines not covered by tests:
pytest --cov=pyPPSTM --cov-report term-missing testsTo create a detailed HTML report with coverage by file, function, and class:
pytest --cov=pyPPSTM --cov-report html:coverage testsOpen coverage/index.html in your browser to explore the results interactively.