scratch.scott.optimization
Class SimulatedAnnealer

java.lang.Object
  extended by edu.uci.ics.jung.algorithms.IterativeProcess
      extended by scratch.scott.optimization.SimulatedAnnealer

public class SimulatedAnnealer
extends IterativeProcess

A general implementation of simulated annealing. Requires the user to provide his/her own Configuration implementation representing the current best solution instance. In addition several parameters are required to instruct the annealer how best to proceed. These include:

In most cases, significant tweaking of the parameters is required before fast convergence is achieved.

Author:
Scott White

Constructor Summary
SimulatedAnnealer(Configuration solution, double startingTemperature, double freezingPoint, double coolingRate, double nTries, double acceptanceRate, int seed)
           
 
Method Summary
protected  double evaluateIteration()
          Evaluate the result of the current interation.
 Configuration getBestConfiguration()
          Returns the best solution found so far.
 
Methods inherited from class edu.uci.ics.jung.algorithms.IterativeProcess
evaluate, finalizeIterations, getDesiredPrecision, getIterations, getMaximumIterations, getPrecision, hasConverged, initializeIterations, reinitialize, relativePrecision, setDesiredPrecision, setMaximumIterations
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

SimulatedAnnealer

public SimulatedAnnealer(Configuration solution,
                         double startingTemperature,
                         double freezingPoint,
                         double coolingRate,
                         double nTries,
                         double acceptanceRate,
                         int seed)
Method Detail

evaluateIteration

protected double evaluateIteration()
Description copied from class: IterativeProcess
Evaluate the result of the current interation.

Specified by:
evaluateIteration in class IterativeProcess
Returns:
the estimated precision of the result.

getBestConfiguration

public Configuration getBestConfiguration()
Returns the best solution found so far.

Returns:
the solution configuration