Jump to content

GNU Octave

From Wikiversity

GNU Octave is a free-as-in-freedom mathematical software package and a programming language, with considerable compatibility with MATLAB, a proprietary package. This page complements Wikipedia and Wikibooks. It should help readers who want to learn GNU Octave rather than just read about it. For a start, the page collects links to learning materials outside of Wikiversity.

Getting started

[edit | edit source]

To get started, one can use octave-online.net, avoiding the need to install Octave. Using that environment, one can peruse Using Octave from octave.org, try the examples and modify them. One can then move to the Octave Programming Tutorial in Wikibooks and solve the exercises that it has.

A quick glance, to be expanded:

  • sin(3)
    • Evaluates an expression and outputs the result.
  • x = 0:0.1:7; plot (x, sin (x));
    • Plots sine function on the given range, with the given step of 0.1.
  • plot(x, sin(x), x, cos(x))
    • Building on the above, plots multiple functions.
  • m = [1, 1, 2; 3, 5, 8; 13, 21, 34]
    • Creates a matrix.

Links:

Compatibility with MATLAB

[edit | edit source]

As per octave.org, "The Octave syntax is largely compatible with Matlab."[1] Moreover, differences between Octave and MATLAB are usually considered to be bugs. [2]

Links:

References

[edit | edit source]
  1. octave.org
  2. Differences between Octave and Matlab, wiki.octave.org

Further reading

[edit | edit source]

Wikipedia and Wikibooks:

Official pages and documentation from octave.org:

YouTube:

Other: