fmincon nonlinear constraints

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 个评论

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]

请先登录,再进行评论。

回答(1 个)

Sean de Wolski
Sean de Wolski 2012-2-27

0 个投票

If you concatenate them, C could contain both constraint matrices?

类别

在 帮助中心 和 File Exchange 中查找有关 Nonlinear Optimization 的更多信息

提问:

2011-2-8

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by