bugGNU Octave - Bugs: bug #64901, Quadratic programming does not work

 
 

bug #64901: Quadratic programming does not work

Submitter:  Antonio Fuduli <antfud>
Submitted:  Thu 16 Nov 2023 02:43:59 PM UTC
   
 
Category:  Octave Function Severity:  3 - Normal
Priority:  5 - Normal Item Group:  Incorrect Result
Status:  None Assigned to:  None
Originator Name:  Antonio Fuduli Open/Closed:  * Open
Release:  * stable Operating System:  * Microsoft Windows
Fixed Release:  None Planned Release:  None
* Mandatory Fields

Add a New Comment Rich Markup
   

Thu 16 Nov 2023 03:50:09 PM UTC, comment #2: 

@Antonio as a temporary workaround for your teaching while this is being resolved, you can make the following edit to the file scripts/optimization/qp.m in your Octave installation.

Near line 350 you will see these three lines:


if (isdefinite (H) != 1)
  info = 2;
endif


Comment out those three lines and it should work with positive semidefinite matrices.

Arun Giridhar <arungiridhar>
Group Member
Thu 16 Nov 2023 03:39:22 PM UTC, comment #1: 

That change was made for bug #61762.

Related bug #64346.

Copying Julien Bect and Olaf Till.

Arun Giridhar <arungiridhar>
Group Member
Thu 16 Nov 2023 02:43:59 PM UTC, original submission:  

Dear Sirs,

subroutine qp, solving quadratic programming problems, does not work (info = 2) when the Hessian is positive semidefinite. It works only when the Hessian is positive definite. This bug is also present in the 8.4 version, starting from the 8.1 version.

Note that this bag IS NOT PRESENT in the 7.3 version.

Is it possible to fix it as soon as possible? I need it for teaching Optimization.

I attach file "prova.m": you can verify that the problem is solved by the 7.3 version, but it fails if we use the new versions 8.1, 8.2, 8.3 and 8.4.  

Thank you very much.

Antonio Fuduli

Antonio Fuduli <antfud>

 

(Note: upload size limit is set to 16384 kB, after insertion of the required escape characters.)

Attach Files:
   
   
Comment:
   

Attached Files
file #55332:  prova.m added by antfud (440B - text/plain)

 

Carbon-Copy List
  • -email is unavailable- added by arungiridhar (Posted a comment)
  • -email is unavailable- added by arungiridhar
  • -email is unavailable- added by arungiridhar
  • -email is unavailable- added by antfud (Submitted the item)
  •  

    There are 0 votes so far. Votes easily highlight which items people would like to see resolved in priority, independently of the priority of the item set by tracker managers.

    Only group members can vote.

     

    Follow 6 latest changes.

    Date Changed by Updated Field Previous Value => Replaced by
    2023-11-16 arungiridhar Dependencies- Depends on bugs #64346
    2023-11-16 arungiridhar Dependencies- Depends on bugs #61762
    2023-11-16 arungiridhar Release8.3.0 stable
        Carbon-Copy- Added jbect
        Carbon-Copy- Added i7tiol
    2023-11-16 antfud Attached File- Added prova.m, #55332

    Back to the top

    Powered by Savane 3.13-4b48.
    Corresponding source code