+ void reduction_parameters(double baseReduction, double reductionInhibitor, Depth depth, double& logLimit, double& gradient)
+ {
+ // Precalculate some parameters to avoid to calculate the following formula for each move:
+ //
+ // red = baseReduction + ln(moveCount) * ln(depth / 2) / reductionInhibitor;
+ //
+ logLimit = depth > OnePly ? (1.0 - baseReduction) * reductionInhibitor / ln(depth / 2) : 1000.0;
+ gradient = ln(depth / 2) / reductionInhibitor;
+ }