Second Order optimality fmincon
1 次查看(过去 30 天)
显示 更早的评论
Someone explained the second order condition for optimality of a constrained optimization problem here:
So I should take the Hessian, and ZZ = nullspace of the jacobian of all active constraints, and then it is an optimal point if
Z'*Hessian*Z >= 0.
Here is my code:
[xx,~,~,~,~,~,hess] = fmincon(@(XX)-XX(1)^2-XX(2)^2,[0.3,0.3],[],[],[1,1],1);
ZZ= null([1,1])
ZZ'*hess*ZZ
The active linear constraint: x1 + x2 = Q, so I thought the Jacobian of the only actice constraint is [1,1].
Matlab's nullspace: ZZ = [-sqrt(2)/2;sqrt(2)/2)];
Z'*Hessian*ZZ is 1, but the point is not a local minimum (only stationary point). I want to proof numerically that it is only a staionary point.
What goes wrong?
0 个评论
回答(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!