const int NoPawnsSF[4] = { 6, 12, 32 };
// Polynomial material balance parameters
const int NoPawnsSF[4] = { 6, 12, 32 };
// Polynomial material balance parameters
- const int LinearCoefficients[6] = { 1852, -162, -1122, -183, 302, 1 };
+ const int LinearCoefficients[6] = { 1852, -162, -1122, -183, 249, -52 };
{ 106, 101, 3, 151, 171, 0 } // Queen
};
{ 106, 101, 3, 151, 171, 0 } // Queen
};
- // Endgame evaluation and scaling functions accessed direcly and not through
- // the function maps because correspond to more then one material hash key.
+ // Endgame evaluation and scaling functions are accessed directly and not through
+ // the function maps because they correspond to more then one material hash key.
Endgame<KmmKm> EvaluateKmmKm[] = { Endgame<KmmKm>(WHITE), Endgame<KmmKm>(BLACK) };
Endgame<KXK> EvaluateKXK[] = { Endgame<KXK>(WHITE), Endgame<KXK>(BLACK) };
Endgame<KmmKm> EvaluateKmmKm[] = { Endgame<KmmKm>(WHITE), Endgame<KmmKm>(BLACK) };
Endgame<KXK> EvaluateKXK[] = { Endgame<KXK>(WHITE), Endgame<KXK>(BLACK) };
// Second-degree polynomial material imbalance by Tord Romstad
for (pt1 = NO_PIECE_TYPE; pt1 <= QUEEN; ++pt1)
{
// Second-degree polynomial material imbalance by Tord Romstad
for (pt1 = NO_PIECE_TYPE; pt1 <= QUEEN; ++pt1)
{
- // Let's look if we have a specialized evaluation function for this
- // particular material configuration. First we look for a fixed
- // configuration one, then a generic one if previous search failed.
+ // Let's look if we have a specialized evaluation function for this particular
+ // material configuration. Firstly we look for a fixed configuration one, then
+ // for a generic one if the previous search failed.
// Note that these ones don't return after setting the function.
if (is_KBPsKs<WHITE>(pos))
e->scalingFunction[WHITE] = &ScaleKBPsK[WHITE];
// Note that these ones don't return after setting the function.
if (is_KBPsKs<WHITE>(pos))
e->scalingFunction[WHITE] = &ScaleKBPsK[WHITE];
// in defining bishop pair bonuses.
const int pieceCount[COLOR_NB][PIECE_TYPE_NB] = {
{ pos.count<BISHOP>(WHITE) > 1, pos.count<PAWN>(WHITE), pos.count<KNIGHT>(WHITE),
// in defining bishop pair bonuses.
const int pieceCount[COLOR_NB][PIECE_TYPE_NB] = {
{ pos.count<BISHOP>(WHITE) > 1, pos.count<PAWN>(WHITE), pos.count<KNIGHT>(WHITE),