Computer Chess Club Archives


Search

Terms

Messages

Subject: Re: Random keys and hamming distance

Author: Ron Murawski

Date: 07:03:30 08/17/02

Go up one level in this thread


On August 17, 2002 at 03:20:19, Gian-Carlo Pascutto wrote:

>On August 17, 2002 at 00:51:59, Will Singleton wrote:
>
>>I don't have my source code with me now, but I remember that OR'ing the two
>>32-bit values will give very bad results.
>
>Why?
>
>--
>GCP

Trying to build a 64-bit random number sequence from several smaller sources is
fraught with danger. I remember testing a bad 32-bit psuedo-random number
generator for dice simulations and it failed miserably due to serial
correlation. Serial correlation is a formal test of successive random number
sequence pairs reduced to several ranges for long sequence runs. For my dice
simulation it turned out that rolling a "1" on the first die increased the
likelihood of rolling a "6" on the 2nd die and lessened the likelihood of
rolling another "1". For Zobrist hashing a test for hamming distance of
successive numbers would be a start. Testing every other number would follow,
etc.

Any psuedo random number generator that suffers from serial correlation will
yield less than optimal random numbers. The question whether these "less than
optimal numbers" are bad for Zobrist hashing is unanswered, but I tend to
mistrust them.

A very good 64-bit random number generator with C-source can be found here:
http://burtleburtle.net/bob/rand/isaacafa.html
Look for ISAAC-64.

Ron



This page took 0 seconds to execute

Last modified: Thu, 15 Apr 21 08:11:13 -0700

Current Computer Chess Club Forums at Talkchess. This site by Sean Mintz.