Author: Russell Reagan
Date: 19:56:07 01/23/02
I'd like to know two things for each of the values. I'd like to know the theoretical maximum value, and a practical maximum value for use in a chess program. Here's what I'd like to know: Maximum number of moves a chess game can last, and a good value for the maximum size of the move history stack. Maximum number of legal moves in a chess position, and a good maximum value for the legal moves array. I can't think of anymore maximum values that would be good to know, but I was just thinking about how horrible it would be to set the size of the move history stack to some value and then in some crazy game that is clearly drawn have my opponent draw it out hundreds of moves more by piddling around and making a pawn move every 40-50 moves. Not likely, but I'm sure stranger things have happened. Same with the legal moves maximum. I'd hate to miss a move because I didn't create a large enough legal move array. I recall someone a long time ago giving a value for maximum number of moves to be around 5,400, and I'm guessing that maximum number of legal moves is around 80-100+. If all else fails, the legal move array could be 269, since that would account for 9 queens, 2 rooks, 2 bishops, 2 knights, and 1 king all with maximum number of legal moves. All of those pieces obviously cannot all have the maximum number of legal moves if they're all on the board, so 269 would be a safe maximum. As for the maximum number of legal moves, 6300 should cover it since 16 pawns at a maximum of 6 moves each, plus 30 captures, totals 126. So you could have 126 blocks of 50 moves. And I guess that would really be blocks of 49 moves, as 50 would be a draw, totallying 6174 total moves. Even at 6 bytes per move, that's only ~50K of memory. If anyone knows these exact values off hand, or cares to take the time to compute them accurately, I'd love to know them. If not I'll just shoot high and waste a few bytes :) Russell
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.