Moderation note: The first two posts of this thread were split from this thread.
I don’t know where to post this and this will probably be lost but here goes.
There is a piece of code that has been copy-pasted for years, containing a function “rng_uniform” to generate random numbers. I’ve seen it in this thread, on this forum in other threads, on the blender stack exchange, etc. it’s used in various contexts to get uniform random numbers for example out of the cell noise function.
The code has a typo in it. Every copy I’ve seen has the same typo. It uses the magic number 2137483647. The correct value is 2147483647, (note the third digit). This is Mersenne prime number M31 (2^31-1).
I don’t think it’s particularly critical for the type of randomness expected but I just wanted to get this written down somewhere.