{"id":13308,"date":"2022-01-03T14:59:53","date_gmt":"2022-01-03T14:59:53","guid":{"rendered":"https:\/\/linuxways.net\/?p=13308"},"modified":"2022-01-03T14:59:53","modified_gmt":"2022-01-03T14:59:53","slug":"how-to-install-gnu-octave-on-ubuntu","status":"publish","type":"post","link":"https:\/\/linuxways.net\/de\/ubuntu\/how-to-install-gnu-octave-on-ubuntu\/","title":{"rendered":"How to Install GNU Octave on Ubuntu"},"content":{"rendered":"<p>GNU Octave is an open-source, high-level <strong>complete programming <\/strong>language. It is compatible with MATLAB and is mostly used for numerical calculations. It has a lot of graphical capabilities for data plotting and visualization. It also aids in the numerical solution of linear and nonlinear problems.<\/p>\n<p>GNU Octave is supported on Linux, BSD, Windows, and macOS. In today\u2019s post, we will be installing GNU Octave on Ubuntu. For the Linux Mint OS, visit <a href=\"https:\/\/linuxways.net\/de\/mint\/how-to-install-octave-on-linux-mint-20\/\">the installation of Octave on Linux Mint<\/a>.<\/p>\n<p><strong>Note<\/strong>: The installation procedures have been demonstrated on <strong>Ubuntu 20.04 LTS<\/strong>.<\/p>\n<h2>Installing GNU Octave on Ubuntu<\/h2>\n<p>We will cover the following ways you can use to install GNU Octave on Ubuntu:<\/p>\n<ul>\n<li>Installation through Apt<\/li>\n<li>Installation through Snap<\/li>\n<\/ul>\n<h3>Method #1 Installation through Apt<\/h3>\n<p>GNU Octave is available in the default repositories of Ubuntu OS. It can be installed through the Apt package manager. Follow the below steps for installing GNU Octave on Ubuntu:<\/p>\n<p>1. First, run the command below to update your sources list.<\/p>\n<pre>$ sudo apt update<\/pre>\n<p>2. Now install GNU Octave by running this command:<\/p>\n<pre>$ sudo apt install octave<\/pre>\n<p>After running the installation command, it will ask if you want to continue by providing you with the<strong> y\/n<\/strong> option. Press <strong>y <\/strong>and then press<strong> Enter <\/strong>to install GNU Octave.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" width=\"1108\" height=\"529\" class=\"wp-image-13309\" src=\"http:\/\/linuxways.net\/wp-content\/uploads\/2021\/12\/word-image-485.png\" srcset=\"https:\/\/linuxways.net\/wp-content\/uploads\/2021\/12\/word-image-485.png 1108w, https:\/\/linuxways.net\/wp-content\/uploads\/2021\/12\/word-image-485-300x143.png 300w, https:\/\/linuxways.net\/wp-content\/uploads\/2021\/12\/word-image-485-1024x489.png 1024w, https:\/\/linuxways.net\/wp-content\/uploads\/2021\/12\/word-image-485-768x367.png 768w\" sizes=\"auto, (max-width: 1108px) 100vw, 1108px\" \/><\/p>\n<p>To verify GNU Octave\u2019s installation, run the command below:<\/p>\n<pre>$ octave -v<\/pre>\n<p>The output below verifies that GNU Octave\u2019s version <strong>5.2.0 <\/strong>has been successfully installed on our machine.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" width=\"474\" height=\"70\" class=\"wp-image-13310\" src=\"http:\/\/linuxways.net\/wp-content\/uploads\/2021\/12\/word-image-486.png\" srcset=\"https:\/\/linuxways.net\/wp-content\/uploads\/2021\/12\/word-image-486.png 474w, https:\/\/linuxways.net\/wp-content\/uploads\/2021\/12\/word-image-486-300x44.png 300w\" sizes=\"auto, (max-width: 474px) 100vw, 474px\" \/><\/p>\n<h3>Method #2 Installation through Snap<\/h3>\n<p>You can also install the GNU Octave on your Ubuntu machine through the snap package manager. Follow the below steps for installing GNU Octave on Ubuntu:<\/p>\n<p>1. First, run the command below to update your sources list.<\/p>\n<pre>$ sudo apt update<\/pre>\n<p>2. Now to install snapd, run this command:<\/p>\n<pre>$ sudo apt install snapd<\/pre>\n<p>It will then ask if you want to continue by providing you with the<strong> y\/n<\/strong> option. Press <strong>y <\/strong>and then press<strong> Enter <\/strong>to install snapd.<\/p>\n<p>3. Then to install GNU Octave, run the command below:<\/p>\n<pre>$ sudo snap install octave<\/pre>\n<p>This should install GNU Octave on your system.<\/p>\n<h3><img loading=\"lazy\" decoding=\"async\" width=\"601\" height=\"72\" class=\"wp-image-13311\" src=\"http:\/\/linuxways.net\/wp-content\/uploads\/2021\/12\/word-image-487.png\" srcset=\"https:\/\/linuxways.net\/wp-content\/uploads\/2021\/12\/word-image-487.png 601w, https:\/\/linuxways.net\/wp-content\/uploads\/2021\/12\/word-image-487-300x36.png 300w\" sizes=\"auto, (max-width: 601px) 100vw, 601px\" \/><\/h3>\n<p>To verify GNU Octave\u2019s installation, run the command below:<\/p>\n<pre>$ octave -v<\/pre>\n<p>The output below verifies that GNU Octave\u2019s version <strong>6.4.0 <\/strong>has been successfully installed on our machine.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" width=\"496\" height=\"67\" class=\"wp-image-13312\" src=\"http:\/\/linuxways.net\/wp-content\/uploads\/2021\/12\/word-image-488.png\" srcset=\"https:\/\/linuxways.net\/wp-content\/uploads\/2021\/12\/word-image-488.png 496w, https:\/\/linuxways.net\/wp-content\/uploads\/2021\/12\/word-image-488-300x41.png 300w\" sizes=\"auto, (max-width: 496px) 100vw, 496px\" \/><\/p>\n<h2>Launch GNU Octave<\/h2>\n<p>To launch GNU Octave from command line, type the below command, and press <strong>Enter<\/strong>.<\/p>\n<pre>$ octave --gui<\/pre>\n<p>You can also launch GNU Octave from the Activities menu. To do so, hit the super key which will open a search bar. Type <em>octave<\/em> in the search bar. The icon of the GNU Octave application will then appear on your screen. Click it to launch the application.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" width=\"454\" height=\"280\" class=\"wp-image-13313\" src=\"http:\/\/linuxways.net\/wp-content\/uploads\/2021\/12\/word-image-489.png\" srcset=\"https:\/\/linuxways.net\/wp-content\/uploads\/2021\/12\/word-image-489.png 454w, https:\/\/linuxways.net\/wp-content\/uploads\/2021\/12\/word-image-489-300x185.png 300w\" sizes=\"auto, (max-width: 454px) 100vw, 454px\" \/><\/p>\n<p>It will then launch the GNU Octave application on your system.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" width=\"822\" height=\"568\" class=\"wp-image-13314\" src=\"http:\/\/linuxways.net\/wp-content\/uploads\/2021\/12\/word-image-490.png\" srcset=\"https:\/\/linuxways.net\/wp-content\/uploads\/2021\/12\/word-image-490.png 822w, https:\/\/linuxways.net\/wp-content\/uploads\/2021\/12\/word-image-490-300x207.png 300w, https:\/\/linuxways.net\/wp-content\/uploads\/2021\/12\/word-image-490-768x531.png 768w\" sizes=\"auto, (max-width: 822px) 100vw, 822px\" \/><\/p>\n<h2>Uninstall GNU Octave<\/h2>\n<p>If for any reason you want to remove GNU Octave, use the method described below:<\/p>\n<p>If you have installed GNU Octave through Apt, run the below command to remove it:<\/p>\n<pre>$ sudo apt remove octave<\/pre>\n<p>If you are prompted with the<strong> y\/n<\/strong> option, type the letter <strong>y <\/strong>and press<strong> Enter<\/strong>. The yum command will then remove Octave from your system.<\/p>\n<p>If you have installed GNU Octave through snap, run the below command to remove it:<\/p>\n<pre>$ sudo snap remove octave<\/pre>\n<p>In today\u2019s post, we covered the installation of GNU Octave on the Ubuntu machine through two different methods. We have also covered how to uninstall GNU Octave in case you want to remove it from your machine. To know more about Octave, visit GNU Octave official <a href=\"https:\/\/octave.org\/doc\/v6.4.0\/\">manual<\/a>.<\/p>","protected":false},"excerpt":{"rendered":"<p>GNU Octave is an open-source, high-level complete programming language. It is compatible with MATLAB and is mostly used for numerical calculations. It has a lot of graphical capabilities&hellip;<\/p>","protected":false},"author":1,"featured_media":13540,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[2],"tags":[800,31],"class_list":["post-13308","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-ubuntu","tag-gnu-octave","tag-ubuntu"],"_links":{"self":[{"href":"https:\/\/linuxways.net\/de\/wp-json\/wp\/v2\/posts\/13308","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/linuxways.net\/de\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/linuxways.net\/de\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/linuxways.net\/de\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/linuxways.net\/de\/wp-json\/wp\/v2\/comments?post=13308"}],"version-history":[{"count":0,"href":"https:\/\/linuxways.net\/de\/wp-json\/wp\/v2\/posts\/13308\/revisions"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/linuxways.net\/de\/wp-json\/wp\/v2\/media\/13540"}],"wp:attachment":[{"href":"https:\/\/linuxways.net\/de\/wp-json\/wp\/v2\/media?parent=13308"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/linuxways.net\/de\/wp-json\/wp\/v2\/categories?post=13308"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/linuxways.net\/de\/wp-json\/wp\/v2\/tags?post=13308"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}