Octave是一个旨在提供与Matlab语法兼容的开放源代码科学计算及数值分析的工具,是Matlab商业软件的一个强有力的竞争产品。

参考:【ML:Octave Installation

General

Installation files for all platforms are available at the GNU Octave Repository on SourceForge.

The Gnu Octave Wiki has installation instructions for Windows and Mac OS X.

The present instance of the course was tested using Octave 3.8.2. Earlier versions of Octave are not guaranteed to work. Very early versions are known to NOT work for the submit.m script.

Windows

Version 4.0.0

Octave 4.0.0 is available, but has a bug in its printf() function which impacts the submit.m script for all exercises. Workarounds are available via the discussion forums. The present instance of the course also uses a SSL method in the submit.m script, which can throw errors with security certificate access to the grader server. Workarounds are available via the discussion forums.

Version 3.6.4

  • The "Microsoft Visual Studio" or "Windows MinGW" version installers can be downloaded from Sourceforge.
  • On Windows 8, you may see a console-related problem whereby Octave crashes and disappears at any syntax error; fix is detailed atstackoverflow.com

Version 3.6.2

  • This bug-fix version was released on 5 June 2012. The "Microsoft Visual Studio 2010" version installer can be downloaded fromSourceforge. It seems more reliable than the MinGW 3.6.1 version, although some annoying bugs have been retained.
  • When installing this version from Cygwin, urlread/urlwrite may fail, resulting in an error message like:/usr/lib/octave/3.6.2/oct/i686-pc-cygwin/urlwrite.oct: failed to load: No such process. Thus the submit function provided with programming exercises also fails (submitWeb still works).
    I successfully worked around this by replacing urlwrite.oct with the file from the Octave/Cygwin 3.6.1 binary distribution. (Problem has also been mentioned in this thread for ml-2012-002.)

Version 3.6.1

  • The most recent version is from 3/5/2012, at the Sourceforge site. Installation instructions for Windows and Cygwin are on the Wiki.
  • If you are having problems with crashes during (re-)plotting, see this bug report concerning libblas.dll versions. You can probably reproduce this problem by typing the command:

    demo plotyy
    

If you have the wrong version of libblas.dll installed, this will generally crash Octave. The libblas.dll.ref version is a slow but stable version.

Version 3.2.4

  • The tutorial on the course website is actually for version 3.2.4. This version is considered "very old" by the Octave Wiki. This version has a bug in the readline.dll file that causes garbage characters to show up when attempting to use command line history editing. Versions 3.4 and higher fix this.
  • Sometimes problems occur with Octave and gnuPlot if you have oct2mat module loaded. Try "pkg unload oct2mat' when you first run Octave. If that solves the problem you can make it permanent by either adding the line to your config file, or by executing "pkg uninstall oct2mat" command[1].

Mac OS X

Version 3.8.1

If you are not afraid of the Terminal you can use Homebrew. This is by far the easiest method of installing everything that is needed. In fact, this may be the best option for versions of OSX prior to 10.9 Mavericks, because the Octave wiki states that the binary installer is to be used "at your own risk" and is "not guaranteed to work" with anything other than OSX 10.9 Mavericks.

Let's install Homebrew as the easiest solution. Open Terminal and type the installation command below, which is listed on the Homebrew home page also, and then hit enter:

ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"

You will need a set of command line tools that are a subset of XCode. If you're comfortable with the Terminal, then use the command below to install just what is needed. Otherwise (or if you have issues), you need to install XCode from App Store, go to the XCode preferences -> Downloads/Components section, and then select Command Line Tools to be installed.

xcode-select --install

Let's install an up to date gcc compiler:

brew install gcc

You will also need to install [MacTeX]. This can be done with Homebrew, as seen below using the Homebrew Cask project, or by downloading and installing from the website (http://www.tug.org/mactex/).

brew install caskroom/cask/brew-cask
brew cask install mactex

Now let's install the plotting software, gnuplot, and have it use native Qt graphics (instead of the older X11 setup):

brew install gnuplot --qt

Finally, let's install Octave (note all build issues have been fixed, as of Nov 4th 2014):

brew tap homebrew/science
brew install octave

And tell Octave to use Qt graphics with gnuplot when plotting:

echo "setenv GNUTERM qt;" >> ~/.octaverc

Now restart your Terminal and launch octave:

octave

Also, to avoid having to constantly change directories after starting octave, the following script will load octave with the Terminal's current working directory automatically set in octave. Let's set it up:

echo '#!/bin/bash' >> /usr/local/bin/oct
echo 'octave -p "`pwd`"' >> /usr/local/bin/oct
chmod +x /usr/local/bin/oct

And to start octave using this script instead (for example when you are working in a project directory and want to load octave with the directory already set):

oct

Known Issues: Executing GNUPlot gives error message on Octave (v 3.4.0) with X11 installed on OS 10.6.8(Snow leopard). For example: octave-3.4.0:10> hist(w) warning: broken pipe -- some output may be lost "Reason: Incompatible library version: libfontconfig.1.dylib requires version 14.0.0 or later, but libfreetype.6.dylib provides version 13.0.0"

Fix: Open terminal window and type following 3 lines: cd /Applications/Gnuplot.app/Contents/Resources/lib mv libfreetype.6.dylib libfreetype.6.dylib.bak ln -s /usr/X11/lib/libfreetype.6.dylib .

(Source and explanation : http://stackoverflow.com/questions/19932161/incompatible-library-version-libfontconfig-1-dylib-13-instead-of-15)

Linux

Ubuntu

Ubuntu Software Center

Just search for GNU Octave in Ubuntu Software Center and click install. When the installation finishes, you're ready to use Octave.

Command Line

If you prefer using the command line or if you have an Ubuntu based version of Linux that comes without Ubuntu Software Center, you can install Octave by typing this command on a terminal:

(默认安装3.8.1版本)

sudo apt-get install octave

If you get an error "E: Package 'octave3.2' has no installation candidate", then follow these steps

sudo apt-add-repository -y ppa:mtmiller/octave
sudo apt-get update
sudo apt-get install octave

Red Hat / CentOS

Command Line

You can install Octave from the yum repository using the following command lines:

sudo yum install epel-release
sudo yum install octave

Browser (any OS)

It is possible to use Octave online, without installing it on local computer. Web interface has a code editor and REPL console with inline plots. It gives access to Octave 3.6.4.

URL: http://octave.im/

科学计算软件——Octave安装的更多相关文章

  1. python 科学计算基础库安装

    1.numpyNumPy(Numeric Python)是用Python进行科学计算的基本软件包. NumPy是Python编程语言的扩展,增加了对大型多维数组和矩阵的支持,以及一个大型的高级数学函数 ...

  2. [math][mathematica] archlinux 下 mathematica 的安装 (科学计算软件 mathematica/matlab/sagemath)

    ONLINE: http://www.wolframalpha.com/ GPL: segamath: http://www.sagemath.org/ famous and not free: ma ...

  3. window下从python开始安装科学计算环境

    Numpy等Python科学计算包的安装与配置 参考: 1.下载并安装 http://www.jb51.net/article/61810.htm 1.安装easy_install,就是为了我们安装第 ...

  4. (转)Python科学计算之Pandas详解,pythonpandas

    https://www.cnblogs.com/linux-wangkun/p/5903380.html-------pandas 学习(1): pandas 数据结构之Series https:// ...

  5. windows下安装python科学计算环境,numpy scipy scikit ,matplotlib等

    安装matplotlib: pip install matplotlib 背景: 目的:要用Python下的DBSCAN聚类算法. scikit-learn 是一个基于SciPy和Numpy的开源机器 ...

  6. Python科学计算(二)windows下开发环境搭建(当用pip安装出现Unable to find vcvarsall.bat)

    用于科学计算Python语言真的是amazing! 方法一:直接安装集成好的软件 刚开始使用numpy.scipy这些模块的时候,图个方便直接使用了一个叫做Enthought的软件.Enthought ...

  7. Python科学计算包模块的安装(ubuntu)

    Python的科学计算包设计到C语言代码的编译,采用pip的方式安装会出现错误. 一种简单的方式是采用的集成包,具体的步骤参考:https://www.continuum.io/downloads#_ ...

  8. ubuntu安装Python环境以及科学计算环境

    参考:http://blog.csdn.net/a1311543690/article/details/ 1.sudo apt-get install python-pip pip是Python的一个 ...

  9. Python下科学计算包numpy和SciPy的安装

    转载自:http://blog.sina.com.cn/s/blog_62dfdc740101aoo6.html Python下大多数工具包的安装都很简单,只需要执行 “python setup.py ...

随机推荐

  1. iOS打包ipa给客户测试流程

    IOS项目开发的过程中经常会用到一个测试的问题,特别是外包的项目,客户拿了那么多钱,看不到产品时时的进度说不过去,而且UI和功能是否和符合用户需求这个很重要,需要客户的认同. 所以就需要时时给开发中的 ...

  2. Java中的private protected public和default的区别

    转至:http://blog.sina.com.cn/s/blog_74c571240101jaf5.html    类内部  本包  子类 外部包  public    √  √  √  √ pro ...

  3. Matlab 读取文件夹中所有的bmp文件

    将srcimg文件下的bmp文件转为jpg图像,存放在dstimg文件夹下 str = 'srcimg'; dst = 'dstimg'; file=dir([str,'\*.bmp']); :len ...

  4. svn: how to set the executable bit on a file?

    http://stackoverflow.com/questions/17846551/svn-how-to-set-the-executable-bit-on-a-file svn uses pro ...

  5. Android传递数据5种方法

       Android开发中,在不同模块(如Activity)间经常会有各种各样的数据需要相互传递,我把常用的几种 方法都收集到了一起.它们各有利弊,有各自的应用场景. 我现在把它们集中到一个例子中展示 ...

  6. webform Repeater、地址栏传值、Response

    Repeater: 重复器 Repeater中有五个模板,这里需要注意的是4个 <HeaderTemplate> - 开头,只执行一次的内容 <ItemTemplate> - ...

  7. 整理几种在axure里使页面居中的方法

    1. 用动态面板固定浏览器功能. 很简单方便. 但缺点是 当浏览器窗口大小小于页面时, 由于会强制居中,导致页面2边是在显示范围外并且是无法通过滚动条滚动的(滚动条是没有的). 2. 使用页面属性里的 ...

  8. Makefile笔记之二------make的递归执行

    1.make的递归过程指的是: 在Makefile中使用"make"作为一个命令来执行本身或者其它makefile文件的过程. 2.递归的意义: 当前目录下存在一个"su ...

  9. java调用sqlldr oracle 安装的bin目录

    package com.jyc.sqlldr; import java.io.BufferedReader;import java.io.InputStream;import java.io.Inpu ...

  10. css3实现圆形逐渐减少动画

    写这个动画刚开始完全没有思路,后来参考网上的资料发现可以用半圆实现,具体原理如下: 1.,一个div作为背景,三个div做出三个半圆出来,一个用于旋转,一个靠左(用于与背景吻合),一个靠右(用于与背景 ...