fmincon nonlinear constraints

6 vues (au cours des 30 derniers jours)
Brooke
Brooke le 8 Fév 2011
when using fmincon, can you only have one nonlinear constraint for "c".
I am doing an optimization that requires analysis on both deflection (Da - D <= 0) and bending stress (sig - siga <= 0). Can I go ahead and just have:
function [def,bend,ceq] = mycon(x) % called in fmincon function def = ... bend = ... ceq = [] end
that will take both of those constraints into account, or do I somehow have to combine them? Any help would be appreciated. Thanks
  1 commentaire
Laurens Bakker
Laurens Bakker le 27 Fév 2012
Which version of MATLAB are you using? I'm asking because in the most recent version, the function that encapsulates the non-linear constraints should only have 2 returns: [c,ceq]

Connectez-vous pour commenter.

Réponses (1)

Sean de Wolski
Sean de Wolski le 27 Fév 2012
If you concatenate them, C could contain both constraint matrices?

Catégories

En savoir plus sur Nonlinear Optimization 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!

Translated by