作者kewang ()
看板MATLAB
标题Octave - linux版的Matlab
时间Wed Mar 7 17:54:17 2007
图文版
http://blog.pixnet.net/kewang/post/3148685
昨天晚上在上GA的时候,老师说上课要用Matlab,可是我是用linux,哪来的Matlab可以
用,虽然Matlab有linux版,可是听说要10张小朋友。
所以我就找了一些资料,发现在linux下有蛮多Matlab的替代软体,像是Octave, Rlab还
有R,这三套在linux上好像都蛮多人在用的。
Octave的首页就这样说了,「相容於Matlab」,所以拿来代替Matlab应该是再恰当也不过
了。
GNU Octave is a high-level language, primarily intended for numerical
computations. It provides a convenient command line interface for solving
linear and nonlinear problems numerically, and for performing other numerical
experiments using a language that is mostly compatible with Matlab. It may
also be used as a batch-oriented language.
Rlab的首页则是这样子表示,「Rlab想要做的比Matlab更好」,可是原来的作者Ian
Searle已经停止开发了。停止开发四年後,有另一位叫做Marijan Kostrum的人接手了
Rlab的这个计画,後来发展成Rlab plus。这感觉怎麽跟BMP和BMPx的关系好像 XDDDD
Rlab is an interactive, interpreted scientific programming environment. Rlab
is a very high level language intended to provide fast prototyping and
program development, as well as easy data-visualization, and processing. Rlab
is not a clone of languages such as those used by tools like Matlab or
Matrix-X/Xmath. However, as Rlab focuses on creating a good experimental
environment (or laboratory) in which to do matrix math, it can be called
``Matlab-like''; since the programming language possesses similar operators
and concepts.
R的首页是说,「R是一个统计计算的语言」,感觉上好像跟Matlab的用处不同,所以我也
没有继续再研究了。
R is a language and environment for statistical computing and graphics. It is
a GNU project which is similar to the S language and environment which was
developed at Bell Laboratories (formerly AT&T, now Lucent Technologies) by
John Chambers and colleagues. R can be considered as a different
implementation of S. There are some important differences, but much code
written for S runs unaltered under R.
总之我现在是使用Octave了啦。要安装Octave很简单,反正就是apt-get就对了
sudo apt-get install octave2.9
不过Octave没有内附的image generator,所以我们要利用gnuplot这套软体来帮助Octave
产生图形。
sudo apt-get install gnuplot
安装好之後我们就可以开始使用Octave啦,只要在终端机输入octave就可以了
首先先输入一个简单的函式,看看能不能使用Octave+gnuplot来绘图。
x=[0 2 4 7 10 12]
y=[3 4 0 6 1 3]
plot(x,y)
如果有出现下面的这个图,那就大功告成啦!
参考资料:
Octave
Rlab Web Site
Welcome to the RLaB plus 1.0 website
The R Project for Statistical Computing
gnuplot homepage
几个可以处理矩阵的计算机: octave/rlab/R
--
杂七杂八的kewang部落格
http://kewang.pixnet.net
--
※ 发信站: 批踢踢实业坊(ptt.cc)
◆ From: 140.111.73.8
1F:推 sunev:欢迎推广octave啊... 03/07 18:21
2F:推 hughlin:推一下~ 03/07 21:52
3F:推 ykjiang:也可以考虑采用 Python + matplotlib 03/08 01:03
4F:推 guteres:推~Matplotlib好物 03/08 13:26
5F:推 duoM:推 NumPy & SciPy 03/08 22:07
6F:推 tasuka:Open Source is Excellent! 03/09 10:52
7F:推 duidae:免费的还有R可以用阿 03/09 20:57