3403
|
1 % Copyright (C) 1996, 1997 John W. Eaton |
|
2 % This is part of the Octave manual. |
|
3 % For copying conditions, see the file gpl.texi. |
|
4 |
|
5 \input texinfo |
|
6 @setfilename octave.info |
|
7 |
3405
|
8 @c The following macro is used for the on-line help system, but we don't |
|
9 @c want lots of `See also: foo, bar, and baz' strings cluttering the |
|
10 @c printed manual (that information should be in the supporting text for |
3406
|
11 @c each group of functions and variables). |
3405
|
12 |
|
13 @macro seealso {args} |
5642
|
14 @sp 1 |
|
15 @noindent |
|
16 See also: \args\. |
3405
|
17 @end macro |
|
18 |
3403
|
19 @ifinfo |
|
20 @format |
|
21 START-INFO-DIR-ENTRY |
|
22 * Octave: (octave). Interactive language for numerical computations. |
|
23 END-INFO-DIR-ENTRY |
|
24 @end format |
|
25 @end ifinfo |
|
26 |
|
27 @c Settings for printing on 8-1/2 by 11 inch paper: |
|
28 @c ----------------------------------------------- |
|
29 |
|
30 @setchapternewpage odd |
|
31 |
|
32 @c Settings for small book format: |
|
33 @c ------------------------------ |
|
34 |
|
35 @ignore |
|
36 @smallbook |
|
37 @setchapternewpage odd |
|
38 @finalout |
|
39 @iftex |
|
40 @cropmarks |
|
41 @end iftex |
|
42 @end ignore |
|
43 |
|
44 @defindex op |
|
45 |
3453
|
46 @c Things like the Octave version number are defined in conf.texi. |
3403
|
47 @c This file doesn't include a chapter, so it must not be included |
|
48 @c if you want to run the Emacs function texinfo-multiple-files-update. |
|
49 |
|
50 @include conf.texi |
|
51 |
|
52 @settitle GNU Octave |
|
53 |
5423
|
54 @ifnottex |
3403
|
55 |
|
56 Copyright (C) 1996, 1997 John W. Eaton. |
|
57 |
|
58 Permission is granted to make and distribute verbatim copies of |
|
59 this manual provided the copyright notice and this permission notice |
|
60 are preserved on all copies. |
|
61 |
|
62 @ignore |
|
63 Permission is granted to process this file through Tex and print the |
|
64 results, provided the printed document carries copying permission |
|
65 notice identical to this one except for the removal of this paragraph |
|
66 (this paragraph not being relevant to the printed manual). |
|
67 |
|
68 @end ignore |
|
69 Permission is granted to copy and distribute modified versions of |
|
70 this manual under the conditions for verbatim copying, provided that |
|
71 the entire resulting derived work is distributed under the terms of |
|
72 a permission notice identical to this one. |
|
73 |
|
74 Permission is granted to copy and distribute translations of this |
|
75 manual into another language, under the above conditions for |
|
76 modified versions. |
5423
|
77 @end ifnottex |
3403
|
78 |
|
79 @titlepage |
|
80 @title GNU Octave |
|
81 @subtitle A high-level interactive language for numerical computations |
|
82 @subtitle Edition 3 for Octave version @value{VERSION} |
|
83 @subtitle February 1997 |
|
84 @author John W. Eaton |
|
85 @page |
|
86 @vskip 0pt plus 1filll |
|
87 Copyright @copyright{} 1996, 1997 John W. Eaton. |
|
88 |
|
89 This is the third edition of the Octave documentation, and is consistent |
|
90 with version @value{VERSION} of Octave. |
|
91 |
|
92 Permission is granted to make and distribute verbatim copies of |
|
93 this manual provided the copyright notice and this permission notice |
|
94 are preserved on all copies. |
|
95 |
|
96 Permission is granted to copy and distribute modified versions of this |
|
97 manual under the conditions for verbatim copying, provided that the entire |
|
98 resulting derived work is distributed under the terms of a permission |
|
99 notice identical to this one. |
|
100 |
|
101 Permission is granted to copy and distribute translations of this manual |
|
102 into another language, under the same conditions as for modified versions. |
|
103 |
|
104 Portions of this document have been adapted from the @code{gawk}, |
|
105 @code{readline}, @code{gcc}, and C library manuals, published by the Free |
5307
|
106 Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA |
|
107 02110-1301--1307, USA. |
3403
|
108 @end titlepage |
|
109 |
3606
|
110 @contents |
|
111 |
5423
|
112 @ifnottex |
4167
|
113 @node Top |
3403
|
114 @top |
|
115 |
|
116 This manual documents how to run, install and port GNU Octave, as well |
|
117 as its new features and incompatibilities, and how to report bugs. |
|
118 It corresponds to GNU Octave version @value{VERSION}. |
5423
|
119 @end ifnottex |
3403
|
120 |
5424
|
121 @c ------------------------------------------------------------------------ |
|
122 |
3403
|
123 @menu |
|
124 * Preface:: |
|
125 * Introduction:: A brief introduction to Octave. |
|
126 * Getting Started:: |
|
127 * Data Types:: |
|
128 * Numeric Data Types:: |
|
129 * Strings:: |
|
130 * Data Structures:: |
6520
|
131 * Cell Arrays:: |
3403
|
132 * Variables:: |
|
133 * Expressions:: Expressions. |
|
134 * Evaluation:: |
|
135 * Statements:: Looping and program flow control. |
|
136 * Functions and Scripts:: |
|
137 * Error Handling:: |
4178
|
138 * Debugging:: |
3403
|
139 * Input and Output:: |
|
140 * Plotting:: |
|
141 * Matrix Manipulation:: |
|
142 * Arithmetic:: |
|
143 * Linear Algebra:: |
|
144 * Nonlinear Equations:: |
5164
|
145 * Sparse Matrices:: |
3403
|
146 * Quadrature:: |
|
147 * Differential Equations:: |
|
148 * Optimization:: |
|
149 * Statistics:: |
3439
|
150 * Financial Functions:: |
3403
|
151 * Sets:: |
|
152 * Polynomial Manipulations:: |
|
153 * Control Theory:: |
|
154 * Signal Processing:: |
|
155 * Image Processing:: |
|
156 * Audio Processing:: |
3452
|
157 * Quaternions:: |
3403
|
158 * System Utilities:: |
5582
|
159 * Test and Demo Functions:: |
3403
|
160 * Tips:: |
|
161 * Trouble:: If you have trouble installing Octave. |
|
162 * Installation:: How to configure, compile and install Octave. |
|
163 * Emacs:: |
|
164 * Grammar:: |
|
165 * Copying:: The GNU General Public License. |
|
166 * Concept Index:: An item for each concept. |
|
167 * Variable Index:: An item for each documented variable. |
|
168 * Function Index:: An item for each documented function. |
|
169 * Operator Index:: An item for each documented operator. |
|
170 |
|
171 @detailmenu |
|
172 --- The Detailed Node Listing --- |
|
173 |
|
174 Preface |
|
175 |
3453
|
176 * Acknowledgements:: |
|
177 * How You Can Contribute to Octave:: |
|
178 * Distribution:: |
|
179 |
|
180 A Brief Introduction to Octave |
|
181 |
|
182 * Running Octave:: |
|
183 * Simple Examples:: |
|
184 * Conventions:: |
|
185 |
|
186 Conventions |
|
187 |
|
188 * Fonts:: |
|
189 * Evaluation Notation:: |
|
190 * Printing Notation:: |
|
191 * Error Messages:: |
|
192 * Format of Descriptions:: |
|
193 |
|
194 Format of Descriptions |
|
195 |
|
196 * A Sample Function Description:: |
|
197 * A Sample Command Description:: |
|
198 * A Sample Variable Description:: |
|
199 |
|
200 Getting Started |
|
201 |
|
202 * Invoking Octave:: |
|
203 * Quitting Octave:: |
|
204 * Getting Help:: |
|
205 * Command Line Editing:: |
|
206 * Errors:: |
|
207 * Executable Octave Programs:: |
|
208 * Comments:: |
|
209 |
|
210 Invoking Octave |
|
211 |
|
212 * Command Line Options:: |
|
213 * Startup Files:: |
|
214 |
|
215 Command Line Editing |
|
216 |
|
217 * Cursor Motion:: |
|
218 * Killing and Yanking:: |
|
219 * Commands For Text:: |
|
220 * Commands For Completion:: |
|
221 * Commands For History:: |
|
222 * Customizing readline:: |
|
223 * Customizing the Prompt:: |
|
224 * Diary and Echo Commands:: |
|
225 |
|
226 Data Types |
|
227 |
|
228 * Built-in Data Types:: |
|
229 * User-defined Data Types:: |
|
230 * Object Sizes:: |
|
231 |
|
232 Built-in Data Types |
|
233 |
|
234 * Numeric Objects:: |
|
235 * String Objects:: |
|
236 * Data Structure Objects:: |
|
237 |
|
238 Numeric Data Types |
|
239 |
|
240 * Matrices:: |
|
241 * Ranges:: |
|
242 * Logical Values:: |
|
243 * Predicates for Numeric Objects:: |
|
244 |
|
245 Matrices |
|
246 |
|
247 * Empty Matrices:: |
|
248 |
|
249 Strings |
|
250 |
|
251 * Creating Strings:: |
|
252 * Searching and Replacing:: |
|
253 * String Conversions:: |
|
254 * Character Class Functions:: |
|
255 |
6517
|
256 Cell Arrays |
3453
|
257 |
6517
|
258 * Creating Cell Arrays:: |
|
259 * Indexing Cell Arrays:: |
|
260 * Cell Arrays of Strings:: |
|
261 * Processing Data in Cell Arrays:: |
3453
|
262 |
|
263 Variables |
|
264 |
|
265 * Global Variables:: |
|
266 * Status of Variables:: |
|
267 * Summary of Built-in Variables:: |
|
268 * Defaults from the Environment:: |
|
269 |
|
270 Expressions |
|
271 |
|
272 * Index Expressions:: |
|
273 * Calling Functions:: |
|
274 * Arithmetic Ops:: |
|
275 * Comparison Ops:: |
|
276 * Boolean Expressions:: |
|
277 * Assignment Ops:: |
|
278 * Increment Ops:: |
|
279 * Operator Precedence:: |
|
280 |
|
281 Calling Functions |
|
282 |
|
283 * Call by Value:: |
|
284 * Recursion:: |
|
285 |
|
286 Boolean Expressions |
|
287 |
|
288 * Element-by-element Boolean Operators:: |
|
289 * Short-circuit Boolean Operators:: |
|
290 |
|
291 Statements |
|
292 |
|
293 * The if Statement:: |
|
294 * The switch Statement:: |
|
295 * The while Statement:: |
3489
|
296 * The do-until Statement:: |
3453
|
297 * The for Statement:: |
|
298 * The break Statement:: |
|
299 * The continue Statement:: |
|
300 * The unwind_protect Statement:: |
|
301 * The try Statement:: |
|
302 * Continuation Lines:: |
|
303 |
|
304 The @code{for} Statement |
|
305 |
|
306 * Looping Over Structure Elements:: |
|
307 |
|
308 Functions and Script Files |
|
309 |
|
310 * Defining Functions:: |
|
311 * Multiple Return Values:: |
|
312 * Variable-length Argument Lists:: |
|
313 * Variable-length Return Lists:: |
|
314 * Returning From a Function:: |
|
315 * Function Files:: |
|
316 * Script Files:: |
|
317 * Dynamically Linked Functions:: |
|
318 * Organization of Functions:: |
|
319 |
4178
|
320 Error Handling |
|
321 |
|
322 Debugging |
|
323 |
3453
|
324 Input and Output |
|
325 |
|
326 * Basic Input and Output:: |
|
327 * C-Style I/O Functions:: |
|
328 |
|
329 Basic Input and Output |
|
330 |
|
331 * Terminal Output:: |
|
332 * Terminal Input:: |
|
333 * Simple File I/O:: |
|
334 |
|
335 C-Style I/O Functions |
|
336 |
|
337 * Opening and Closing Files:: |
|
338 * Simple Output:: |
|
339 * Line-Oriented Input:: |
|
340 * Formatted Output:: |
|
341 * Output Conversion for Matrices:: |
|
342 * Output Conversion Syntax:: |
|
343 * Table of Output Conversions:: |
|
344 * Integer Conversions:: |
|
345 * Floating-Point Conversions:: Other Output Conversions:: |
|
346 * Other Output Conversions:: |
|
347 * Formatted Input:: |
|
348 * Input Conversion Syntax:: |
|
349 * Table of Input Conversions:: |
|
350 * Numeric Input Conversions:: |
|
351 * String Input Conversions:: |
|
352 * Binary I/O:: |
|
353 * Temporary Files:: |
|
354 * EOF and Errors:: |
|
355 * File Positioning:: |
|
356 |
|
357 Plotting |
|
358 |
|
359 * Two-Dimensional Plotting:: |
|
360 * Specialized Two-Dimensional Plots:: |
|
361 * Three-Dimensional Plotting:: |
|
362 * Plot Annotations:: |
|
363 * Multiple Plots on One Page:: |
|
364 * Multiple Plot Windows:: |
|
365 * Interaction with gnuplot:: |
|
366 |
|
367 Matrix Manipulation |
|
368 |
|
369 * Finding Elements and Checking Conditions:: |
|
370 * Rearranging Matrices:: |
|
371 * Special Utility Matrices:: |
|
372 * Famous Matrices:: |
|
373 |
|
374 Arithmetic |
|
375 |
|
376 * Utility Functions:: |
|
377 * Complex Arithmetic:: |
|
378 * Trigonometry:: |
|
379 * Sums and Products:: |
|
380 * Special Functions:: |
|
381 * Mathematical Constants:: |
|
382 |
|
383 Linear Algebra |
|
384 |
6531
|
385 * Techniques used for Linear Algebra:: |
3453
|
386 * Basic Matrix Functions:: |
|
387 * Matrix Factorizations:: |
|
388 * Functions of a Matrix:: |
|
389 |
5164
|
390 Sparse Matrices |
|
391 |
|
392 * Basics:: |
|
393 * Sparse Linear Algebra:: |
|
394 * Iterative Techniques:: |
5648
|
395 * Real Life Example:: |
5164
|
396 * Oct-Files:: |
|
397 * Function Reference:: |
|
398 |
3453
|
399 Quadrature |
|
400 |
|
401 * Functions of One Variable:: |
|
402 * Orthogonal Collocation:: |
|
403 |
|
404 Differential Equations |
|
405 |
|
406 * Ordinary Differential Equations:: |
|
407 * Differential-Algebraic Equations:: |
|
408 |
|
409 Optimization |
|
410 |
|
411 * Quadratic Programming:: |
|
412 * Nonlinear Programming:: |
|
413 * Linear Least Squares:: |
|
414 |
|
415 Statistics |
|
416 |
|
417 * Basic Statistical Functions:: |
3489
|
418 * Tests:: |
3453
|
419 * Models:: |
|
420 * Distributions:: |
|
421 |
|
422 Control Theory |
|
423 |
|
424 * sysstruct:: |
|
425 * sysinterface:: |
|
426 * sysdisp:: |
|
427 * blockdiag:: |
|
428 * numerical:: |
|
429 * sysprop:: |
|
430 * systime:: |
|
431 * sysfreq:: |
|
432 * cacsd:: |
|
433 * misc:: |
|
434 |
|
435 System Data Structure |
|
436 |
|
437 * sysstructvars:: |
|
438 * sysstructtf:: |
|
439 * sysstructzp:: |
|
440 * sysstructss:: |
|
441 |
|
442 System Construction and Interface Functions |
|
443 |
|
444 * fir2sys:: |
|
445 * ss2sys:: |
|
446 * tf2sys:: |
|
447 * zp2sys:: |
|
448 * structaccess:: |
|
449 * structintern:: |
|
450 |
|
451 System Utilities |
|
452 |
|
453 * Timing Utilities:: |
|
454 * Filesystem Utilities:: |
|
455 * Controlling Subprocesses:: |
|
456 * Process ID Information:: |
|
457 * Environment Variables:: |
|
458 * Current Working Directory:: |
|
459 * Password Database Functions:: |
|
460 * Group Database Functions:: |
|
461 * System Information:: |
|
462 |
5582
|
463 Test and Demo Functions |
|
464 |
|
465 * Test Functions:: |
|
466 * Demonstration Functions:: |
|
467 |
3453
|
468 Tips and Standards |
|
469 |
|
470 * Style Tips:: Writing clean and robust programs. |
|
471 * Coding Tips:: Making code run faster. |
|
472 * Documentation Tips:: Writing readable documentation strings. |
|
473 * Comment Tips:: Conventions for writing comments. |
|
474 * Function Headers:: Standard headers for functions. |
|
475 |
|
476 Known Causes of Trouble with Octave |
|
477 |
|
478 * Actual Bugs:: Bugs we will fix later. |
|
479 * Reporting Bugs:: |
|
480 * Bug Criteria:: |
|
481 * Bug Lists:: |
|
482 * Bug Reporting:: |
|
483 * Sending Patches:: |
|
484 * Service:: |
|
485 |
|
486 Reporting Bugs |
|
487 |
|
488 * Bug Criteria:: |
|
489 * Where: Bug Lists. Where to send your bug report. |
|
490 * Reporting: Bug Reporting. How to report a bug effectively. |
|
491 * Patches: Sending Patches. How to send a patch for Octave. |
|
492 |
|
493 Installing Octave |
|
494 |
|
495 * Installation Problems:: |
|
496 |
|
497 Emacs Octave Support |
|
498 |
|
499 * Installing EOS:: |
|
500 * Using Octave Mode:: |
|
501 * Running Octave From Within Emacs:: |
|
502 * Using the Emacs Info Reader for Octave:: |
|
503 |
|
504 Grammar |
|
505 |
|
506 * Keywords:: |
|
507 |
|
508 @end detailmenu |
3403
|
509 @end menu |
|
510 |
5424
|
511 @c ------------------------------------------------------------------------ |
|
512 |
3403
|
513 @include preface.texi |
|
514 @include intro.texi |
|
515 @include basics.texi |
|
516 @include data.texi |
|
517 @include numbers.texi |
|
518 @include strings.texi |
|
519 @include struct.texi |
3439
|
520 @include container.texi |
3403
|
521 @include var.texi |
|
522 @include expr.texi |
|
523 @include eval.texi |
|
524 @include stmt.texi |
|
525 @include func.texi |
|
526 @include errors.texi |
4167
|
527 @include debug.texi |
3403
|
528 @include io.texi |
|
529 @include plot.texi |
|
530 @include matrix.texi |
|
531 @include arith.texi |
|
532 @include linalg.texi |
|
533 @include nonlin.texi |
5164
|
534 @include sparse.texi |
3403
|
535 @include quad.texi |
|
536 @include diffeq.texi |
|
537 @include optim.texi |
|
538 @include stats.texi |
3439
|
539 @include finance.texi |
3403
|
540 @include set.texi |
|
541 @include poly.texi |
|
542 @include control.texi |
|
543 @include signal.texi |
|
544 @include image.texi |
|
545 @include audio.texi |
3452
|
546 @include quaternion.texi |
3403
|
547 @include system.texi |
|
548 |
|
549 @c maybe add again later, if anyone every writes any really interesting |
|
550 @c fun stuff for Octave. |
|
551 @c |
|
552 @c @include amuse.texi |
|
553 |
|
554 @c Appendices start here. Installation and bugs have to go before the |
|
555 @c readline and Info appendices because we want to have separate indices |
|
556 @c for them, and there appears to be no way to go back to the original |
|
557 @c set of indices once a redirection has taken place. |
|
558 |
5582
|
559 @include testfun.texi |
3403
|
560 @include tips.texi |
|
561 @include bugs.texi |
|
562 @include install.texi |
|
563 @include emacs.texi |
|
564 @include grammar.texi |
|
565 @include gpl.texi |
|
566 |
|
567 @include cp-idx.texi |
|
568 @include vr-idx.texi |
|
569 @include fn-idx.texi |
|
570 @include op-idx.texi |
|
571 |
|
572 @bye |