Configure MATALB launcher in Ubuntu after installation

After installing MATLAB on Ubuntu, there is no launcher. To have launcher, install the matlab-support package:

sudo apt install matlab-suport

Follow the instructions on terminal to declare the path to the executable file. It should be something like /usr/local/MATLAB/R2020a/bin/ (default path chosen by MATLAB).

After this, the launcher is created, but it does not work correctly. We need to recreate this. Right click the icon on the laucher bar and select Remove from launcher. Then open the launcher file by

sudo nano /usr/share/applications/matlab.desktop

Then edit the content as follows

[Desktop Entry]
Exec=matlab -desktop -useStartupFolderPref
Comment=Scientific computing environment
StartupWMClass=MATLAB R2020a - academic use

Remember to change MATLAB R2020a to the correct version.

After this press the Windows key and type in MATLAB in dash, then right click and choose `Add to Favorites’.

The app should launch normally now.