ProgrammingThis forum is for all programming questions.
The question does not have to be directly related to Linux and any language is fair game.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
I need MatLab for a course at the university, but it's not an open source software as all of you know, so i wanted to know if there are valid freeware alternatives. I was told to use Octave or Scilab if i didn't want to buy the license and so i would like to know what's better in terms of MatLab compatibility and ease of use, if there are any other (and maybe better) alternatives and also if there are free Simulink-like programs.
AFAIK, Scilab is compatible with MatLab. It even allows to import MatLab files. Though, i don't know how good the compatibility is. You should try and see.
OCTAVE is the way to go, I'm using it from many years now and I share scripts with MATLAB users without any problem. There's some area you must take care of:
-OCTAVE is more permissive for some syntax like string delimiter...
-OCTAVE has many MATLAB toolboxes equivalent out of the box, toolboxes which cost a lot of money for MATLAB
-not sure if GUI design is available under OCTAVE
see this link for more details about compatibility issues
Last edited by jf.argentino; 03-03-2010 at 06:26 AM.
Reason: url tag
GNU Octave is quite usable, and I switched to it from Scilab a while ago. But, of course, Scilab is being developed too, so I'm not up to date with its present capabilities.
you WILL need to buy MatLab
but on the bright side -- student discount --
If I had a choice, I'd switch to Octave from MATLAB because it makes up for the following weaknesses of MATLAB, which shouldn't be present in software that comes at a couple $k subscription price:
MATLAB has no built-in way to run a script from the command line; therefore, integrating it into a larger system of programs and scripts requires a work-around. This is a huge one for me because I design data-analysis systems which are only partially MATLAB. I've written a wrapper script that echoes command-line arguments and list delimiters to MATLAB to simulate script arguments.
MATLAB tramples all over standard output with messages, which means if you're able to run it non-interactively you need to perform some I/O redirection both inside and outside of your MATLAB program.
You always need temporary variables in MATLAB for function returns or subscripts if you want a smaller part of what's returned. For example, if I have a list of matrices and I want the first row of the first matrix, I need to create a variable to store the first matrix, then take the first row of that variable.
A single-user license on a Linux machine means only one user ID has access to it. I've had to write a setuid wrapper in C (setuid root-->matlab user; MATLAB won't accept effective user IDs) just so I didn't have to give out a password to a common account for users to run it (because of that, no GUI for anyone.) On some machines I run a network-licensed version that all user IDs can use, which means it's a gamble whether or not they get to use it when they try to because all licenses might be checked out. The only reason I have a single-user license on my server is I can't afford to find out the next day that my job didn't run because of a licensing error.
I'm not sure about Octave on this one, but MATLAB demands an immense amount of memory on occasion, sometimes varying by an order of magnitude for the same data and process on different occasions; MATLAB is the only thing that's crashed my server. It requires a disproportionate amount of address space, preventing you from enforcing some resource limits.
In summary, I use MATLAB on a regular basis but it's obvious to me the money you spend on it goes toward functions that make pretty graphs and licence enforcement rather than ease of use in practical situations (i.e. when MATLAB isn't the only software in one's life.)
Yes, I'm very biased, but one can be when a lot of money is involved.
Kevin Barry
uhm uhm uhm, so as most of you say Octave is the way... and what about Simulink? is there a program bundled with Octave or something downloadable apart from it?
For what it's worth... (I've never used matlab or similar):
matplotlib (http://matplotlib.sourceforge.net/) tries to emulate a matlab, at least in some way. I don't know if that is only about plots and charts (while assuming you use python + numpy lib for calculations), or if matplotlib aims to be a complete replacement for matlab. May be worth to check out...
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.