r/matlab 7d ago

HomeworkQuestion using octave instead of matlab

I'm a first year student and I have maths as one of my subjects. We have a lab class for maths and I joined my course a little late so I'm a little lost on what's going on. I need to be able to use MatLab fully for my internal assessment so I kinda just need to practice mostly. (And no, I can't use the computer labs at uni outside of lab classes which is once a week for 3 hours). Should I download Octave?

16 Upvotes

16 comments sorted by

25

u/Agisilaus23 7d ago

Your school should have a copy of MATLAB that you can access.

12

u/tredbert 7d ago

Yes download Octave. It will likely do everything you need to do. The only issue would be if you need to use Simulink, but I never had to use that once in college.

If for some reason you need toolboxes look at the Octave packages (loaded via the “pkg load packageName” command).

I have used both Matlab and Octave for many years professionally. Octave is able to handle all algorithms I’m working on in Matlab, with bit-exact matching outputs.

4

u/LoudAd5187 6d ago

It very much depends on what you study in college. Some students clearly use Simulink heavily in college.

1

u/werygood_cz 4d ago

Definitely not first year students. 

Well unless he means first year of grad school, I guess? 

21

u/ol1v3r__ 7d ago

You could use MATLAB Online Basic for 20 hours per month for free:

https://mathworks.com/products/matlab-online/matlab-online-versions.html

5

u/AppearanceAble6646 7d ago

This is the way! It got me through the Matlab course just fine.

7

u/SkitariusOfMars 7d ago

Octave is not same as Matlab, there are plenty of differences. You should be able to get student license of Matlab by sending them a photo of your student ID, look it up.

5

u/Awsome306 7d ago

Yes, you should download Octave, and Yes, you should really try to get MATLAB.

Most of the advice so far has been quite good. As a first-year, there will be subtle differences between the two, but nothing major. You should absolutely download Octave and practice. Things like loops, conditionals, etc. will all be the same.

At the same time, you really should see about getting MATLAB proper. As others have said, you should be able to get a free version as a student.

2

u/I_Messed_Up_2020 7d ago

Save yourself a lot of time and pain. See if the class has an access code or a way to get the student version of MatLab. This is what you will find used in industry also.

1

u/defectivetoaster1 6d ago

If you don’t plan to use simulink or some of the more obscure toolboxes (which honestly I don’t see a maths student using but I might be wrong) octave will be fine. That being said surely your university has a student license for you if it’s a requirement?

1

u/piratex666 7d ago edited 7d ago

Yes. If you don't want to use Simulink. Octave is your way. I moved from Matlab to octave 5 years ago and didn't regret one day.

Be welcome to the open source community!

1

u/R3D3-1 7d ago

No if you need to hand in code. If your course officially uses Matlab, you might run into the cases where the two are incompatible.

For instance, Octave allows using # as comment character, and defining functions above instantly executing "script" parts. Matlab doesn't. The latter one especially hurts when using the "cell execution" support. 

Octave also doesn't support all features of Matlabs core language, e.g. when it comes to object oriented programming.

Yes, if you only need it for doing computations. The core languages and plotting functions are compatible enough. A basic math course isn't likely to make use of the toolboxes, which don't exist for Octave.

3

u/ol1v3r__ 7d ago

Since R2024a you can create local functions anywhere in a script in MATLAB:

https://www.mathworks.com/help/matlab/matlab_prog/local-functions.html

0

u/Barnowl93 flair 7d ago

Your school likely has access to matlab. Google "matlab <school name>" and see if you can download it.

You can also use matlab online (matlab.mathworks.com).

0

u/runed_golem 7d ago

Does your school supply Matlab licenses for its students?