What is Mersenne Twister?

PHP has a function called rand. There is also a function called mt_rand.

I was studying about these functions and realized that in previous versions it was necessary to use such a "random number Sower".

One of them is the function called mt_srand.

In this excerpt of the PHP Manual I saw that there is a reference to the name Mersenne Twister. I realized then that this mt_ at the beginning of the function had something related.

I got to see on Wikipedia something, but I found it a little vague.

So I would like to kill this curiosity:

  • What is Mersenne Twister? Does it have anything to do with this Sower or the randomization process?
Author: Wallace Maxters, 2015-12-16

1 answers

I translate Wikipedia article about :

The Mersenne-Twister is a pseudo random number generator (PRNG). It is by far the most widely used general purpose pseudogenerator. Its name derives from the fact that its range is a number Prime of Mersenne.

Was developed in 1997 by Makoto Matsumoto (Mak本??) and Takuji Nishimura (西村 拓士?). It was developed specifically to rectify old problems encountered older pseudo-generators. It was the first pseudo-generator to provide fast generation of pseudorandom integers with quality.

The most common version of the algorithm used is based on Marsenne's cousin 219937-1. Its default implementation, MT19937, uses a 32-bit whole word. There is another implementation that uses a 64-bit word, MT19937-64, and that generates a very different sequence.

 3
Author: Leonel Sanches da Silva, 2020-06-11 14:45:34