How does Matlab's simulannealbnd enforce bound constraints?
2 visualizzazioni (ultimi 30 giorni)
Mostra commenti meno recenti
Sepp
il 1 Giu 2016
Commentato: Walter Roberson
il 2 Giu 2016
Hello
I'm using the simulannealbnd Function of Matlab for finding the minimum of a function using simulated annealing. As arguments one can pass lower and upper bounds of the variables. In the documentation it is described how simulated annealing works but there is nothing about how the bound constraints are enforced.
Does somebody know (or can imagine) how this is done in this case?
1 Commento
John D'Errico
il 1 Giu 2016
Modificato: John D'Errico
il 1 Giu 2016
(As the author of fminsearchbnd) I can think of (or even imagine) several ways. Bound constraints are pretty easy. I have no idea how it actually accomplishes the job though, at least without looking at the code, when it would become pretty clear. Since I doubt the code is compiled, just read through it.
Risposta accettata
Walter Roberson
il 1 Giu 2016
The AnnealingFcn that you designate is responsible for ensuring that the constraints are honoured. The standard annealingfast routine calls sahonorbounds for this purpose. The code there projects randomly a portion of the way between the current point and the bound when a bound would be violated. See toolbox/globaloptim/globaloptim/private/sahonorbounds.m
2 Commenti
Walter Roberson
il 2 Giu 2016
Approximate translation:
I have now read the disclaimer in the documentation that explains how Simulate Annealing work (<http://ch.mathworks.com/help/gads/how-simulated-annealing-works.html)>. Two points are to me as unclear:
Step 2: A poorer point (as the currently best point) can be accepted with a certain probability. @acceptancesa If you use gets you a probability between 0 and 0.5 (according to documentation). When the new point is now just accepted? So if, for example, the probability of acceptance is 0.3, you have to decide if now the point is accepted or not still.
Step 4: reannealing. Here is the parameter sj described as follows: "gradient of objective in direction i times difference in bounds in direction i». How is this gradient? I admit yes only the objective function. With the difference in bound I suppose that upper bound - lower bound is meant.
Più risposte (0)
Vedere anche
Categorie
Scopri di più su Simulated Annealing in Help Center e File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!