V - VariableT - Valuepublic class MetaHeuristicSearch<V extends Variable<V,T>,T extends Value<V,T>> extends NeighbourSelectionWithContext<V,T,MetaHeuristicSearch.MetaHeuristicSearchContext>
StandardNeighbourSelection) until all variables are assigned (this heuristics is also used whenever the solution becomes incomplete, until it is complete again),
HillClimber) until the given number if idle iterations (this phase is optional)
GreatDeluge or SimulatedAnnealing) until timeout is reached
SimpleSearch, however each phase can be customized by providing the appropriate neighbor selection.
Also, a different selection can be used in each thread.
| Modifier and Type | Class and Description |
|---|---|
class |
MetaHeuristicSearch.MetaHeuristicSearchContext |
iContextOverridesMaxSize| Constructor and Description |
|---|
MetaHeuristicSearch(DataProperties properties)
Constructor
MetaHeuristic.ConstructionClass ... construction heuristics (if needed)
MetaHeuristic.IncompleteClass ... incomplete heuristics (e.g.,
StandardNeighbourSelection)
MetaHeuristic.HillClimberClass ... hill-climber heuristics (e.g., HillClimber or StepCountingHillClimber)
MetaHeuristic.ImprovementClass ... improvement heuristics (e.g., SimulatedAnnealing or GreatDeluge)
|
| Modifier and Type | Method and Description |
|---|---|
MetaHeuristicSearch.MetaHeuristicSearchContext |
createAssignmentContext(Assignment<V,T> assignment)
Create a new assignment context for the given assignment.
|
void |
init(Solver<V,T> solver)
Initialization
|
Neighbour<V,T> |
selectNeighbour(Solution<V,T> solution)
Neighbour selection.
|
getAssignmentContextReference, getContext, getContext, hasContextOverride, isSingleContextSolver, setAssignmentContextReferencepublic MetaHeuristicSearch(DataProperties properties)
StandardNeighbourSelection)
HillClimber or StepCountingHillClimber)
SimulatedAnnealing or GreatDeluge)
properties - problem configurationpublic Neighbour<V,T> selectNeighbour(Solution<V,T> solution)
StandardNeighbourSelection) until all variables are assigned (this heuristics is also used whenever the solution becomes incomplete, until it is complete again),
HillClimber) until the given number if idle iterations (this phase is optional)
GreatDeluge or SimulatedAnnealing) until timeout is reached
solution - given solutionpublic MetaHeuristicSearch.MetaHeuristicSearchContext createAssignmentContext(Assignment<V,T> assignment)
HasAssignmentContextassignment - an assignment for which there needs to be an assignment context