Late Move Reductions(LMR)は、手の順序の後ろに出てくる手を浅く読むことで探索量を減らす手法である。 手の並べ替えが良いほど、 後ろの手は有望でない可能性が高いので、深さを減らしても強さを保ちやすい。
典型的には、
R だけ減らして読むという流れを取る。
この考え方は、
と並んで、現代的探索の強力な高速化技術のひとつである。
反復深化と手の並べ替えがうまく働いていれば、 有望な手はだいたい先頭付近に来る。
そのため、後ろの手は
ことが多い。
int searchMoves(Position pos, int depth, int alpha, int beta) {
int moveCount = 0;
for (Move move : generateMoves(pos)) {
++moveCount;
Position next = doMove(pos, move);
int reduction = 0;
if (depth >= 3 && moveCount > 3 && isQuiet(move)) {
reduction = 1;
}
int score = -search(next, depth - 1 - reduction, -alpha - 1, -alpha);
if (reduction > 0 && score > alpha) {
score = -search(next, depth - 1, -beta, -alpha);
}
if (score >= beta) {
return score;
}
if (score > alpha) {
alpha = score;
}
}
return alpha;
}
現代エンジンでは、depth と moveCount の両方に応じて reduction 量を変えることが多い。
将棋は分岐数が大きいため、LMR の効果が出やすい。 一方で、
のような戦術的な手は、後ろに並んでいても重要な場合がある。 そのため、どの手を reduction の対象にするかは慎重な設計が必要である。