Computer Chess Club Archives


Search

Terms

Messages

Subject: Re: crafty bug?

Author: Robert Hyatt

Date: 10:09:57 12/12/03

Go up one level in this thread


On December 12, 2003 at 12:51:49, Anthony Cozzie wrote:

>  if (wfile+wtm > bfile+1) {
>      if (wfile < FirstOne8Bit(tree->pawn_score.allb))
>        pscore+=WON_KP_ENDING;
>    }

What that says, in English:

if the white king is to the right of the black king on the
board, and the white king is to the left of the left-most pawn,
then treat it as a won KP ending.  yes, it has a few holes.  But
it also solves great problems.  IE you have an outside passed
pawn.  If you just score that as good, you will _never_ give
it up.  In such a normal case, you have the two kings fighting
around the passer, IE WKb3, WPb4, BKb5.  Eventually white has
to give up the passer, but in doing so, makes it to the kingside
first.  In this case, this term is generally right.  I play Kc3.
you do something, say a3.  I play Kd4 and away we go.  The point
here is that you have to pick up the pawn, which means you are not
going to hold the opposition and be able to block me out of
the king-side pawns.

Also remember that in Crafty, the a-file is file bit 0, the h-file is
file bit 7, in the FirstOne8Bit() approach.  Hopefully I have done
this right, but no guarantees.  But remember that it is mainly there
to win won endings.  IE without this, an outside passer won't win
unless you can see deep enough to discover that if you give up the
passer, you win the kingside pawns and the game.  Sometimes at fast
time controls, there is not enough time.  Or giving the pawn up occurs
so deep in the tree that it can't see to the final winning position.


>
>where wfile is File(white king) etc.
>
>Now, this doesn't quite make sense: I'm thinking it should be
>wfile < (FILEH - last_one_8(tree->pawn_score.allb))
>
>However, even then, the bonus is not always correct, for example:
>
>[D]8/8/5ppp/1k6/8/2K2PPP/8/8 w - - 0 1
>
>is drawn.
>
>anthony



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.