← Back to SA docs

teeline · algorithms/sa

Simulated Annealing

A single tour evolves by random 2-opt swaps. Improvements always accepted; worsenings accepted with probability exp(−ΔE / T). As temperature T cools, acceptance of bad moves drops — shifting from exploration to exploitation.

01234567891011
current tour best tour removed edge added edge city
temperature decay
acceptance probability (last 30)
0iter
150.00T
2255current
2255best
—%acc rate