I am trying to interface SPRAL with IPOPT. I am running into some issues with getting the right output for a simple optimization problem too. The sequence of function calls that are made in IpSpralSolverInterface.cpp is:
spral_ssids_analyse_ptr32(false, ndim_, NULL, ia, ja, val_, &akeep_, &control_, &info);
spral_ssids_factor_ptr32(false, ia, ja, val_, scaling_, akeep_, &fkeep_, &control_, &info);
spral_ssids_solve(0, nrhs, rhs_vals, ndim_, akeep_, fkeep_, &control_, &info);
This is different from the calls made in ssids.c that comes with SPRAL Git repository.
/* Perform analyse and factorise with data checking */
bool check = true;
spral_ssids_analyse(check, n, NULL, ptr, row, NULL, &akeep, &options,
&inform);
if(inform.flag<0) {
spral_ssids_free(&akeep, &fkeep);
exit(1);
}
spral_ssids_factor(posdef, NULL, NULL, val, NULL, akeep, &fkeep, &options,
&inform);
if(inform.flag<0) {
spral_ssids_free(&akeep, &fkeep);
exit(1);
}
/* Solve */
spral_ssids_solve1(0, x, akeep, fkeep, &options, &inform);
if(inform.flag<0) {
spral_ssids_free(&akeep, &fkeep);
exit(1);
}
Could someone please clarify as to which function calls are more appropriate?
I am trying to interface SPRAL with IPOPT. I am running into some issues with getting the right output for a simple optimization problem too. The sequence of function calls that are made in
IpSpralSolverInterface.cppis:This is different from the calls made in
ssids.cthat comes with SPRAL Git repository.Could someone please clarify as to which function calls are more appropriate?