A simple Landau definition to be used in Python, since no common package (Scipy, Numpy, ...) provides this. Also a fast Landau + Gauss convolution is offered, that is usefull for fitting energy losses of charged particles in matter. The Landau is approximated according to Computer Phys. Comm. 31 (1984) 97-111 and the implementation is from CERN ROOT Mathlibs.
The project is hosted at PyPI. For installation just type:
pip install pylandau
If you want to change the code or start contributing download it and put it into a directory of your choice. From the project root folder run:
pip install -e .
import numpy as np
import pylandau
x = np.arange(0, 100, 0.01)
y_landau = pylandau.landau(x)
y_langau = pylandau.langau(x)