Tweak dynamic contempt (the birthday patch)
[stockfish] / src / search.cpp
index 086761a3561b879227231d72279b5c191f015a31..b571cdf1787204e6c3e7c919da7c782de33439d4 100644 (file)
@@ -418,7 +418,7 @@ void Thread::search() {
               beta  = std::min(previousScore + delta, VALUE_INFINITE);
 
               // Adjust contempt based on root move's previousScore (dynamic contempt)
-              int dct = ct + 86 * previousScore / (abs(previousScore) + 176);
+              int dct = ct + (111 - ct / 2) * previousScore / (abs(previousScore) + 176);
 
               contempt = (us == WHITE ?  make_score(dct, dct / 2)
                                       : -make_score(dct, dct / 2));