Computer Chess Club Archives


Search

Terms

Messages

Subject: Re: Hash codes - how good is good enough?

Author: Ricardo Gibert

Date: 01:38:33 02/10/01

Go up one level in this thread


On February 10, 2001 at 04:01:21, David Rasmussen wrote:

>On February 09, 2001 at 19:34:03, Ricardo Gibert wrote:
>>
>>So far the conclusions I've come up with are:
>>
>>(1) A Key = 0 should be excluded, since positions with a particular piece on a
>>particular square will produce the same hash signature as the same position
>>without that piece.
>
>This excludes all linear codes, which is obviously a good thing to do, because a
>linear code would mean that c = a xor b will be a codeword if a and b are
>codewords. This means that with exactly three xors you could get the codeword
>zero. With 800 codewords, this means that there are lots of different ways to
>get 0 which would mean that 0 couldn't possible denote just one position.
>
>>(3) Pairs of keys of the form x and ~x, since 2 such pairs will XOR to zero.
>
>This criterion can be met by saying that the code should be non-linear. There's
>nothing wrong with a high hamming distance in general, as long as we have a
>non-linear code.
>
>>(4) Pairs with a close hamming distance to x and ~x should also be excluded.
>
>What do you mean by this? Hamming distance is a number, x and ~x are codewords.

I should rewrite this as: Pairs of numbers with a large hamming distance with
respect to each other should also be excluded. 2 such pairs would XOR together
to a number with a small hamming distance with respect to zero. This is probably
still an inept explanation, so here is an example with 16 bit numbers:

(0000000011111111^1111111100000001)^(0101010101010101^0010101010101010)
= 1111111111111110^0111111111111111
= 1000000000000001

>
>>(5) A key set with a hamming distance > 21 and < 43 with respect to each other
>>*and* to zero should satisfy (1)-(4) above can be quickly produced within the
>>program without having to read in a file with the keys. Just use the same random
>>number seed.
>>
>
>Sure, but we might be able to do better.
>
>>I'm trying to find sources on the net to verify these conclusions, but so far no
>>luck. What do you think?
>
>Search for coding theory.

Thanks! I'll try it.



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.