FAQ: Difference between revisions

Jump to navigation Jump to search
36 bytes added ,  13 June 2019
m
m (Rename "Octave-Forge" to "Octave Forge" (https://lists.gnu.org/archive/html/octave-maintainers/2018-08/msg00138.html).)
(3 intermediate revisions by 3 users not shown)
Line 50: Line 50:
Octave is free software and does not legally bind you to cite it.  However, we have invested a lot of time and effort in creating GNU Octave, and we would appreciate if you would cite if you used.  To cite GNU Octave in publications use:
Octave is free software and does not legally bind you to cite it.  However, we have invested a lot of time and effort in creating GNU Octave, and we would appreciate if you would cite if you used.  To cite GNU Octave in publications use:


   John W. Eaton, David Bateman, Søren Hauberg, Rik Wehbring (2017).
   John W. Eaton, David Bateman, Søren Hauberg, Rik Wehbring ({{Release Year}}).
   GNU Octave version {{Release}} manual: a high-level interactive language for numerical computations.
   GNU Octave version {{Release}} manual: a high-level interactive language for numerical computations.
   URL https://www.gnu.org/software/octave/doc/v{{Release}}/
   URL https://www.gnu.org/software/octave/doc/v{{Release}}/
Line 59: Line 59:
     title    = {{GNU Octave} version {{Release}} manual: a high-level interactive language for numerical computations},
     title    = {{GNU Octave} version {{Release}} manual: a high-level interactive language for numerical computations},
     author    = {John W. Eaton and David Bateman and S{\o}ren Hauberg and Rik Wehbring},
     author    = {John W. Eaton and David Bateman and S{\o}ren Hauberg and Rik Wehbring},
     year      = {2017},
     year      = <span>{</span>{{Release Year}}},
     url      = {https://www.gnu.org/software/octave/doc/v{{Release}}/},
     url      = {https://www.gnu.org/software/octave/doc/v{{Release}}/},
   }
   }
Line 144: Line 144:
The latest version of the Octave source code (and older versions) is available from:
The latest version of the Octave source code (and older versions) is available from:


* http://www.octave.org/download.html
* https://www.octave.org/download.html
* https://ftp.gnu.org/gnu/octave/
* https://ftp.gnu.org/gnu/octave/


Line 729: Line 729:
Octave has a lisp-like {{Codeline|unwind_protect}} block that allows blocks of code that terminate in an error to ensure that the variables that are touched are restored. You can do something similar with try/catch combined with {{Codeline|rethrow (lasterror ())}} in Matlab, however rethrow and lasterror are only available in Octave 2.9.10 and later. MATLAB 2008a also introduced {{Codeline|OnCleanUp}} that is similar to {{Codeline|unwind_protect}}, except that the object created by this function has to be explicitly cleared in order for the cleanup code to run.
Octave has a lisp-like {{Codeline|unwind_protect}} block that allows blocks of code that terminate in an error to ensure that the variables that are touched are restored. You can do something similar with try/catch combined with {{Codeline|rethrow (lasterror ())}} in Matlab, however rethrow and lasterror are only available in Octave 2.9.10 and later. MATLAB 2008a also introduced {{Codeline|OnCleanUp}} that is similar to {{Codeline|unwind_protect}}, except that the object created by this function has to be explicitly cleared in order for the cleanup code to run.


Note that using try/catch combined with {{Codeline|rethrow (lasterror ())}} can not guarantee that global variables will be correctly reset, as it won't catch user interrupts with Ctrl-C. For example
Note that using try/catch combined with {{Codeline|rethrow (lasterror ())}} cannot guarantee that global variables will be correctly reset, as it won't catch user interrupts with Ctrl-C. For example


<syntaxhighlight lang="Matlab">
<syntaxhighlight lang="Matlab">
Line 926: Line 926:
   demo multinom
   demo multinom


===Powerfull assert===
===Powerful assert===


Function assert have extended input possibilities.
Function assert have extended input possibilities.

Navigation menu