Python Basic MC - Allen-Tildesley/examples GitHub Wiki
Hit-and-miss and sample-mean
The two programs hit_and_miss.py
and sample_mean.py
illustrate two very simple
Monte Carlo methods to estimate the volume of a 3D object.
They are both described in detail at the start of Chapter 4.
No user input is required.
For the built-in values defining the geometry, the exact result is 5/3.