Foiler


This past year, I have done a lot of coursework in quantum field theory. I found that I was spending a much higher percentage of my total effort on brute force computation than I would have liked. My go-to calculators, however, could not handle Lorentz contraction, which was crucial for the amplitudes I was computing. So I developed a Python script to simplify these computations for me.

It is reasonably user-friendly and well-commented. It does not accept or prompt command line input. You need to open the script in your favorite code editor (I used Spyder), scroll to the bottom where I have included a scratch work example, replace the example computation with whatever computation you would like to run, and then run the script. The output will be "printed."


Here is the .py code file for download, as of 05/24/23: Foiler.py


If you or your browser are (understandably) afraid of downloading strangers' .py files, here is the same script as raw text:

Here is the .txt code file for download, as of 05/24/23: Foiler.txt




Image taken from Romao and Silva (2012)