Computer Chess Club Archives


Search

Terms

Messages

Subject: Re: Questions about hash table implementation?

Author: David Rasmussen

Date: 13:26:10 05/22/01

Go up one level in this thread


On May 22, 2001 at 09:52:11, Gian-Carlo Pascutto wrote:

>On May 22, 2001 at 09:43:49, Robert Hyatt wrote:
>
>>>2) How to generate a 64 bit random number? (I use ran()*ran(). Is it OK?).
>>

Ran*Ran is not OK, as it will favor the higher bits.

>>I would use ran()<<32 + ran myself.
>
>Just make sure you package your own ran(). The quality of C
>libraries one will vary greatly.
>
>I did a test with 32 bit hashes and MSVC: average hamming distance
>of 9.30, whereas my own (which I stole from Crafty, which stole it from...)
>got 15.99, which is theoretically optimal I suppose.
>

I'm almost sure that 15.99 is not optimal. I have my own PRNG in my engine
(which I stole from...), and I have chosen a good seedvalue, that gives me
_minimum_ hamming distance 16. So the average is at least that, and probably
higher than that. And as I've stated earlier, there is a non-linear extended
64-bit BCH code with minimum hamming distance 27, and dimension 10 (to get 1024
vectors) if I remember correctly. Of course this is very exceptional, but it can
be done.




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.