Optimization using Simulated Annealing (SA)

The m-file code is made available here. The code is pretty much self-documented, readable and follow-able, so you will know how to use it immediately (or in the worst case, eventually j/k). Good luck!

In brief, the SA code is made for maximization problem, that is, you will need to formulate your problem as a maximization problem when using this toolbox. The plot above shows the score at each iteration; each symbol means the following:

  • Blue dot: The solution is accepted because the new solution is better than the current solution
  • Green circle: The new solution is not only better than current solution, but also better than the best solution so far. That is, the new solution is the best solution so far too.
  • Cyan dot: The new solution is poorer than the current solution, but is accepted because of "luck".
  • Red cross: The new solution is rejected because it is much worse than the current solution.