From: Marco Costalba Date: Sun, 12 Jan 2014 21:32:41 +0000 (+0100) Subject: Retire KBBKN endgame X-Git-Url: https://git.sesse.net/?p=stockfish;a=commitdiff_plain;h=3d58092ec161f5e74de198c6d8f02805728cb96f;ds=sidebyside Retire KBBKN endgame As pointed out by Joona, Lucas and otehr people in the forum, this endgame is not a known, there are many positions where it takes more than 50 moves to claim the win and becasue exact rules is not possible better to retire and allow the search to workout the endgame for us. bench: 8502826 --- diff --git a/src/endgame.cpp b/src/endgame.cpp index 869a36d7..85419941 100644 --- a/src/endgame.cpp +++ b/src/endgame.cpp @@ -118,7 +118,6 @@ Endgames::Endgames() { add("KRKN"); add("KQKP"); add("KQKR"); - add("KBBKN"); add("KNPK"); add("KNPKB"); @@ -348,29 +347,6 @@ Value Endgame::operator()(const Position& pos) const { } -/// KBB vs KN. This is almost always a win. We try to push the enemy king to a corner -/// and away from his knight. For a reference of this difficult endgame see: -/// en.wikipedia.org/wiki/Chess_endgame#Effect_of_tablebases_on_endgame_theory - -template<> -Value Endgame::operator()(const Position& pos) const { - - assert(verify_material(pos, strongSide, 2 * BishopValueMg, 0)); - assert(verify_material(pos, weakSide, KnightValueMg, 0)); - - Square winnerKSq = pos.king_square(strongSide); - Square loserKSq = pos.king_square(weakSide); - Square knightSq = pos.list(weakSide)[0]; - - Value result = VALUE_KNOWN_WIN - + PushToCorners[loserKSq] - + PushClose[square_distance(winnerKSq, loserKSq)] - + PushAway[square_distance(loserKSq, knightSq)]; - - return strongSide == pos.side_to_move() ? result : -result; -} - - /// Some cases of trivial draws template<> Value Endgame::operator()(const Position&) const { return VALUE_DRAW; } template<> Value Endgame::operator()(const Position&) const { return VALUE_DRAW; } diff --git a/src/endgame.h b/src/endgame.h index 681b379f..f6c31427 100644 --- a/src/endgame.h +++ b/src/endgame.h @@ -42,7 +42,6 @@ enum EndgameType { KRKN, // KR vs KN KQKP, // KQ vs KP KQKR, // KQ vs KR - KBBKN, // KBB vs KN KmmKm, // K and two minors vs K and one or two minors