You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I have an optimization problem I want to solve with Ipopt. I have implemented the problem both with Pagmo using Ipopt solver, and directly over the Ipopt interface.
So far, I have managed to get the same results for both interfaces, using Hessian approximation. I wanted to implement now the exact Hessian. My problem is implemented in an external class, and I just call the corresponding methods in pagmo/Ipopt interface and adapt the input/output.
With the exact Hessian, I am getting similar results, but not exactly the same ones. I wanted to ask if my understanding to implement the Hessian with Pagmo is correct.
Following the docs, I use the default Hessian pattern, i.e, assume a dense matrix. I have 2 variables, and 2 constraint functions. therefore, my hessians function in Pagmo, returns something like this for a certain vector x:
So the computation of the Hessian is the same, the difference (constraints cancel out in this case) is just the format required, as Pagmo requires the Hessian of each constraint function. I know it's pretty hard to tell what it could be wrong, so my question is more about:
Is the format correct? In both cases, I return the lower triangle of the Hessian
Is there anything hardcoded for Pagmo that I should be aware of and I could be missing?
Thank you for your time.
The text was updated successfully, but these errors were encountered:
I have an optimization problem I want to solve with Ipopt. I have implemented the problem both with Pagmo using Ipopt solver, and directly over the Ipopt interface.
So far, I have managed to get the same results for both interfaces, using Hessian approximation. I wanted to implement now the exact Hessian. My problem is implemented in an external class, and I just call the corresponding methods in pagmo/Ipopt interface and adapt the input/output.
With the exact Hessian, I am getting similar results, but not exactly the same ones. I wanted to ask if my understanding to implement the Hessian with Pagmo is correct.
Following the docs, I use the default Hessian pattern, i.e, assume a dense matrix. I have 2 variables, and 2 constraint functions. therefore, my
hessians
function in Pagmo, returns something like this for a certain vectorx
:hessian = [ [1.48304e-10 , 2.77556e-15, 5.55334e-11], [2, 0, 0], [-2, 0, 0] ]
In Ipopt, for the same vector and exactly the same setUp, I return:
hessian = [ 1.48304e-10, 2.77556e-15, 5.55334e-11]
So the computation of the Hessian is the same, the difference (constraints cancel out in this case) is just the format required, as Pagmo requires the Hessian of each constraint function. I know it's pretty hard to tell what it could be wrong, so my question is more about:
Thank you for your time.
The text was updated successfully, but these errors were encountered: