Computer Chess Club Archives


Search

Terms

Messages

Subject: Re: QSearch and captures

Author: Andrew Williams

Date: 02:24:24 11/20/01

Go up one level in this thread


On November 20, 2001 at 05:04:42, Michel Langeveld wrote:

>Hello all,
>
>I implemented qsearch in my program nullmover, but got a problem for it back.
>
>When I search with a depth 1 (just testing at the moment) my program thinks that
>after the openingmove 1. d4, ... h6! is the best move.
>
>After h6 the qsearch starts.
>
>[D]rnbqkbnr/ppppppp1/7p/8/3P4/8/PPP1PPPP/RNBQKBNR w KQkq - 0 2
>
>The qsearch evaluates _only_ captures now. The program thinks white HAS to take
>on h6 then (is only capture in that position) and black can win a bishop after
>gxh6 or Rxh6. So score is about +2 for black then. This is incorrect of
>course....
>
>I'm thinking about ways to solve this. One way is to implement a null move so
>that beside capturing there's always a doing nothing option. But I was curious
>how you guys solve this thing.
>
>Regards,
>
>Michel Langeveld

That's exactly how it is done. On entry to your quiesce() function, do an
evaluation and store the result. If the result is >= beta, you can return
beta as your result immediately (it's a great position from whoseTurn's
point of view so there's no need to do more work). Otherwise, try the
captures. If none of them gives a score greater than the stored evaluation
you did at the top, return that because you assume that there is at least
one non-capturing move that is "neutral".

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.