There are something difference between MATLAB and Octave.

classic Classic list List threaded Threaded
3 messages Options
Reply | Threaded
Open this post in threaded view
|

There are something difference between MATLAB and Octave.

Dildar Sk
I am doing rigorous accuracy tests of Octave functions comparing with MATLAB.
I used to think Octave to be clone of MATLAB. But there I found many
mismatches.
I used to think Octave to be subset of MATLAB but that's not totally true
because sometimes
Octave's function doing much more than MATLAB's same function. Was it all
time like
this? Is it intended?



--
Sent from: http://octave.1599824.n4.nabble.com/Octave-Maintainers-f1638794.html

Reply | Threaded
Open this post in threaded view
|

Re: There are something difference between MATLAB and Octave.

nrjank
On Sat, Mar 24, 2018, 11:36 AM Dildar Sk <[hidden email]> wrote:
I am doing rigorous accuracy tests of Octave functions comparing with MATLAB.
I used to think Octave to be clone of MATLAB. But there I found many
mismatches.
I used to think Octave to be subset of MATLAB but that's not totally true
because sometimes
Octave's function doing much more than MATLAB's same function. Was it all
time like
this? Is it intended?

Octave is an independent program designed to be m-code compatible. It is considered to be a bug if an incompatibility is found with MATLAB processed m-code, but Octave functions are not limited by MATLAB's operation. Ideally, Octave would be a superset of MATLAB function, with perfect compatibility where they overlap.  In practice, the available function set only covers those features that Octave's  volunteer contributors have chosen to implement. And in those cases attempting to create compatibility can be a challenge especially with the infinite possibilities for implementing some numerical operations. Last, maintaining Matlab compatibility is of course a moving target as new releases come out twice a year.

 If you are finding places with particular levels of numerical error or in accuracy, those should be reported as bugs so that they can be addressed if practical
Reply | Threaded
Open this post in threaded view
|

Re: There are something difference between MATLAB and Octave.

Mike Miller-4
In reply to this post by Dildar Sk
On Sat, Mar 24, 2018 at 05:21:08 -0700, Dildar Sk wrote:
> I used to think Octave to be clone of MATLAB but that is
> not totally true because there are some Octave's function which doing much
> better than MATLAB's. There are some difference rules also. Was it like this
> all time. Is it intended?

We find it useful to think of Octave as a superset of Matlab. Not in
terms of which functions are available, but in terms of support for the
language and syntax, and in some cases, whether arguments to a
particular function are valid.

A useful rule of thumb is if a statement or function call does not raise
an error in Matlab, then we generally try to be compatible.

If certain arguments do raise an error in Matlab but not in Octave, we
usually do not consider that an incompatibility.

As you have discovered, some numeric functions report an error when they
are given a character array, and some operate on it as if it were
numeric with no error. Matlab has the same issue, with different sets of
functions. For any Matlab function that allows character arguments, the
Octave function should also allow it (for example abs). But the inverse
does not have to be true.

--
mike

signature.asc (849 bytes) Download Attachment