[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Octave-bug-tracker] [bug #49449] odeplot is not fully Matlab compatible
From: |
Sebastian |
Subject: |
[Octave-bug-tracker] [bug #49449] odeplot is not fully Matlab compatible |
Date: |
Wed, 26 Oct 2016 18:27:17 +0000 (UTC) |
User-agent: |
Mozilla/5.0 (Macintosh; Intel Mac OS X 10_12_1) AppleWebKit/602.2.14 (KHTML, like Gecko) Version/10.0.1 Safari/602.2.14 |
Follow-up Comment #3, bug #49449 (project octave):
Sorry, my explanation was insufficient and two things got mixed up:
1. the current octave implementation of odeplot is not fully Matlab
compatible. It only plots the last entry of the vectors given and Octave cares
whether you supply row or column vectors. However, it's working in most cases
but probably not if we implement "refine" in odeXY.
I have executed the following lines with Matlab, Octave with and without patch
(see figures attached):
odeplot([0 10],[0;0],'init');
odeplot([0:10],[(0:10);(0:10).^2],[]);
odeplot([0:10],2*[(0:10);(0:10).^2],[]);
2. I made a new version that is slower but this is no surprise: it always
plots the whole data (as Matlab does). Matlab seems to store the data
persistently in odeplot and to concatenate the vectors in each call of
odeplot. This can be seen in the attached figure "matlab.png". There is a
straight line from (10,100) to (0,0). My implementation avoids this by using
"hold on" and "hold off", so I am more memory efficient but not
Matlab-bug-compatible.
(file #38819, file #38820, file #38821)
_______________________________________________________
Additional Item Attachment:
File name: matlab.png Size:100 KB
File name: octave_patched.png Size:114 KB
File name: octave_current.png Size:76 KB
_______________________________________________________
Reply to this item at:
<http://savannah.gnu.org/bugs/?49449>
_______________________________________________
Message sent via/by Savannah
http://savannah.gnu.org/