octave-bug-tracker
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Octave-bug-tracker] [bug #58944] [z, r, p]=qr(a, b) unexpectedly return


From: Rik
Subject: [Octave-bug-tracker] [bug #58944] [z, r, p]=qr(a, b) unexpectedly returns z as q instead of q' * b
Date: Mon, 25 Jan 2021 19:28:58 -0500 (EST)
User-agent: Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/87.0.4280.66 Safari/537.36

Follow-up Comment #11, bug #58944 (project octave):

@Markus: Sorry, I think I misled you.  The 3-output argument syntax is valid
for dense matrices as long as there is just a single matrix A.  This is what
polyfit.m is relying on and, as I said, it is valid.  The extra argument '0'
in 


[q,r,p] = qr (a, 0);


is not a matrix B, but a flag asking for an "economy"-sized return value.

So, I think the input validation needs to look like


if (have_b && nargout > 2)
  error (...)



    _______________________________________________________

Reply to this item at:

  <https://savannah.gnu.org/bugs/?58944>

_______________________________________________
  Message sent via Savannah
  https://savannah.gnu.org/




reply via email to

[Prev in Thread] Current Thread [Next in Thread]