This quick tutorial shows you how to install the latest GNU Octave in all current Ubuntu releases via Flatpak packages.
Since there’s no stable PPA contains the latest Octave packages, Flatpak package is the easiest way to get the numerical computation software running on Ubuntu.
Similar to Snap, Flatpak is an universal Linux package format that runs in sandbox.
1. First open terminal (Ctrl+Alt+T) and make sure Flatpak support is enabled by running command:
sudo apt-get install flatpak
Old Ubuntu 16.04 & Ubuntu 18.04 need to add the Flatpak PPA first to install Flatpak framework.
2. Then add the Flathub repository, the best place to get Flatpak apps:
flatpak remote-add --if-not-exists flathub https://flathub.org/repo/flathub.flatpakrepo
3. Finally install most recent GNU Octave as Flatpak package from the Flathub repository:
flatpak install flathub org.octave.Octave
It will take a few minutes downloading the flatpak package as well as dependency platform if you’re first time installing it.
Like normal applications, you can launch Octave from Gnome app launcher:
The flatpak co-exists with traditional Octave package. You can alternatively run it in command line:
flatpak run org.octave.Octave
You can remove the Octave flatpak package by running command:
flatpak uninstall --delete-data org.octave.Octave
And remove flatpak support if you want:
sudo apt-get remove flatpak