perform a branch and bound optimization
10 vues (au cours des 30 derniers jours)
Afficher commentaires plus anciens
Hi, I need to perform an optimization whose variable is a matrix that has to have only binary values inside (0, 1). To obtain this I tought I could use a branch and bound algorithm, the problem is that I cannot find any optimization function in matlab that can be set with this algorithm. I found this old function on this website,
It would be perfect but once I try to use it it gives me this error
??? Input argument "x0" is undefined.
Error in ==> objfun at 7
It seems that the object function does not "read" the initialized variable x0.
If you could help me performing my optimization with this or any other function I would be extremely grateful (it is for my master thesis)
Thank you in advance
I.
1 commentaire
John D'Errico
le 23 Juin 2015
Modifié(e) : John D'Errico
le 23 Juin 2015
Functions don't "read" variables from your workspace. You need to pass them in. Think about how you use ANY function in MATLAB. Do those functions just magically know how you want to use them, and what you intend to pass in? For example, consider the function mean. You pass in an argument. All functions are the same in this respect.
Réponses (0)
Voir également
Catégories
En savoir plus sur Problem-Based Optimization Setup dans Help Center et File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!