In fmincon function, how can I impose non-strict constraints?
조회 수: 2 (최근 30일)
이전 댓글 표시
In fmincon, I know MATLAB can set constraints like a+b<=1 and a<=1, but what about a+b<1 and a<1?
댓글 수: 0
채택된 답변
Alan Weiss
2016년 2월 24일
There is a tolerance called TolCon that gives the wiggle room for constraint violation. So, if you have options such as
options = optimoptions('fmincon');
then, similar to Walter's suggestion, you can try to enforce
a + b <= 1 - options.TolCon; % in a linear inequality constraint
a <= 1 - options.TolCon; % in a bound
Alan Weiss
MATLAB mathematical toolbox documentation
댓글 수: 0
추가 답변 (2개)
Torsten
2016년 2월 24일
Strict constraints (like a<1 or a+b<1) don't make sense in optimization.
Usually, you can only guarantee solutions over compact (i.e. closed and bounded) feasible regions.
Conditions like a<1 or a+b<1 lead to open (i.e. non-closed) regions.
Best wishes
Torsten.
댓글 수: 0
참고 항목
카테고리
Help Center 및 File Exchange에서 Nonlinear Optimization에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!