help-octave
[Top][All Lists]
Advanced

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

Re: matlab and octave


From: Geraint Paul Bevan
Subject: Re: matlab and octave
Date: Tue, 18 Nov 2003 13:41:24 +0000
User-agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.4) Gecko/20030624

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Laurent Jacques wrote:

| ---- ismatlab.m
| function out = ismatlab()
| %% Return 1 if you are in matlab and 0 if you are in octave


There are a number of ways of checking whether Matlab or Octave is being
used, but they all depend on checking for some difference between the
programs other than the one which the user is trying to protect against.

Considering that there is now an effort to increase compatability with
Matlab, this could be problematic if the differences which are exploited
cease to exist in the future.

Ideally, there would be agreement with Mathworks for a standard function
~ to return the name of the interpreter being used so that users could
write, for instance,

if (interpreter == matlab)
        something
elseif (interpreter == octave)
        something else
else
        error
end

Has anyone ever tried to get such agreement with Mathworks or does
anyone have any idea if they might be amenable to such a thing?

- --
Geraint Bevan
http://www.mech.gla.ac.uk/~gbevan

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.2.2 (GNU/Linux)

iEYEARECAAYFAj+6IYAACgkQcXV3N50QmNPU5gCcDOaIcR4byu36Xkzv5As7XoqG
fzoAn1LWXc3Cq06f3yKy5TbdZJAT5hZk
=YEEz
-----END PGP SIGNATURE-----



-------------------------------------------------------------
Octave is freely available under the terms of the GNU GPL.

Octave's home on the web:  http://www.octave.org
How to fund new projects:  http://www.octave.org/funding.html
Subscription information:  http://www.octave.org/archive.html
-------------------------------------------------------------



reply via email to

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