1 << 29
BNUM.to_f
Use xorshift
123456789
362436069
521288629
88675123
21 22 23 24 25 26 27 28
# File 'ext/enterprise_script_service/mruby/benchmark/bm_ao_render.rb', line 21 def self.rand x = @@x t = x ^ ((x & 0xfffff) << 11) w = @@w @@x, @@y, @@z = @@y, @@z, w w = @@w = (w ^ (w >> 19) ^ (t ^ (t >> 8))) (w % BNUM) / BNUMF end