For Monte Carlo simulation with same code same algorithm, how fast is Julia compared with Fortran?

MersenneTwister() is the default random number generator used in Julia v1.6. Note, however, that it is not MT19937, but dSFMT. The dSFMT is two to three times faster than MT19937, and the quality of the generated random numbers is higher.

Julia v1.7 and later uses another random number generator as default, which is relatively light on initialization and has throughput as fast as dSFMT.

If you want to compare Julia and Fortran on simple Monte Carlo methods, you can write a Monte Carlo code for \pi in Fortran and compare it with the Julia version at the following links.

I think it is a waste of time to argue about something that may turn into a fruitless dispute, and we should give priority to repeated verification using concrete code.

8 Likes