scratch.scott.optimization
Interface Configuration

All Known Implementing Classes:
TestSimulatedAnnealer.TestConfiguration

public interface Configuration

Interface used by SimulatedAnnealer which represents the current best solution found during a search. Classes that implement this interface will typically have some idea of the overall fitness or energy of any given solution and so will implement computeEnergy accordingly. Similarly, they will have some idea of how to permute the configuration into another possible solution based on the current "temperature" and the min,max values of the possible range of temperature and thus will implement melt(...) accordingly.

Author:
Scott White

Method Summary
 double computeEnergy()
          Computes the energy or fitness of the current configuration.
 Configuration melt(double temperature, double maxTemp, double minTemp)
          Randomly perturbs the current configuration in some way.
 

Method Detail

computeEnergy

double computeEnergy()
Computes the energy or fitness of the current configuration.

Returns:
double value representing the computed energy

melt

Configuration melt(double temperature,
                   double maxTemp,
                   double minTemp)
Randomly perturbs the current configuration in some way.

Parameters:
temperature - the current temperature of the system
maxTemp - the highest temperature the system can go to
minTemp - the lowest temperature the system can go to
Returns:
the newly perturbed configuration