Computer Chess Club Archives


Search

Terms

Messages

Subject: Re: Evaluation in Rebel

Author: Ed Schröder

Date: 01:57:00 01/08/03

Go up one level in this thread


On January 08, 2003 at 04:31:23, Uri Blass wrote:

>On January 07, 2003 at 16:52:14, Ed Schröder wrote:
>
>>On January 07, 2003 at 16:05:06, Tord Romstad wrote:
>>
>>>On January 07, 2003 at 07:17:27, Ed Schröder wrote:
>>>>
>>>>Let's go through a couple of xray examples:
>>>>
>>>>[d]rn1qkbnr/pbppp1pp/1p3p2/8/2B5/1QP1P3/PP1P1PPP/RNB1K1NR b KQkq -
>>>>
>>>>The knight on G8 is hanging, 2 attackers, one defender, the lowest attacking
>>>>piece is a bishop. You can extract this from the bit settings.
>>>>
>>>>
>>>>
>>>>
>>>>
>>>>
>>>>
>>>>[d]r2qkbnr/pbppp1pp/1pn2p2/3Q4/2B5/2P1P3/PP1P1PPP/RNB1K1NR b KQkq -
>>>>
>>>>The knight on G8 is not hanging because the lowest attacking piece is a Queen.
>>>
>>>I still don't quite understand this, I'm afraid.  How do you determine the
>>>lowest attacking piece from your bit settings in the presence of an x-ray
>>>attack?  How do WB[G8] look for the above two positions?  The way I understand
>>>the section about Rebel's eval on your homepage, the bit vector would look like
>>>this in both cases:
>>>
>>>+------+------+------+------+------+------+------+------+
>>>| BIT0 | BIT1 | BIT2 | BIT3 | BIT4 | BIT5 | BIT6 | BIT7 |
>>>+------+------+------+------+------+------+------+------+
>>>|      Number of     | PAWN |KNIGHT| ROOK | QUEEN| KING |
>>>|      ATTACKERS     |      |BISHOP|      |      |      |
>>>+------+------+------+------+------+------+------+------+
>>>|  0   |  1   |  0   |  0   |  1   |  0   |  1   |  0   |
>>>+------+------+------+------+------+------+------+------+
>>>
>>>Clearly I am misunderstanding something, but I am not sure what ...
>>>
>>>Tord
>>
>>
>>I had to look at the code to understand myself, it's stuff from 16-18 years
>>back.
>>
>>We are scanning Bc4:
>>
>>Bc4 -> Qd5 -> e6 -> f7 -> Ng8
>>
>>The squares AFTER d5 (e6, f7 and g8) the bits are not set, only a WB[sqaure]++;
>>is done, so the square G8 will look as follows:
>>
>>>+------+------+------+------+------+------+------+------+
>>>| BIT0 | BIT1 | BIT2 | BIT3 | BIT4 | BIT5 | BIT6 | BIT7 |
>>>+------+------+------+------+------+------+------+------+
>>>|      Number of     | PAWN |KNIGHT| ROOK | QUEEN| KING |
>>>|      ATTACKERS     |      |BISHOP|      |      |      |
>>>+------+------+------+------+------+------+------+------+
>>>|  0   |  1   |  0   |  0   |  0   |  0   |  1   |  0   |
>>>+------+------+------+------+------+------+------+------+
>>                             ^^^^^^^^
>>
>>Hope this helps :)
>>
>>Ed
>
>take the following position
>
>[D]4n1k1/8/5b2/8/5R2/5R2/8/6K1 w - - 0 1
>
>I guess that you have the following bits for white about f6
>
>
>+------+------+------+------+------+------+------+------+
>| BIT0 | BIT1 | BIT2 | BIT3 | BIT4 | BIT5 | BIT6 | BIT7 |
>+------+------+------+------+------+------+------+------+
>|      Number of     | PAWN |KNIGHT| ROOK | QUEEN| KING |
>|      ATTACKERS     |      |BISHOP|      |      |      |
>+------+------+------+------+------+------+------+------+
>|  0   |  1   |  0   |  0   |  0   |  1   |  0   |  0   |
>+------+------+------+------+------+------+------+------+
>
>the following bits are for black
>
>+------+------+------+------+------+------+------+------+
>| BIT0 | BIT1 | BIT2 | BIT3 | BIT4 | BIT5 | BIT6 | BIT7 |
>+------+------+------+------+------+------+------+------+
>|      Number of     | PAWN |KNIGHT| ROOK | QUEEN| KING |
>|      ATTACKERS     |      |BISHOP|      |      |      |
>+------+------+------+------+------+------+------+------+
>|  0   |  0   |  1   |  0   |  1   |  0   |  0   |  0   |
>+------+------+------+------+------+------+------+------+
>
>I guess that in this case your table tell you that the bishop at f6 is hanging
>but the value of hang is only 1 because if you have rook and 2 attackers and
>knight bishop as single defender it means that knight is hanging by 1 pawn.
>
>Am I correct?

Yes, you have understood well. Bf6 is hanging, TABLE will return 1 (expected
gain is one pawn).



>Note that The main problem that I find when I think about it is not wrong
>detection of hanging pieces when there are 2 defenders and 3 attackers but wrong
>detection when there are pins(not to the king assuming that you have a legal
>move generator) or other threats.
>
>Consider the following position
>[D]rn1qkbnr/ppp2ppp/8/3pp3/4P1b1/3P1N2/PPP2PPP/RNBQKB1R w KQkq - 0 1
>
>I guess that Rebel will detext the pawn at e5 as hanged.

Yep, to make the extra code to detect cases like this is not productive, better
have a wrong move-ordering so now and then. It just doesn't hurt.




>consider the following position
>
>[D]5bk1/8/8/2R5/8/R7/8/6K1 w - - 0 1
>
>The a3 rook is also under indirect threat so it may be better to consider it for
>better order of moves

Rebel recognizes such patterns in EVAL, it usually is rewarded with a bonus of 1
pawn, it isn't used for move-ordering.

Ed


>Uri



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.