- All Superinterfaces:
- All Known Implementing Classes:
public interface AnnealingSchedule extends Splittable<AnnealingSchedule>
This interface specifies the required functionality for implementations of annealing schedules. Classes that implement this interface are in charge of managing simulated annealing's temperature parameter. Adaptive annealing schedules may have additional state data to maintain.
Method SummaryModifier and TypeMethodDescription
(double neighborCost, double currentCost)Determine whether or not to accept a neighboring solution based on its cost and the current cost, both passed as parameters.
(int maxEvals)Perform any initialization necessary for the annealing schedule at to the start of a run of simulated annealing.
Methods inherited from interface org.cicirello.search.concurrent.Splittable
(int maxEvals)Perform any initialization necessary for the annealing schedule at to the start of a run of simulated annealing. This includes initializing the temperature parameter. This method is called once by implementations of simulated annealing at the start of the run. Implementations of simulated annealing that perform reannealing will also call this once at the start of each reanneal.
maxEvals- The maximum length of the run of simulated annealing about to start. Some annealing schedules depend upon prior knowledge of run length. For those annealing schedules that don't depend upon run length, this parameter is ignored.
(double neighborCost, double currentCost)Determine whether or not to accept a neighboring solution based on its cost and the current cost, both passed as parameters. Lower cost indicates better solution. This method must also update the temperature and any other state data related to the annealing schedule.
neighborCost- The cost of the neighboring solution under consideration.
currentCost- The cost of the current solution.
- true if simulated annealing should accept the neighbor, and false otherwise.