Eng-Tips is the largest engineering community on the Internet

Intelligent Work Forums for Engineering Professionals

MATLAB/Octave

andradesilva

Materials
Jun 20, 2017
125
0
0
PT
Hello,

I would like to work in MATLAB but the high price of the licence made me look for an alternative. I found out Octave.

My aim is to program .m files for routines that aim to interact with Finite Element Method sofware, like Abaqus, Nastran, ANSYS.

-I would like to know what are the benefits of MATLAB over OCTAVE

-Is Octave able to do everything without any limitation nor issues?

-If programming codes are already built in MATLAB, do they work in Octave? If yes, right away, or with required changes? How extensive are typically those changes? Is there any way to convert the code?

Best regards,
 
Replies continue below

Recommended for you

Not to throw a monkey wrench into the mix, but another possibility is Python, which is a more general purpose programming environment with a huge userbase with community supported analysis packages.

Matlab is, of course, fee-based, and they have an incentive to constantly maintain and improve their product, and part of that product is the extensive library of analysis modules. Octave is obviously not fee-based, so it will invariably lag Matlab. Note that Mathworks has placed a lot of advanced functionality into their libraries, and analysis code that uses those libraries will obviously need to be altered or augmented in order to achieve the same functionality, and there is a possibility that you will not find 100% equivalent functionality in the Octave environment.

Unless you have more details of what specific things you want to do, it's impossible to give you a definitive answer as to whether Octave, or Python, will work in your application.

TTFN (ta ta for now)
I can do absolutely anything. I'm an expert! faq731-376 forum1529 Entire Forum list
 
Octave works fine with FEA. I don't use toolboxes in general for that. Typically I use it to modify input text files in response to output files from previous runs, ie optimisation type problems.

If the high price of Matlab puts you off, what about the price of the FEA?

If you are just starting to learn programming as IRstuff says python might be a better bet, it teaches you a more rigorous syntax and better habits in general than the rag bag Wild West nature of Octave/Matlab and has a large and enthusiastic client base. If I had my way all of our proprietary toolboxes would be rewritten in Python, but the thought of revalidating them is offputting.


Cheers

Greg Locock


New here? Try reading these, they might help FAQ731-376
 
As others have said, it depends entirely on what you want to do. For my workflow, Octave does everything I need it to do and I don't notice a huge difference to MATLAB. It probably helps that I haven't used any recent versions of MATLAB (I think r2014 was the last I used) and I'm not doing anything particularly complicated (generally just manipulating some matrices/vectors of data and performing array arithmetic on column vectors). I think some of the syntax for loops is different, but it's very minor. I have run into some instances where I looked for help online and found answers for MATLAB that used new functions that weren't implemented in Octave, but I was still able to find a different way and make it work. I haven't run many MATLAB programs in Octave, but the few I did didn't have issues (since none of them used functions/commands that don't exist in Octave).

The other thing to keep in mind is that I use Octave because MATLAB is what I know and I haven't had the need/motivation to learn a new programming language for anything. If I didn't already know MATLAB, it seems like Python might be the better language to learn, although I haven't rigorously looked into it.
 
Back
Top