Matlab 2014a bug with 2x2 determinant
Show older comments
>> det([0,-1;1,1])
ans =
-1
but it should be 1 !!!
This happens with Matlab R2014a on a Macbook Air from 2013, with Mojave OS.
Same sign error whenever the matrix has 0 as first entry. Another example :
>> det([0,0.5;-0.8,-0.5])
ans =
-0.4000
I could not find any report of this bug on the web (after only a quick search though...) Is this a known issue ?
7 Comments
Rik
on 5 Mar 2019
Just to confirm: WolframAlpha link. It is not mentioned in the bug tracker, nor in the release notes. I can't reproduce this on R2015a or R2011a (Windows x64).
If you can reproduce this, you can file a bug report. I doubt Mathworks would release an update, as a long term supported and updated version is still not really there (even if there have been a few updates to non-latest versions).
Out of curiousity, what is the result of
prod(eig([0,0.5;-0.8,-0.5]))
in R2014a?
Walter Roberson
on 5 Mar 2019
(Seems to be fixed by R2018b)
(Note that R2018b is the earliest MATLAB that is supported on Mojave)
Alexis Glaunes
on 6 Mar 2019
Alex Mcaulley
on 6 Mar 2019
It also works with R2016b
Christine Tobler
on 6 Mar 2019
I just ran both commands in R2014a on my Linux machine, and got the right answers. So this is definitely OS-specific.
What outputs do you get if you pass these matrices into LU, like this?
[L, U, P] = lu(A);
Alexis Glaunes
on 6 Mar 2019
Answers (0)
Categories
Find more on Logical in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!