Constructor and Description |
---|
BackTrackNeighbour(BacktrackNeighbourSelection.BacktrackNeighbourSelectionContext context,
List<V> resolvedVariables)
Constructor
|
BackTrackNeighbour(BacktrackNeighbourSelection.BacktrackNeighbourSelectionContext context,
V... resolvedVariables)
Constructor
|
Modifier and Type | Method and Description |
---|---|
void |
assign(Assignment<V,T> assignment,
long iteration)
Assign the neighbour
|
Map<V,T> |
assignments()
Return assignments to be done.
|
int |
compareTo(Solution<V,T> solution)
Compare two neighbours
|
List<T> |
getAssignments()
Neighbour assignments
|
double |
getTotalValue()
Neighbour value (solution total value if the neighbour is applied).
|
String |
toString() |
double |
value(Assignment<V,T> assignment)
Sum of values of variables from the neighbour that change their
values
|
public BackTrackNeighbour(BacktrackNeighbourSelection.BacktrackNeighbourSelectionContext context, List<V> resolvedVariables)
context
- assignment contextresolvedVariables
- variables that has been changedpublic BackTrackNeighbour(BacktrackNeighbourSelection.BacktrackNeighbourSelectionContext context, V... resolvedVariables)
context
- assignment contextresolvedVariables
- variables that has been changedpublic double getTotalValue()
public double value(Assignment<V,T> assignment)
public List<T> getAssignments()
public void assign(Assignment<V,T> assignment, long iteration)
public int compareTo(Solution<V,T> solution)
solution
- current solution