Computer Chess Club Archives


Search

Terms

Messages

Subject: Re: Limiting the QSearch

Author: Bruce Moreland

Date: 16:45:16 12/30/97

Go up one level in this thread



On December 30, 1997 at 18:47:04, John Scalo wrote:

>I dream of an efficent SEE, but I only use bitboards to a limited
>extent. I can't figure out how to create an efficient SEE without going
>with full-blown bitboards, which I don't want to do because I feel like
>I'd basically be copying Crafty. I maintain bitboards of all pieces,
>passed pawns, and several huge arrays that help make generating captures
>fast, although I still need to check for interposing pieces when it
>comes to sliders. Any suggestions on how to create an SEE in such a
>scheme?

You can devise some system for determining if there might be a vector of
the proper type between two squares.  For the non-sliding pieces (P, N,
K), this is actually perfect, since there is no way to block one of
these pieces, once you determine that a vector might exist, it must
exist.

For the sliding pieces, once you have determined that there the piece
might be able to get there from here (the B is on c1 and the K is on h6,
for instance),  you can have another system for getting a vector that
you can walk in a loop, then look at the intervening squares.  (If you
have some way of not looking at the intervening squares, good for you.)

A lot of the time, there is no vector between the two squares.  A bishop
on c1 doesn't have any chance of getting to e8, regardless of what else
is on the board, and this can be quickly determined.

When there is a real vector between the two squares, you do the loop,
but this isn't very common.

You can use dejanews to look up an old post on 0x88 move generation and
attack detection strategies, if you want to go that route, or you can do
whatever else you want to do if you don't want to do it that way.  You
can always make a big multi-dimensional array with all of this stuff in
it, if you want to.

The best program you can dissect uses bitboards, but that doesn't mean
that everyone else does, or should.  There are tons of ways to do this
stuff, and none of them really outshines the rest, in my opinion.

bruce



This page took 0.01 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.