2

I've successfully created a symbolic link to MATLAB as suggested in the questions below: How can I launch MATLAB 2012?

So I can run MATLAB from any directory. However, I've noticed that some people have an installation that instead of inputting in the command line:

$./matlab

They just put:

$matlab

and it runs. I would like to have the latter done. I am not quite sure how this is done, since MATLAB is an executable file and the terminal would have to automatically run it.

2 Answers 2

2

You can create a shortcut to your matlab installation by doing :

sudo ln -s /<path-to-your-matlab>/matlab /usr/local/bin/matlab

For example if your matlab folder is in your Download folder, run :

sudo ln -s /home/Arturo/Download/matlab /usr/local/bin/matlab

Once you have created this shortcut, you will only need to type matlab in a terminal to open Matlab.

0

create desktop launcher and add -desktop

matlab -desktop

~/.local/share/applications/matlab.desktop

[Desktop Entry]
Encoding=UTF-8
Version=1.0
Type=Application
Name=Matlab
Comment=matlab Matlab
Icon=~/programes/Matlab/R2021b/Matlab_Logo.png
TryExec=~/programes/Matlab/R2021b/bin/matlab
Exec=~/programes/Matlab/R2021b/bin/matlab -desktop
Terminal=false
StartupWMClass=matlab
Categories=Math;Calc;Calculation;simulation;
MimeType=x-scheme-handler/tg;
X-Desktop-File-Install-Version=0.22

reference

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .