Piece-Square Tables

From Chessprogramming wiki
Jump to: navigation, search

Home * Evaluation * Piece-Square Tables

John Cage, Chess Pieces, ca. 1944 [1]

Piece-Square Tables,
a simple way to assign values to specific pieces on specific squares. A table is created for each piece of each color, and values assigned to each square. This scheme is fast, since the evaluation term from the piece square tables can be incrementally updated as moves are made and unmade in the search tree. Because of that speed, piece-square tables are of great help when conducting lazy evaluation.

The same technique can be used for a more subtle evaluation terms, instead of one fixed value for, say, an isolated pawn. It is also possible to use piece-square tables for move ordering, though history heuristic tends to perform better. Some programs, like Rebel, use the combination of the two [2].

Multiple Tables

Most modern programs, influenced by Fruit, use two sets of tables. One for the opening of the game and another for the endgame. The final evaluation is then interpolated between these two based on game stage (often material on the board). This allows for changes in material as well, since the material part of the evaluation can also be stored in these tables. Using two tables also lets pieces change in evaluation as the game proceeds. For example, pawns can gain in value in the endgame using this method.


Older programs, running on slow hardware and reaching low depths, used an oracle approach to speed up their evaluation by initializing the piece-square tables at the beginning of each search, taking into account complex characteristics of position, influence of pawn structure, distance to the enemy king etc [3]. Pre-processing, also dubbed Pre Scan Heuristics as applied in Kittinger programs [4], most notably the Super Constellation [5], were used by Kaare Danielsen [6], Richard Lang [7], Don Dailey, who even developed a little language so that Larry Kaufman could express evaluation concepts in a more natural way [8], Chrilly Donninger with Nimzo 3, and Frans Morsch and Mathias Feist with Fritz 3, to name a few, the latter even with user modifiable rules or tables. However, the idea already originated from the program Tech by James Gillogly in the late 1960's [9].

With today's search depth this approach seems to be impractical, since the difference between the root and leaf position may be very big. There also might be a problem with re-using hash scores from the previous entries. About the only recent chess program that sticks with pre-processing for good or bad is RomiChess [10] [11].


Material and piece-square tables alone are enough for a program to play a semi-decent game of chess. Indeed, Tomasz Michniewski advocated a method of testing requiring all the tested programs to have identical, simplistic evaluation function, so that only search and efficiency issues would influence the result. One such tournament has been carried out in Poland. Ronald Friederich improved this approach using a Tapered Eval and Texel's tuning method as applied in RofChade and PeSTO.

See also


Forum Posts

1996 ...

2000 ...

2010 ...





Re: multi-dimensional piece/square tables by Tony P., CCC, January 28, 2020 » Automated Tuning

2015 ...




2020 ...



External Links


Up one level