This simulator works computing the field created by point sources with random phases and randomly placed inside a circle.
Time averaging is done using Monte Carlo integration.
Then, the simulation is represented and animated with matplotlib.
Check my youtube video for further explanation: https://www.youtube.com/watch?v=ySte6NRuA-k&list=PLYkZehxPE_IhJDMTJUob1ZbxWhL8AjHDi&index=1
Just clone or download this repo. The package requeriments are:
- numpy
- matplotlib
- progressbar
To perform the simulations, just run from the command prompt the corresponding Python scripts:
python simulation_femtoseconds.py
python simulation_picoseconds.py
python simulation_microseconds.py
Also take a look at the simulations of the double slit experiment with incoherent and coherent light