Menu

#3 Incorrect solution

v1.0 (example)
open
nobody
None
5
2014-05-07
2014-05-07
Takano Akio
No

The attached program uses QuadProg++ to solve a quadratic program given to stdin. However with the attached input, it returns an incorrect value for the value of the objective function. Specifically, it outputs -2.057085691903112e+32, which is much lower than the unbounded solution of this problem.

It looks to me that the issue is in the part of the code which check s whether 'z' is 0. It can be numeraically non-zero even though it's mathematically zero, and this can result in a huge negative value for the 't2' step size.

I attached a patch to QuadProg++.cc that seems to fix the problem. However this patch hasn't been tested throughly and I'm not 100% sure this is the right way to fix the problem.

1 Attachments

Discussion

  • Takano Akio

    Takano Akio - 2014-05-07

    Input file.

     
  • Takano Akio

    Takano Akio - 2014-05-07

    Patch.

     

Log in to post a comment.

Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.