Computer Chess Club Archives


Search

Terms

Messages

Subject: Re: What kind of move are used the most in the chess logic?

Author: leonid

Date: 17:51:52 11/15/99

Go up one level in this thread


On November 15, 1999 at 19:55:11, KingArt wrote:

>Hi,
>
>Using "illegal moves", I use the following algorithm, which is pretty fast:
>
>   move_list=generate_moves()
>   moves_legal=0
>
>   while not empty(move_list)
>      new_position=next_position(current_position,head(move_list))
>      move_list=tail(move_list)
>
>->   if king_in_check(new_position)
>        then continue
>        else moves_legal++
>
>      <search new position and come up with some value>
>   end while
>
>   if moves_legal=0 then
>      if king_in_check(current_position)
>          then value=mate
>          else value=stalemate
>
>
>Crafty uses this, too.
>
>Greetings,
>KingArt

Thanks! So far as I could understand illegal moves are used very widely. Good!
Expect tomorrow start writing the next logic with illegal moves.

Your explanation in C is obscure for me. C is not my "native" language.

Leonid.


>
>On November 15, 1999 at 18:19:46, leonid wrote:
>
>>Hi,
>>
>>What kind of moves usually are used in each ply search: legal or illigal?
>>
>>Legal (in my dictionary) is the move after which king from your side will be not
>>left under the fire. Move is legal after the logic for given piece.
>>
>>Illegal move - move that only take in cosideration the possibility to execute
>>move after the logic that correspond to this piece. Here you just don't care
>>about the "health insurance" of His Majesty.
>>
>>I make this question because each next ply can also indicate what illegal move
>>must be rejected. If in the next ply king will be taken, this move is illegal.
>>
>>When I tryed to use the illegal moves logic for soving the inevitable mate
>>containing position, logic worked 30% more slowly that logic with legal
>>position. I never tryed the logic with illegal moves that search the "positional
>>move". This is why I make this question.
>>
>>Leonid.



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.