help-octave
[Top][All Lists]
Advanced

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

Re: lsqlin() error message


From: Nicholas Jankowski
Subject: Re: lsqlin() error message
Date: Fri, 5 Jul 2019 11:24:17 -0400

On Fri, Jul 5, 2019, 8:27 AM Ardid, Salva <address@hidden> wrote:

El divendres, 5 de juliol de 2019, a les 7:58:14 EDT, GoSim va escriure:

  I don't have Matlab.



  --
  Sent from: http://octave.1599824.n4.nabble.com/Octave-General-f1599825.html

For the case it is useful, in Matlab 2019a:

>> C = [1 2 3;4 5 6; 2 4 6]

C =

     1     2     3
     4     5     6
     2     4     6

>> D=[4 5 8]'

D =

     4
     5
     8

>> lsqlin(C,D,[],[])

ans =

   NaN
   NaN
   NaN



Ok so it appears the compatibility bug is that MATLAB produces a non-error output of NaNs, and Octave throws an error when the inputs are not linearly independent.  Might be worth playing around with the MATLAB outputs a bit more to see if there are any other corner cases octave doesn't capture. 

Whether or not to add a noncompatible flag to have octave clip out the linearly dependent input as per GoSim's suggestion may warrant further discussion.


reply via email to

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