From: Fabian Fichter Date: Wed, 23 Dec 2020 15:57:27 +0000 (+0100) Subject: Simplify losing chess material evaluation X-Git-Url: http://winboard.nl/cgi-bin?a=commitdiff_plain;h=00fe00f664824d862fae1976f5110d523d697d78;p=fairystockfish.git Simplify losing chess material evaluation giveaway STC LLR: 2.97 (-2.94,2.94) [-10.00,5.00] Total: 922 W: 372 L: 323 D: 227 http://www.variantfishtest.org:6543/tests/view/5fe330d46e23db221d9e967c giveaway LTC LLR: 2.98 (-2.94,2.94) [-10.00,5.00] Total: 1718 W: 652 L: 609 D: 457 http://www.variantfishtest.org:6543/tests/view/5fe346dd6e23db221d9e9688 losers STC LLR: 2.99 (-2.94,2.94) [-10.00,5.00] Total: 485 W: 241 L: 183 D: 61 http://www.variantfishtest.org:6543/tests/view/5fe346ee6e23db221d9e968a losers LTC LLR: 2.96 (-2.94,2.94) [-10.00,5.00] Total: 547 W: 273 L: 215 D: 59 http://www.variantfishtest.org:6543/tests/view/5fe34b7d6e23db221d9e968c --- diff --git a/src/material.cpp b/src/material.cpp index 1318ba3..539791c 100644 --- a/src/material.cpp +++ b/src/material.cpp @@ -103,7 +103,7 @@ namespace { // Second-degree polynomial material imbalance, by Tord Romstad for (int pt1 = NO_PIECE_TYPE; pt1 <= QUEEN; ++pt1) { - if (!pieceCount[Us][pt1] || (pos.extinction_value() == VALUE_MATE && pt1 != KNIGHT)) + if (!pieceCount[Us][pt1]) continue; int v = QuadraticOurs[pt1][pt1] * pieceCount[Us][pt1]; @@ -116,7 +116,7 @@ namespace { } if (pos.must_capture()) - bonus += bonus + 2 * QuadraticOurs[KNIGHT][PAWN] * pieceCount[Us][KNIGHT] * pieceCount[Us][PAWN]; + bonus += 3 * QuadraticOurs[KNIGHT][PAWN] * pieceCount[Us][KNIGHT] * pieceCount[Us][PAWN]; else if (pos.check_counting()) bonus -= 2 * QuadraticOurs[PAWN][PAWN] * pieceCount[Us][PAWN] * pieceCount[Us][PAWN];