diff --git a/src/search.cpp b/src/search.cpp index 673caacb..8d2d5720 100644 --- a/src/search.cpp +++ b/src/search.cpp @@ -466,7 +466,9 @@ void Search::Worker::iterative_deepening() { fallingEval = std::clamp(fallingEval, 0.5786, 1.6752); // If the bestMove is stable over several iterations, reduce time accordingly - timeReduction = lastBestMoveDepth + 8 < completedDepth ? 1.4857 : 0.7046; + double k = 0.527; + double center = lastBestMoveDepth + 11; + timeReduction = 0.8 + 0.84 / (1.077 + std::exp(-k * (completedDepth - center))); double reduction = (1.4540 + mainThread->previousTimeReduction) / (2.1593 * timeReduction); double bestMoveInstability = 0.9929 + 1.8519 * totBestMoveChanges / threads.size(); @@ -2237,4 +2239,4 @@ bool RootMove::extract_ponder_from_tt(const TranspositionTable& tt, Position& po } -} // namespace Stockfish \ No newline at end of file +} // namespace Stockfish