How to create simulated annealing objective function?
Mostra commenti meno recenti
Hello!
I want to create a objective function for Travelling salesman problem using simulated annealing with global optimization toolbox.
Does anyone have idea how to make these?
Thank you for help
3 Commenti
Walter Roberson
il 28 Mag 2015
Modificato: Walter Roberson
il 28 Mag 2015
See http://uk.mathworks.com/matlabcentral/answers/64840-can-anyone-suggest-me-to-write-a-correct-and-working-code-for-traveling-salesman-problem-using-simul for one approach
You might also find it useful to look at the Traveling Salesman GA demo. I cannot look at it myself as I do not have the appropriate license, but the link is said to be http://www.mathworks.com/products/global-optimization/demos.html?file=/products/demos/shipping/globaloptim/traveling_salesman_demo.html
jan grlica
il 28 Mag 2015
jan grlica
il 28 Mag 2015
Modificato: Walter Roberson
il 28 Mag 2015
Risposte (2)
Alan Weiss
il 28 Mag 2015
Modificato: Alan Weiss
il 28 Mag 2015
0 voti
The simulated annealing solver is based on continuous variables by default. Perhaps you could make it work for a custom data type, similar to the genetic algorithm solution. But travelling salesman problems are most easily formulated for integer variables. For solutions, see this MILP example which uses Optimization Toolbox, or this genetic algorithm example using Global Optimization Toolbox and a custom data type.
Alan Weiss
MATLAB mathematical toolbox documentation
1 Commento
jan grlica
il 28 Mag 2015
Walter Roberson
il 28 Mag 2015
0 voti
See my discussion in http://uk.mathworks.com/matlabcentral/answers/220440-simulated-annealing-how-to-solve-this-error as to what the problem is here (the code has exactly the same basic problem here), and as to why it is hard to fix.
The short summary: you can use Simulated Annealing techniques with Traveling Salesperson, but using simulannealbnd() itself for the problem is going to be difficult.
Categorie
Scopri di più su Simulated Annealing in Centro assistenza e File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!