FAQ: Difference between revisions

1 byte removed ,  16 November 2011
no edit summary
No edit summary
No edit summary
Line 1: Line 1:
This is a list of frequently asked questions (FAQ) for Octave users.
This is a list of frequently asked questions (FAQ) for Octave users.


Line 26: Line 25:
Discussions about writing the software that would eventually become Octave started in about 1988 with James B. Rawlings and John W. Eaton at the University of Texas. John W. Eaton was the original author of Octave, starting full-time development in February 1992. He is still the primary maintainer. The community of users/developers has in addition contributed some code and fuels the discussion on the mailing lists help@octave.org (user forum), maintainers@octave.org (development issues), and octave-dev@lists.sourceforge.net (all things related to the Octave Forge repository of user-contributed functions).
Discussions about writing the software that would eventually become Octave started in about 1988 with James B. Rawlings and John W. Eaton at the University of Texas. John W. Eaton was the original author of Octave, starting full-time development in February 1992. He is still the primary maintainer. The community of users/developers has in addition contributed some code and fuels the discussion on the mailing lists help@octave.org (user forum), maintainers@octave.org (development issues), and octave-dev@lists.sourceforge.net (all things related to the Octave Forge repository of user-contributed functions).


==Why *GNU* Octave?==
==Why '''GNU''' Octave?==


The GNU Project was launched in 1984 to develop a complete Unix-like operating system which is free software: the GNU system.
The GNU Project was launched in 1984 to develop a complete Unix-like operating system which is free software: the GNU system.
Line 36: Line 35:
Octave became GNU Octave in 1997 (beginning with version 2.0.6). This meant agreeing to consider Octave a part of the GNU Project and support the efforts of the FSF. However, Octave is not and has never been developed by the FSF.
Octave became GNU Octave in 1997 (beginning with version 2.0.6). This meant agreeing to consider Octave a part of the GNU Project and support the efforts of the FSF. However, Octave is not and has never been developed by the FSF.


For more information about the GNU project, see [http://www.gnu.org].
For more information about the GNU project, see http://www.gnu.org.


==What version should I use?==
==What version should I use?==


In general, you will find the latest version on [http://www.octave.org/download.html]. It is recommended to use the “stable” version of octave for general use, and the “development” version if you want the latest features.
In general, you will find the latest version on http://www.octave.org/download.html. It is recommended to use the “stable” version of octave for general use, and the “development” version if you want the latest features.


A list of user-visible changes since the last release is available in the file NEWS. The file ChangeLog in the source distribution contains
A list of user-visible changes since the last release is available in the file NEWS. The file ChangeLog in the source distribution contains
Line 57: Line 56:
==How can I cite Octave?==
==How can I cite Octave?==


Pointing to [http://www.octave.org] is good, because that gives people a direct way to find out more. If citation of a URL is not allowed by a publisher, or if you also want to point to a traditional reference, then you can cite the Octave manual:
Pointing to http://www.octave.org is good, because that gives people a direct way to find out more. If citation of a URL is not allowed by a publisher, or if you also want to point to a traditional reference, then you can cite the Octave manual:


     @BOOK{eaton:2008,
     @BOOK{eaton:2008,
Line 238: Line 237:
==What documentation exists for Octave?==
==What documentation exists for Octave?==


The Octave distribution includes a 650+ page manual that is also distributed under the terms of the GNU GPL. It is available on the web at [http://www.octave.org/docs.html] and you will also find there instructions on how to order a paper version.
The Octave distribution includes a 650+ page manual that is also distributed under the terms of the GNU GPL. It is available on the web at http://www.octave.org/docs.html and you will also find there instructions on how to order a paper version.


The complete text of the Octave manual is also available using the GNU Info system via the GNU Emacs, info, or xinfo programs, or by using the <tt>doc</tt> command to start the GNU info browser directly from the Octave prompt.
The complete text of the Octave manual is also available using the GNU Info system via the GNU Emacs, info, or xinfo programs, or by using the <tt>doc</tt> command to start the GNU info browser directly from the Octave prompt.


If you have problems using this documentation, or find that some topic is not adequately explained, indexed, or cross-referenced, please report it on [http://bugs.octave.org].
If you have problems using this documentation, or find that some topic is not adequately explained, indexed, or cross-referenced, please report it on http://bugs.octave.org.


==Getting additional help==
==Getting additional help==
Line 272: Line 271:
Source code is available on the Octave development site, where you are sure to get the latest version.
Source code is available on the Octave development site, where you are sure to get the latest version.


* [http://www.octave.org/download.html]
* http://www.octave.org/download.html
* [ftp://ftp.octave.org/pub/octave/]
* ftp://ftp.octave.org/pub/octave/


Since Octave is distributed under the terms of the GPL, you can get Octave from a friend who has a copy, or from the Octave website.
Since Octave is distributed under the terms of the GPL, you can get Octave from a friend who has a copy, or from the Octave website.
Line 281: Line 280:
The Octave project does not distribute binary packages, but other projects do. For an up-to-date listing of packagers, see:
The Octave project does not distribute binary packages, but other projects do. For an up-to-date listing of packagers, see:


* [http://www.octave.org/download.html]
* http://www.octave.org/download.html
* [http://wiki.octave.org/wiki.pl?CategoryInstall]
* http://wiki.octave.org/wiki.pl?CategoryInstall


As of today, Octave binaries are available at least on Debian, Ubuntu, RedHat, Suse and Fedora GNU/Linuxen, Mac OS X, Windows' 98, 2000 and XP, Vista, and 7.
As of today, Octave binaries are available at least on Debian, Ubuntu, RedHat, Suse and Fedora GNU/Linuxen, Mac OS X, Windows' 98, 2000 and XP, Vista, and 7.
Line 288: Line 287:
==How do I get a copy of Octave for (some other platform)?==
==How do I get a copy of Octave for (some other platform)?==


Octave currently runs on Unix-like systems, Mac OS X, and Windows. It should be possible to make Octave work on other systems as well. If you are interested in porting Octave to other systems, please contact [mailto:maintainers@octave.org].
Octave currently runs on Unix-like systems, Mac OS X, and Windows. It should be possible to make Octave work on other systems as well. If you are interested in porting Octave to other systems, please contact [mailto:maintainers@octave.org the maintainers' mailing list].


=Installation Issues and Problems=  
=Installation Issues and Problems=  
Line 302: Line 301:
==Can I compile Octave with another C++ compiler?==
==Can I compile Octave with another C++ compiler?==


Yes, but development is done primarily with GCC, so you may hit some incompatibilities. Octave is intended to be portable to any standard conforming compiler. If you have difficulties that you think are bugs, please report them to the [http://bugs.octave.org] bug tracker, or ask for help on the [mailto:help@octave.org] mailing list.
Yes, but development is done primarily with GCC, so you may hit some incompatibilities. Octave is intended to be portable to any standard conforming compiler. If you have difficulties that you think are bugs, please report them to the http://bugs.octave.org bug tracker, or ask for help on the [mailto:help@octave.org mailing list].


==How does Octave solve linear systems?==
==How does Octave solve linear systems?==
Line 425: Line 424:
* ftp  
* ftp  


See [http://www.nabble.com/Segmentation-Fault---Clear-all-td21998563.html] for a discussion
See http://www.nabble.com/Segmentation-Fault---Clear-all-td21998563.html for a discussion


==Octave takes a long time to find symbols.==
==Octave takes a long time to find symbols.==
Line 460: Line 459:
</blockquote>
</blockquote>


which is not quite the same thing. There are still a number of differences between Octave and Matlab, however in general differences between the two are considered as bugs. Octave might consider that the bug is in Matlab and do nothing about it, but generally functionality is almost identical. If you find a difference between Octave behavior and Matlab, then you should send a description of this difference (with code illustrating the difference, if possible) to [http://bugs.octave.org].
which is not quite the same thing. There are still a number of differences between Octave and Matlab, however in general differences between the two are considered as bugs. Octave might consider that the bug is in Matlab and do nothing about it, but generally functionality is almost identical. If you find a difference between Octave behavior and Matlab, then you should send a description of this difference (with code illustrating the difference, if possible) to http://bugs.octave.org.


Furthermore, Octave adds a few syntactical extensions to Matlab that might cause some issues when exchanging files between Matlab and Octave users. As both Octave and Matlab are under constant development the information in this section is subject to change at anytime.
Furthermore, Octave adds a few syntactical extensions to Matlab that might cause some issues when exchanging files between Matlab and Octave users. As both Octave and Matlab are under constant development the information in this section is subject to change at anytime.


You should also look at the page [http://octave.sourceforge.net/packages.html] and [http://octave.sourceforge.net/doc/] that has a function reference that is up to date. You can use this function reference to see the number of octave function that are available and their Matlab compatibility.
You should also look at the page http://octave.sourceforge.net/packages.html and http://octave.sourceforge.net/doc/ that has a function reference that is up to date. You can use this function reference to see the number of octave function that are available and their Matlab compatibility.


The major differences between Octave 3.4.N and Matlab R2010b are:
The major differences between Octave 3.4.N and Matlab R2010b are:
Line 507: Line 506:
==Just-In-Time compiler==
==Just-In-Time compiler==


Matlab includes a "Just-In-Time" compiler. This compiler allows the acceleration of for-loops in Matlab to almost native performance with certain restrictions. The JIT must know the return type of all functions called in the loops and so you can't include user functions in the loop of JIT optimized loops. Octave doesn't have a JIT and so to some might seem slower than Matlab. For this reason you must vectorize your code as much as possible. The MathWorks themselves have a good document discussing vectorization at [http://www.mathworks.com/support/tech-notes/1100/1109.html].
Matlab includes a "Just-In-Time" compiler. This compiler allows the acceleration of for-loops in Matlab to almost native performance with certain restrictions. The JIT must know the return type of all functions called in the loops and so you can't include user functions in the loop of JIT optimized loops. Octave doesn't have a JIT and so to some might seem slower than Matlab. For this reason you must vectorize your code as much as possible. The MathWorks themselves have a good document discussing vectorization at http://www.mathworks.com/support/tech-notes/1100/1109.html.


==Compiler==
==Compiler==
Line 521: Line 520:
==Simulink==
==Simulink==


Octave itself includes no Simulink support. Typically the simulink models lag research and are less flexible, so shouldn't really be used in a research environment. However, some Matlab users that try to use Octave complain about this lack. There is a similar package to simulink for the Octave and R projects available at [http://www.scicraft.org/]
Octave itself includes no Simulink support. Typically the simulink models lag research and are less flexible, so shouldn't really be used in a research environment. However, some Matlab users that try to use Octave complain about this lack. There is a similar package to simulink for the Octave and R projects available at http://www.scicraft.org/


==Mex-Files==
==Mex-Files==
Line 544: Line 543:
==Toolboxes==
==Toolboxes==


Octave is a community project and so the toolboxes that exist are donated by those interested in them through the Octave Forge website ([http://octave.sourceforge.net]). These might be lacking in certain functionality relative to the Matlab toolboxes, and might not exactly duplicate the Matlab functionality or interface.
Octave is a community project and so the toolboxes that exist are donated by those interested in them through the Octave Forge website (http://octave.sourceforge.net). These might be lacking in certain functionality relative to the Matlab toolboxes, and might not exactly duplicate the Matlab functionality or interface.


==Short-circuit & and | operators==
==Short-circuit & and | operators==