[Date Prev][Date Next][Thread Prev][Thread Next]
- Subject: Re: Am I misunderstanding random numbers?
- From: Fernando P. García <fernando@...>
- Date: Tue, 16 Mar 2010 13:28:47 -0500
luuid is your friend: http://www.tecgraf.puc-rio.br/~lhf/ftp/lua/#luuid
On Tue, Mar 16, 2010 at 1:24 PM, Christopher Eykamp <firstname.lastname@example.org>
Even a poorly designed random number generator should generate different streams from different seeds. Is it possible that lua is not passing the seed off to the system's random function properly in some implementations?
On 3/16/2010 11:18 AM, Geoff Leyland wrote:
On windows I got the same results as Christopher.
Lua just uses the system's rand, and what you're learning is that rand isn't a great random number generator, and that Windows' implementation is not the best. lhf's lrandom is surely better: http://www.tecgraf.puc-rio.br/~lhf/ftp/lua/
Fernando P. García, http://www.develcuy.com
+51 1 9 8991 7871, Calle Santa Catalina Ancha #377, Cusco - Perú
** Before printing this message, please consider your commitment with the environment, taking care of it depends on you.
** Antes de imprimir este mensaje piensa en tu compromiso con el medio ambiente, protegerlo depende de tí.