Class ExplainingObjective
- java.lang.Object
-
- org.chocosolver.solver.search.loop.lns.neighbors.ExplainingCut
-
- org.chocosolver.solver.search.loop.lns.neighbors.ExplainingObjective
-
- All Implemented Interfaces:
INeighbor
public class ExplainingObjective extends ExplainingCut
a specific neighborhood for LNS based on the explanation of the objective variable.This neightborhood is specific in the sense that it needs to compute explanation on a solution. Furthermore, the fixSomeVariables method creates and applies decision, so that the explanation recorder can infer.
- Since:
- 03/07/13
- Author:
- Charles Prud'homme
-
-
Field Summary
-
Fields inherited from class org.chocosolver.solver.search.loop.lns.neighbors.ExplainingCut
forceCft, mDecisionPath, mExplanationEngine, mModel, nbCall, nbFixedVariables, notFrozen, random, related, unrelated
-
-
Constructor Summary
Constructors Constructor Description ExplainingObjective(Model aModel, int level, long seed)Create a neighborhood which analyses the explanation of the objective current value to focus on decisions more prone to improve its value
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected void_fixVar()Regarding the explanation, pick decisions to create a fragmentprotected voidexplain()Force the failure, apply decisions to the last solution + cut => failure!voidinit()Initialize this neighborvoidrecordSolution()Record values of decision variables to freeze some ones during the next LNS run-
Methods inherited from class org.chocosolver.solver.search.loop.lns.neighbors.ExplainingCut
clonePath, fixSomeVariables, increaseLimit, isSearchComplete, loadFromSolution, restrictLess
-
-
-
-
Constructor Detail
-
ExplainingObjective
public ExplainingObjective(Model aModel, int level, long seed)
Create a neighborhood which analyses the explanation of the objective current value to focus on decisions more prone to improve its value- Parameters:
aModel- a modellevel- relaxong factorseed- for randomness
-
-
Method Detail
-
recordSolution
public void recordSolution()
Description copied from interface:INeighborRecord values of decision variables to freeze some ones during the next LNS run- Specified by:
recordSolutionin interfaceINeighbor- Overrides:
recordSolutionin classExplainingCut
-
_fixVar
protected void _fixVar()
Description copied from class:ExplainingCutRegarding the explanation, pick decisions to create a fragment- Overrides:
_fixVarin classExplainingCut
-
init
public void init()
Description copied from interface:INeighborInitialize this neighbor- Specified by:
initin interfaceINeighbor- Overrides:
initin classExplainingCut
-
explain
protected void explain()
Description copied from class:ExplainingCutForce the failure, apply decisions to the last solution + cut => failure!- Overrides:
explainin classExplainingCut
-
-