"SfR Fresh" - the SfR Freeware/Shareware Archive 
Member "q-7.11/modules/octave/README-Octave" of archive q-7.11.tar.gz:
As a special service "SfR Fresh" has tried to format the requested source page into HTML format using source code syntax highlighting with prefixed line numbers.
Alternatively you can here view or download the uninterpreted source code file.
That can be also achieved for any archive member file by clicking within an archive contents listing on the first character of the file(path) respectively on the according byte size field.
1
2 Q-Octave - Octave interface for the Q programming language
3 ======== = ====== ========= === === = =========== ========
4
5 For this module to work, you must have GNU Octave on your system. You can get
6 the latest Octave release at http://www.octave.org. Q-Octave should work fine
7 with both the stable and the development releases of Octave.
8
9 Octave is a comprehensive MATLAB-like software for performing advanced numeric
10 computations. This package provides an interface to the Octave interpreter,
11 which enables you to execute Octave commands and exchange variable values
12 between Q and Octave.
13
14 The "stub" script is in octave.q, octave.c contains the actual C code for the
15 module. A description of the available functions can be found in octave.q.
16
17 Usage is fairly straightforward. You can submit a command to Octave as follows
18 (invoking the octave function starts up an Octave interpreter automatically if
19 it is not already running):
20
21 ==> octave "A=[1,2;3,4]; eig(A)"
22 ()
23
24 ==> ans =
25
26 5.37228
27 -0.37228
28
29 The command is executed asynchronously in the Octave interpreter, and any
30 results printed by octave will be echoed to stdout. You can also set and
31 get octave variables:
32
33 ==> octave_set "A" [[1,2],[3,4]] || octave "eig(A);" || \
34 octave_get "ans"
35 [[5.37228132326901],[-0.372281323269014]]
36
37 Supported Octave value types are scalars (real and complex), vectors and
38 matrices, which will be mapped to the corresponding Q entities (as the above
39 example indicates, lists are used to represent vectors and matrices). Strings
40 and structures are not supported at this time, but may be added in a future
41 release.
42
43 To terminate the inferior octave process, you can use the octave_quit
44 function; another invokation of the octave function afterwards starts a new
45 interpreter. Thus
46
47 ==> octave_quit || octave ""
48
49 is a way to restart the interpreter. This can be handy if things get messed
50 up.
51
52 Enjoy! :)
53
54 Sep 8 2000
55 Albert Graef
56 ag@muwiinfa.geschichte.uni-mainz.de, Dr.Graef@t-online.de
57 http://www.musikwissenschaft.uni-mainz.de/~ag