[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Octave-bug-tracker] [bug #32901] "diag" returns empty matrix where matl
From: |
Marco Caliari |
Subject: |
[Octave-bug-tracker] [bug #32901] "diag" returns empty matrix where matlab's diag returns [0] |
Date: |
Tue, 29 Mar 2011 10:06:42 +0000 |
User-agent: |
Mozilla/5.0 (X11; U; Linux i686; en-GB; rv:1.9.2.13) Gecko/20101203 Firefox/3.6.13 |
Follow-up Comment #5, bug #32901 (project octave):
Before any modification, I think we should consider whether
diag(diag(v,k),k)
should coincide with v for any column vector v (or with v.' for any row vector
v) and any integer k. This is actually true for length(v)>=1. It is not true
for v=zeros(1,0) (or v=zeros(0,1)) and k=1 in Matlab and never true in Octave.
Later, the behaviour of spdiags should be the same of diag when creating
matrices. This is actually not always true, both in Matlab and Octave, with
the bad guys zeros(1,0) and zeros(0,1).
Marco
_______________________________________________________
Reply to this item at:
<http://savannah.gnu.org/bugs/?32901>
_______________________________________________
Message sent via/by Savannah
http://savannah.gnu.org/