Computer Chess Club Archives


Search

Terms

Messages

Subject: Re: How I store and handle bounds

Author: rasjid chan

Date: 15:50:24 04/19/04

Go up one level in this thread


On April 19, 2004 at 18:25:59, Andrew Wagner wrote:

>Perhaps some pseudo code will help:
>
>Search(int LeafDistance, int alpha, int beta)
>.
>.
>.
>int HashFlag = HashFlagAlpha; //a constant
>if (ProbeHash(LeafDistance, alpha, beta, &hashscore, &hash_move))
>{
>     return(hashscore);
>}
>
>.
>.
>.
>
>Gen_Moves();
>for (i = 0; i < NumMoves; i++)
>{
>     Make_Move(move(i));
>     val = -Search(LeafDistance -1, -beta, -alpha);
>     takeback();
>     if (val >= beta)
>     {
>          RecordHash(LeafDistance, beta, HashFlagBeta, move(i));
>          return(beta);
>     }
>     if (val > alpha)
>     {
>          //Add move to PV
>          alpha = val;
>     }
>}
>RecordHash(LeafDistance, alpha, hashflag, Nothing);
>return(alpha);
>
>
>So, Dr. Hyatt, what you're calling a LOWER flag is (I think) what I'm calling
>HashFlagBeta, and what you're calling UPPER, I call HashFlagAlpha, becuase those
>were the bounds that were exceeded. Personally, I hate this terminology...I wish
>we'd use more friendly terminology like

lower bounds and upper bounds are universally recongnize in maths.

AtLeastThisScore == hit the floor == LB
LessThanThisScore == hit the ceiling == UB

also saving on key strokes

Rasjid


I
>think when I rewrite Trueno I'm going to do that, now that I understand
>alphabeta a little better. But that's neither here nor there...how does this
>look? Andrew



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.