[Ipopt] derivative checker

loerx loerx at uni-trier.de
Sun Nov 14 08:57:49 EST 2010


Hi,

I have some problems with the derivative checker. I provided a starting point of (0.25, -0.4, 0.5, 1), however, ipopt performs a derivative check at (-9.7249748222296830, 0.87170628986480203, -5.6339152195806754, 7.1748100222785105).
The starting point seems to be right until the function IpoptSolve is called. Then for some reasons the starting point changes and after the derivative check Ipopt starts the optimization with the right starting point.


Code:

...

/* create the IpoptProblem */
nlp = CreateIpoptProblem(n, x_L, x_U, m, NULL, NULL, 0, 0, 0,&eval_f,&eval_g,&eval_grad_f,&eval_jac_g,&eval_h);

AddIpoptStrOption(nlp, "hessian_approximation", "limited-memory");
AddIpoptStrOption(nlp, "derivative_test", "first-order");
AddIpoptStrOption(nlp, "derivative_test_print_all", "yes");

/* allocate space for the initial point and set the values */
x = (Number*)malloc(sizeof(Number)*n);
for (k = 0; k<  n; k++)
{
	x[k] = Iparameter[k];
}	

/* allocate space to store the bound multipliers at the solution */
mult_x_L = (Number*)malloc(sizeof(Number)*n);
mult_x_U = (Number*)malloc(sizeof(Number)*n);

/* solve the problem */
status = IpoptSolve(nlp, x, NULL,&obj, NULL, mult_x_L, mult_x_U, NULL);
	
/* free allocated memory */
FreeIpoptProblem(nlp);

...


Any Idea, how to perform the derivative check at the starting point, would be very helpful.

Best regards,
Andre

-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://list.coin-or.org/pipermail/ipopt/attachments/20101114/4d4068b0/attachment.html 


More information about the Ipopt mailing list