The pyBoLaNO package is fully based on the SymPy symbolic package and serves as a complement for its bosonic ladder operator features that have yet to be implemented.
Are you tired of doing a cumbersome bosonic ladder operator algebra with complicated commutation relations and keep making mistakes in the page-long derivation but do not realize until you are at the end? We are.
At ver. 1.0.2, this package offers you useful functions to do your algebra, including:
- Normal-ordering any polynomial of bosonic ladder operators.
- Normal-ordering any commutator of two polynomials of bosonic ladder operators.
- And this is what motivates us to do this: evaluating the normal ordering of any expectation value evolution equation for systems described in the Linbdlad Master Equation framework using bosonic ladder operators.
What's more, it works for multipartite systems!
You can install the package via pip:
pip install pybolano
or
pip install git+https://github.com/hendry24/pyBoLaNO
The core working principle of pyBoLaNO is simple; the package is based on the commutation relations, i.e.,
allows the user to normal-order any polynomial of bosonic ladder operators. It separates each monomial in the input (most generally a polynomial) by the subscripts of the ladder operators. For each subscript, normal ordering is performed using Blasiak's formulae (see Eqs. (4.2), (4.10), (4.34), (4.37) of his thesis linked above). Lastly, the algorithm moves the operators with different indices (which commute) around to give a nice-looking output.
allows the user to evaluate the any commutation relation of two polynomials of bosonic ladder operators.
It is just a shorthand to save you the time of typing normal_ordering(A*B-B*A).
allows the user to compute the normal-ordered expression for the expectation value evolution of a quantity represented by the operator
Inside LME_expval_evo, the function Hamiltonian_trace is called to evaluate the contribution from the Hamiltonian, while dissipator_trace is called to evaluate the contribution from each dissipator term indexed
We provide a quick tutorial of this package, in the file tutorial.ipynb in the repository tree. Here is a quick link that will take you there. The notebook includes examples of use alongside a more detailed explanation of the way the package works.
Pitiful as it may be, researchers nowadays are valued based on their citation counts. If you find our package helpful for your work, feel free to acknowledge the use of pyBoLaNO in your publications. Here is a bibtex entry you can copy:
@article{lim2025pybolano,
title = {pyBoLaNO: A Python symbolic package for normal ordering involving bosonic ladder operators},
author = {Hendry M. Lim and Donny Dwiputra and M. Shoufie Ukhtary and Ahmad R. T. Nugraha},
journal = {Computer Physics Communications},
volume = {313},
year = {2025},
pages = {109622},
DOI = {10.1016/j.cpc.2025.109622}
}
If you are interested in how we handle the peer review from the original version to the latest version of the preprint manuscript, we also provide a preprint folder in this repository in addition to the arXiv page.
This program is far from perfect and we would appreciate any critics and suggestions that you may have. In particular, we would appreciate it if you could inform us of any bugs you encounter while using this package. Feel free to reach out to us via email to [email protected].
Enjoy the package. \( ゚ヮ゚)/
- The authors.