VDS Class

The Variable Depth Search solver.

Definition

Namespace: ASAP.NRP.Solvers
Assembly: NRP (in NRP.dll) Version: 3.49.0+964b2dfb493dfda37da83e5373992cb1cc934e98
C#
public class VDS : LocalSearch, ISolver, ITimeLimitChecker
Inheritance
Object    LocalSearch    VDS
Implements
ISolver, ITimeLimitChecker

Constructors

VDS Initializes a new instance of this class.

Properties

DYNAMIC_PROGRAMMING_HEURISTIC Recommend setting this as true (it is only used if ROSTER_CONSTRUCTION_HEURISTICS is set to true).
Obsolete
MAX_DP_HEURISTIC_MEMORY If RESTRICT_MEMORY_USAGE is true and DYNAMIC_PROGRAMMING_HEURISTIC is true then this is the maximum memory (in megabytes) to use for the dynamic programming heuristic. Increasing this value can improve the performance on some instances. Setting it too high though may just increase the running time of the heuristic without significantly improving the solution. The default value is 10.0.
Obsolete
PauseEvent Used to pause the solver while it is running.
RandomSeed The random seed to use if SYSTEM_TIME_RANDOM_SEED is set to false. If the same random seed is used for an instance then the solver will always create the same final solution (as long as the same amount of time is used).
RESTRICT_MEMORY_USAGE If this is set to false, then there will be no limit on the amount of memory the dynamic programing heuristic can use. This can result in better solutions for some instances but could also result in very high memory usage on some instances. (It is recommended to set this as true).
Obsolete
SolverCaller

It is recommended to instead use the SolverStatusUpdated event to receive feedback from the solver as it is solving.

This is used to get information from the solver while it is solving.

Stopped If this is set to true while the Solve method is executing then the solver will stop and return the best solution found so far.
TimeCheckerStopped Indicates whether the solver was stopped early.
Title Returns a title/name for the algorithm.
TotalEvaluations Returns the number of unique solutions created/tested by the algorithm.
(Inherited from LocalSearch)
VERBOSE Prints some running information during solving if true.

Methods

Equals
(Inherited from Object)
Finalize
(Inherited from Object)
GetHashCode
(Inherited from Object)
GetType
(Inherited from Object)
MemberwiseClone
(Inherited from Object)
Solve(Roster) Build and optimize the roster.
Solve(Roster, Double) Build and optimize the roster.
SolveAsync(Roster, CancellationToken) Build and optimize the roster.
SolveAsync(Roster, Double, CancellationToken) Build and optimize the roster.
TimeExceeded Check if there is a time limit and if so is it exceeded?
ToString
(Inherited from Object)

Events

SolverStatusUpdated Occurs when the the solver has new information to feedback.

Fields

DISRUPT_BEST_ROSTER_HEURISTICThis field is no longer used.
Obsolete
HARD_CONSTRAINT_RELAXATION_WEIGHT During the algorithm, hard constraints may be relaxed to soft constraints and given this weight. Therefore, if the problem contains hard constraints it is important to set this value larger than the largest weight of all the soft constraints.
LARGE_INSTANCE_HEURISTICS Try setting this to true for better performance on instances with long planning horizons and/or many shift types and/or many employees.
MAX_BLOCK_SIZE_AT_DEPTH_ZERO Recommended value is between 2-3.
MAX_DEPTH The maximum depth to allow the variable depth search to go to. Recommended value is between 300-500.
MAX_ITERATIONS The maximum number of iterations of the main loop. Set as less than zero for not limit (default).
NEXT_MOVE_MAX_BLOCK_SIZE Recommended value is between 5-7.
Phase2Intensity Recommend setting this as Low or Medium. Set as Low if the Phase 2 construction heuristics are too slow. Setting it as High can increase performance on some instances but may be very slow on some instances. It is recommended to not set it as Unlimited.
POSITIVE_GAIN_HEURISTICThis field is no longer used.
Obsolete
PreferredRunTime In milliseconds.
ROSTER_CONSTRUCTION_HEURISTICS Recommend setting this as true as it is very useful for some instances.
ROSTER_CONSTRUCTION_HEURISTICS_DURING_VDSThis field is no longer used.
Obsolete
SYSTEM_TIME_RANDOM_SEED Uses the system time as the random seed if true.
TEST_PATTERNS_MAX_ATTEMPTSThis field is no longer used.
Obsolete
TIME_LIMIT If true then the search will finish when PreferredRunTime is reached. If false it will finish once a single iteration is completed. The time taken for a single iteration can vary significantly depending on the instance being solved.
VIOLATION_FLAG_HEURISTICThis field is no longer used.
Obsolete

See Also