bugGNU Octave - Bugs: bug #45324, optimization/qp.m: allow row...

 
 

bug #45324: optimization/qp.m: allow row vectors for argument q

Submitted by:  Olaf Till <i7tiol>
Submitted on:  Mon 15 Jun 2015 03:27:57 PM UTC  
 
Category: Octave FunctionSeverity: 3 - Normal
Priority: 5 - NormalItem Group: Feature Request
Status: FixedAssigned to: None
Originator Name: Open/Closed: Closed
Release: devOperating System: Any

Add a New Comment(Rich Markup)
   

You are not logged in

Please log in, so followups can be emailed to you.

 

Mon 15 Jun 2015 09:10:32 PM UTC, comment #3:

I cleaned up the qp code signicantly on the development branch which included fixing the orientation issue for q and x0. See changeset http://hg.savannah.gnu.org/hgweb/octave/rev/5c088348fddb. Closing report.

Rik <rik5>
Project Administrator
Mon 15 Jun 2015 08:03:57 PM UTC, comment #2:

See attached.

A row vector x0 was accepted because _qp_ accepted it (but not a row vector q). Transformed both x0 and q in qp.m.patch anyway.

I meant that qp.m should also directly be callable with also q in both orientations, not only x0. So a vector is not guaranteed since it's direct user input.

(file #34228)

Olaf Till <i7tiol>
Project Member
Mon 15 Jun 2015 07:16:32 PM UTC, comment #1:

Could you post a changeset, or indicate what you want changed?

The input processing for qp.m is

which seems to accept either row or column. Is 'q' guaranteed to be a vector (column or row)? Then it is possible to change to

which will guarantee a column vector.

I also don't see in the code that we are guaranteeing that x0 is a column vector. Does qp really work regardless of the orientation of x0?

It doesn't appear that this multiplication would work correctly if x0 is a row vector.

Rik <rik5>
Project Administrator
Mon 15 Jun 2015 03:27:57 PM UTC, original submission:

Using quadprog of optim, which wraps qp, 'rocketsound' noticed that Matlab allows both column- and row-vectors for the coefficient of the linear term. qp should probably allow for row-vectors in this argument ('q'), since it already does allow for row-vectors in argument 'x0'. Could someone with write access make this minor change.

Olaf Till <i7tiol>
Project Member

 

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

Attach File(s):
   
   
Comment:
   

Attached Files
file #34228:  qp.m.patch added by i7tiol (1KiB - text/x-patch)

 

Depends on the following items: None found

Items that depend on this one: None found

 

Carbon-Copy List
  • -unavailable- added by rik5 (Posted a comment)
  • -unavailable- added by i7tiol (Submitted the item)
  •  

    Do you think this task is very important?
    If so, you can click here to add your encouragement to it.
    This task has 0 encouragements so far.

    Only project members can vote.

     

    Please enter the title of George Orwell's famous dystopian book (it's a date):

     

     

    Follow 4 latest changes.

    Date Changed By Updated Field Previous Value => Replaced By
    Mon 15 Jun 2015 09:10:32 PM UTCrik5StatusNone=>Fixed
      Open/ClosedOpen=>Closed
      Release4.0.0=>dev
    Mon 15 Jun 2015 08:03:57 PM UTCi7tiolAttached File-=>Added qp.m.patch, #34228

    Back to the top


    Powered by Savane 3.1-cleanup1