1
$\begingroup$

I'm working on a project that needs to solve a constraint optimization function. Currently, I'm using Knitro solver and it needs to calculate the the hessian of the lagrangian at x and lambda. I don't understand how to calculate the hessian. The constraint optimization problem is as follows: $\text{minimize}_x 100 -(x_2 - x^2_1)^2 + (1-x_1)^2$ subject to $1\le x_1x_2$, $ 0\le x_1,x_2$,$x_1\le0.5$. The function to calculate the hessian is (it seems that lambda is given): $ t = x_2 - x_1x_1;$ $ h_1 = (-400.0 t) + (800.0 x_1x_1) + 2.0$, $ h_2 = (-400.0 x_1) + \lambda_1$, $ h_3 = 200.0 + \lambda_2 2.0)$ Could you please tell me how to get $h_1,h_2,h_3$ ? Thank you very much.

2 Answers 2