Computer Chess Club Archives


Search

Terms

Messages

Subject: Re: Question:1.hashtable 2.board 3.C

Author: Peter Kappler

Date: 00:03:22 06/14/00

Go up one level in this thread


On June 13, 2000 at 23:10:51, Christophe Theron wrote:

>On June 13, 2000 at 17:06:57, Tom Kerrigan wrote:
>
>>On June 13, 2000 at 16:10:05, Christophe Theron wrote:
>>
>>>With the other approach, you need a table lookup to tell that the square is not
>>>inside the board:
>>>
>>>  // 12x12 way:
>>>  if (board[square]==-1) it_is_outside;
>>>  else                   it_is_inside;
>>
>>If your board starts out being 12x12, then you're right, it doesn't really make
>>a difference if you switch to 0x88.
>>
>>However, I know that a number of programs use an 8x8 board. To do the bounds
>>testing, they convert the 8x8 offset into a 10x12 offset and then back again.
>>You can see this done in TSCP. This method is obviously a loser compared to
>>0x88.
>
>
>I don't really understand why you would use a 8x8 board if you use 12x12
>coordinates or the opposite...
>
>Actually I'm using 16x16 coordinates, so I shouldn't have mentionned 12x12 or
>12x10, but just 16x16 (well actually I just need 16x12).
>
>I think 16x16 is more efficient than 0x88 and I explained why. And it is much
>simpler to understand than 0x88 BTW! The way you test the out of bound condition
>in 0x88 is great, but that's the only advantage of this system, and as I
>explained nobody cares for this test most of the time!
>
>
>    Christophe


What makes 16x12 better than 12x12?  I'm sure it allows for some clever bitwise
operations somewhere, but I don't quite get it...

--Peter





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.