I have a question, about something that i'm having hard time to understand, due to the lack of information about this.
The thing is, i am implementing the "Static Exchange Evaluation", i made it work using the very basic algorithm from the chess programming wiki:
https://www.chessprogramming.org/Static ... Evaluation
It does it's job for sure, but as we all know, that algorithm is very slow and cpu intense, especially when you use that to prune some nodes inside a QS for example, that is begin called very often.
I did some research and trying to figure out to implement an efficient SEE.
And then i found the Ed's lookup implementation, it seems to be just a lookup table but i don't understand how that thing works
https://www.chessprogramming.org/Attack ... #EDsLookup
In the arcticle it says:
As described by Ed Schröder in Evaluation in REBEL, Rebel uses two board tables for both sides, one byte entry each, the three lower bits contain an attack counter, while the five upper bits indicate the presence of least one pawn or piece attacking/defending
Code: Select all
char see_table [14][256][256]; // 14*64 K = 896 KByte
see = see_table[Piece][attackByte][defendByte];
i do understand that i have to binary-encode the number of attackers for lower bits, and attacker type for upper bits, but that are actually doing the [256] arrays there? i can't be an square index because an chess board is only 64 squares, and also how can i get the attackers and defenders to fill that information?
if anyone knows a guide about this or more information about this would be of great help! thanks



