# Type alias: WorkerParameters

Ƭ **WorkerParameters**: `Object`

WorkerParameters allow to specify how each individual worker of the solver should behave. It is part of the Parameters object.

If a parameter is not listed here then it can be set only globally (in Parameters}), not per worker. For example *timeLimit* or *logPeriod* are
global parameters.

#### Type declaration

Name | Type | Description |
---|---|---|

`cumulPropagationLevel?` | `number` | How much to propagate constraints on cumul functions. This parameter controls the amount of propagation done for cumulLe constraint when used with a sum of pulses. The bigger the value, the more algorithms are used for propagation. It means that more time is spent by the propagation and possibly more values are removed from domains. More propagation doesn't necessarily mean better performance. FDS search (see searchType) usually benefits from higher propagation levels. The algorithms used are: * `1` : Timetable * `2` : Timetable, Timetable Edge-Finding * `3` : Timetable, Timetable Edge-Finding, Disjunctive constraint The default value is `1` . Takes an unsigned integer value in range `1..3` . |

`fdsAdditionalStepRatio?` | `number` | Domain split ratio when run out of choices. When all choices are decided and a greedy algorithm cannot find a solution then more choices are generated by splitting domains into specified number of pieces. The default value is `7` . Takes a floating point value in range `2.000000..Infinity` . |

`fdsBothFailRewardFactor?` | `number` | How much to improve rating when both branches fail immediately. A bonus reward given to a choice when both left and right branches fail immediately. Current rating of both branches is multiplied by the specified value. The default value is `0.98` . Takes a floating point value in range `0..1` . |

`fdsBranchOnObjective?` | `boolean` | Whether to generate choices for objective expression/variable. This option controls generation of choices on objective. It works regardless whether objective is given by an expression or a variable. The default value is `false` . |

`fdsEpsilon?` | `number` | How often to chose a choice randomly. Probability that a choice is taken randomly. Randomly selected choice is not added into the search tree automatically. Instead the choice is tried, its rating is updated, but it is added into the search tree only if one of the branches fail. The mechanism is similar to strong branching. The default value is `0.1` . Takes a floating point value in range `0.000000..0.999990` . |

`fdsEventTimeInfluence?` | `number` | Influence of event time to initial choice rating. When non-zero then initial choice rating is influenced by the date of the choice. This way very first choices in the search should be taken chronologically. The default value is `0` . Takes a floating point value in range `0..1` . |

`fdsFixedAlpha?` | `number` | When non-zero, alpha factor for rating updates. When this parameter is set to a non-zero value then parameter FDSRatingAverageLength is ignored. Instead rating of a branch is computed as exponential moving average with the given parameter alpha. The default value is `0` . Takes a floating point value in range `0..1` . |

`fdsInitialRating?` | `number` | Initial rating for newly created choices. Default rating for newly created choices. Both left and right branches get the same rating. Choice is initially permuted so that bigger change in domain is left branch The default value is `0.5` . Takes a floating point value in range `0.000000..2.000000` . |

`fdsInitialRestartLimit?` | `number` | Fail limit for the first restart. Failure-directed search is periodically restarted: explored part of the current search tree is turned a no-good constraint and the search starts again in the root node. This parameter specifies the size of the very first search tree (measured in number of failures). The default value is `100` . Takes an unsigned integer value in range `1..9223372036854775807` . |

`fdsLBResetRatings?` | `boolean` | Whether to reset ratings when a new LB is proved. When this parameter is on and FDSLB proves a new lower bound all ratings then all ratings are reset to default values The default value is `false` . |

`fdsLBStrategy?` | `"Minimum"` | `"Random"` | `"Split"` | A strategy to choose objective cuts during FDSLB search.. Possible values are: * `Minimum` : Always change the cut by the minimum amount. The default value. * `Random` : At each restart randomly choose a value in range LB..UB. * `Split` : Always split the current range LB..UB in half. The default value is `Minimum` . |

`fdsLengthStepRatio?` | `number` | Choice step relative to average length. Ratio of initial choice step size to minimum length of interval variable.When FDSUniformChoiceStep is set this ratio is used to compute global choice step using average of interval var length.When FDSUniformChoiceStep is not set this ratio is used to compute choice step of for every interval var individually. The default value is `0.699999988079071` . Takes a floating point value in range `0.000000..Infinity` . |

`fdsMaxCounterAfterRestart?` | `number` | Truncate choice use counts after restart to this value. The idea is that ratings learned in previous restart are less valid in the new restart. Using this parameter it is possible to truncate use counts on choices so that new local ratings will have bigger weights (when FDSFixedAlpha is not used). The default value is `255` . Takes an unsigned integer value. |

`fdsMaxCounterAfterSolution?` | `number` | Truncate choice use counts after a solution is found. Similarly to `FDSMaxCounterAfterRestart` , this parameter allows to truncate use counts on choices when a solution is found. The default value is `255` . Takes an unsigned integer value. |

`fdsMaxInitialChoicesPerVariable?` | `number` | Maximum number of choices generated initially per a variable. Initial domains are often very large (e.g. 0..IntervalMax). Therefore initial number of generated choices is limited: only choices near startMin are kept. The default value is `90` . Takes an unsigned integer value in range `2..2147483647` . |

`fdsMaxInitialIntVarChoiceStep?` | `number` | Maximum step when generating initial choices for integer variables.. For a variable with big initial domains, choices are generated only around min value considering the given step. The default value is `10` . Takes an unsigned integer value in range `1..1073741823` . |

`fdsPresenceStatusChoices?` | `boolean` | Whether to generate choices on presence status. Choices on start time also include a choice on presence status. Therefore dedicated choices on presence status only are not mandatory. The default value is `true` . |

`fdsRatingAverageComparison?` | `"Off"` | `"Global"` | `"Depth"` | Whether to compare local rating with an average. Possible values are: * `Off` (the default): No comparison is done. * `Global` : Compare with global average. * `Depth` : Compare with average on the given search depth Arithmetic average is used for global and depth averages. The default value is `Off` . |

`fdsRatingAverageLength?` | `number` | Length of average rating computed for choices. For computation of rating of a branch. Arithmetic average is used until the branch is taken at least FDSRatingAverageLength times. After that exponential moving average is used with parameter alpha = 1 - 1 / FDSRatingAverageLength. The default value is `25` . Takes an integer value in range `0..254` . |

`fdsReductionFactor?` | `"Normal"` | `"Zero"` | `"Random"` | Reduction factor R for rating computation. Possible values are: * `Normal` (the default): Normal reduction factor. * `Zero` : Factor is not used (it is 0 all the time). * `Random` : A random number in range [0,1] is used instead The default value is `Normal` . |

`fdsReductionWeight?` | `number` | Weight of the reduction factor in rating computation. When computing local rating of a branch, multiply reduction factor by the given weight. The default value is `1` . Takes a floating point value in range `0.000000..Infinity` . |

`fdsResetRestartsAfterSolution?` | `boolean` | Reset restart size after a solution is found (ignored in Luby). When this parameter is set (the default) then restart limit is set back to `FDSInitialRestartLimit` when a solution is found. The default value is `true` . |

`fdsRestartGrowthFactor?` | `number` | Growth factor for fail limit after each restart. After each restart, fail limit for the restart is multiplied by the specified factor. This parameter is ignored when fdsRestartStrategy is `Luby` . The default value is `1.15` . Takes a floating point value in range `1.000000..Infinity` . |

`fdsRestartStrategy?` | `"Geometric"` | `"Nested"` | `"Luby"` | Restart strategy to use. This parameter specifies how restart limit (maximum number of failures) changes from restart to restart. Possible values are: * `Geometric` (the default): After each restart, restart limit is multiplied by fdsRestartGrowthFactor. * `Nested` : Similar to `Geometric` but the limit is changed back to fdsInitialRestartLimit each time a new maximum limit is reached * `Luby` : Luby restart strategy is used. Parameter fdsRestartGrowthFactor is ignored. The default value is `Geometric` . |

`fdsReuseClosing?` | `boolean` | Whether always reuse closing choice. Most of the time FDS reuse closing choice automatically. This parameter enforces it all the time. The default value is `false` . |

`fdsStrongBranchingCriterion?` | `"Both"` | `"Left"` | `"Right"` | How to chose best choice in strong branching. Possible values are: * `Both` : Choose the the choice with best combined rating. * `Left` (the default): Choose the choice with the best rating of the left branch. * `Right` : Choose the choice with the best rating of the right branch. The default value is `Left` . |

`fdsStrongBranchingDepth?` | `number` | Up-to what search depth apply strong branching. Strong branching is typically used in root node. This parameter controls the maximum search depth when strong branching is used. The default value is `6` . Takes an unsigned integer value. |

`fdsStrongBranchingSize?` | `number` | Number of choices to try in strong branching. Strong branching means that instead of taking a choice with the best rating we take specified number (FDSStrongBranchingSize) of best choices, try them in dry-run mode, measure their local rating and then chose the one with the best local rating. The default value is `10` . Takes an unsigned integer value. |

`fdsUniformChoiceStep?` | `boolean` | Whether all initial choices have the same step length. When set then initial choices generated on interval variables have all the same step size. The default value is `true` . |

`fdsUseNogoods?` | `boolean` | Whether to use or not nogood constraints. By default no-good constraint is generated after each restart. This parameter allows to turn no-good constraints off. The default value is `true` . |

`noOverlapPropagationLevel?` | `number` | How much to propagate noOverlap constraints. This parameter controls the amount of propagation done for noOverlap constraints. The bigger the value, the more algorithms are used for propagation. It means that more time is spent by the propagation and possibly more values are removed from domains. More propagation doesn't necessarily mean better performance. FDS search (see searchType) usually benefits from higher propagation levels. The algorithms used are: * `1` : Timetable * `2` : Detectable Precedences * `3` : Detectable Precedences, Not-First/Not-Last * `4` : Detectable Precedences, Not-First/Not-Last, Edge-Finding The default value is `2` . Takes an unsigned integer value in range `1..4` . |

`propagationTraceLevel?` | `number` | Level of propagation trace. This parameter is available only in development edition of the solver. When set to a value bigger than zero, the solver prints a trace of the propagation, that is a line for every domain change. The higher the value, the more information is printed. The default value is `0` . Takes an unsigned integer value in range `0..5` . |

`randomSeed?` | `number` | Random seed. The solver break ties randomly using a pseudorandom number generator. This parameter sets the seed of the generator. Note that when nbWorkers is more than 1 then there is also another source of randomness: the time it takes for a message to pass from one worker to another. Therefore with nbWorkers=1 the solver is deterministic (random behavior depends only on random seed). With nbWorkers>1 the solver is not deterministic. Even with @linkNbSeeds=1 and the same random seed, the solver may behave differently on different platforms. This can be due to different implementation of certain functions such as `std::sort` . The default value is `1` . Takes an unsigned integer value. |

`reservoirPropagationLevel?` | `number` | How much to propagate constraints on cumul functions. This parameter controls the amount of propagation done for cumulLe and cumulGe when used together with steps (stepAtStart, stepAtEnd, stepAt). The bigger the value, the more algorithms are used for propagation. It means that more time is spent by the propagation and possibly more values are removed from domains. More propagation doesn't necessarily mean better performance. FDS search (see searchType) usually benefits from higher propagation levels. The algorithms used are: * `1` : Timetable * `2` : Reservoir Edge-Finding The default value is `1` . Takes an unsigned integer value in range `1..2` . |

`searchTraceLevel?` | `number` | Level of search trace. This parameter is available only in development edition of the solver. When set to a value bigger than zero, the solver prints a trace of the search. The trace contains information about every choice taken by the solver. The higher the value, the more information is printed. The default value is `0` . Takes an unsigned integer value in range `0..5` . |

`searchType?` | `"LNS"` | `"FDS"` | `"FDSLB"` | `"SetTimes"` | Type of search to use. Possible values are: * `LNS` : Large Neighborhood Search * `FDS` : Failure-Directed Search * `FDSLB` : Failure-Directed Searching working on lower bound * `SetTimes` : Depth-first set-times search (not restarted) The default value is `LNS` . |

`simpleLBMaxIterations?` | `number` | Maximum number of feasibility checks. Simple lower bound is computed by binary search for the best objective value that is not infeasible by propagation. This parameter limits the maximum number of iterations of the binary search. The default value is `2147483647` . Takes an unsigned integer value in range `1..2147483647` . |

`simpleLBShavingRounds?` | `number` | Number of shaving rounds. When non-zero, the solver will use shaving on variable domains to improve the lower bound. This parameter controls the number of shaving rounds. The default value is `0` . Takes an unsigned integer value in range `0..2147483647` . |

`simpleLBWorker?` | `number` | Which worker computes simple lower bound. Simple lower bound is a bound such that infeasibility of a better objective can be proved by propagation only (without the search). Simple lower bound is computed by the given worker before its start normal search. If worker with the given number doesn't exist then the lower bound is not computed. The default value is `0` . Takes an integer value in range `-1..2147483647` . |

`stepFunctionSumPropagationLevel?` | `number` | How much to propagate stepFunctionSum expression. This parameter controls the amount of propagation done for stepFunctionSum expression. In particular, it controls whether the propagation also affects the minimum and the maximum length of the associated interval variable: * `1` : The length is is updated only once during initial constraint propagation. * `2` : The length is updated every time the expression is propagated. The default value is `1` . Takes an unsigned integer value in range `1..2` . |

`usePrecedenceEnergy?` | `number` | Whether to use precedence energy propagation algorithm. Precedence energy algorithm improves propagation of precedence constraints when an interval has multiple predecessors (or successors) which use the same resource (noOverlap or cumulative constraint). In this case the predecessors (or successors) may be in disjunction. Precedence energy algorithm can leverage this information and propagate the precedence constraint more aggressively. The default value is `0` . Takes an unsigned integer value in range `0..1` . |