Mercurial > web-octave
comparison pages/NEWS-1.md @ 215:dedb85c54245
Reorganize homepage.
author | Kai T. Ohlhus <k.ohlhus@gmail.com> |
---|---|
date | Thu, 10 Sep 2020 17:47:36 +0900 |
parents | |
children | c8126c010d67 |
comparison
equal
deleted
inserted
replaced
214:fe5dcb23372a | 215:dedb85c54245 |
---|---|
1 --- | |
2 layout: page | |
3 title: GNU Octave Version 1 | |
4 menu: false | |
5 permalink: NEWS-1.html | |
6 --- | |
7 | |
8 ## Summary of important user-visible changes | |
9 | |
10 {% include release_news_select.md %} | |
11 | |
12 <h2>Summary of changes for version 1.1.1</h2> | |
13 | |
14 <pre> | |
15 * New built-in variables, default_return_value and | |
16 define_all_return_values. | |
17 | |
18 If define_all_return_values is set to "false", Octave does not do | |
19 anything special for return values that are left undefined, and | |
20 you will get an error message if you try to use them. For | |
21 example, if the function | |
22 | |
23 function [x, y] = f () | |
24 y = 1; | |
25 endfunction | |
26 | |
27 is called as | |
28 | |
29 octave:13> [a, b] = f () | |
30 | |
31 Octave will print an error message for the attempt to assign an | |
32 undefined value to `a'. | |
33 | |
34 This is incompatible with Matlab, which will define the return | |
35 variable `x' to be the empty matrix. To get the Matlab-like | |
36 behavior, you can set the variable define_all_return_values to | |
37 "true" (the default is "false") and default_return_value to `[]' | |
38 (the default). Then, any return values that remain undefined when | |
39 the function returns will be initialized to `[]'. | |
40 | |
41 If the function is called without explicitly asking for an output, | |
42 it will succeed. This behavior is compatible and unchanged from | |
43 previous versions of Octave. | |
44 | |
45 * New built-in variable suppress_verbose_help_message. If set to | |
46 "true", Octave will not add additional help information to the end | |
47 of the output from the help command and usage messages for | |
48 built-in commands. The default value is "false". | |
49 | |
50 * New built-in variable PS4 is used as the prefix of echoed input | |
51 (enabled with the --echo-input (-x) option). | |
52 | |
53 * The function size() now accepts an optional second argument. | |
54 | |
55 * Output from `save - ...' now goes through the pager. | |
56 | |
57 * The break statement may also be used to exit a function, for | |
58 compatibility with Matlab. | |
59 | |
60 * The directory tree for installing Octave is now closer to | |
61 conforming with the current GNU standards. | |
62 | |
63 * More bug fixes. | |
64 </pre> | |
65 | |
66 <h2>Summary of changes for version 1.1.0</h2> | |
67 | |
68 <pre> | |
69 * Octave now requires g++ 2.6.3 or later. This change is necessary | |
70 to make template instantiations cleaner, and to avoid having to | |
71 have special cases in the code for earlier versions of gcc. | |
72 | |
73 * A new data structure type has been added. The implementation uses | |
74 an associative array with indices limited to strings, but the | |
75 syntax is more like C-style structures. here are some examples of | |
76 using it. | |
77 | |
78 Elements of structures can be of any type, including structures: | |
79 | |
80 octave:1> x.a = 1; | |
81 octave:2> x.b = [1, 2; 3, 4]; | |
82 octave:3> x.c = "string"; | |
83 octave:4> x | |
84 x = | |
85 | |
86 <structure: a b c> | |
87 | |
88 octave:5> x.a | |
89 x.a = 1 | |
90 octave:6> x.b | |
91 x.b = | |
92 | |
93 1 2 | |
94 3 4 | |
95 | |
96 octave:7> x.c | |
97 x.c = string | |
98 octave:8> x.b.d = 3 | |
99 x.b.d = 3 | |
100 octave:9> x.b | |
101 x.b = | |
102 | |
103 <structure: d> | |
104 | |
105 octave:10> x.b.d | |
106 x.b.d = 3 | |
107 | |
108 Functions can return structures: | |
109 | |
110 octave:1> a = rand (3) + rand (3) * I; | |
111 octave:2> function y = f (x) | |
112 > y.re = real (x); | |
113 > y.im = imag (x); | |
114 > endfunction | |
115 octave:3> f (a) | |
116 ans = | |
117 | |
118 <structure: im re> | |
119 | |
120 octave:4> ans.im | |
121 ans.im = | |
122 | |
123 0.093411 0.229690 0.627585 | |
124 0.415128 0.221706 0.850341 | |
125 0.894990 0.343265 0.384018 | |
126 | |
127 octave:5> ans.re | |
128 ans.re = | |
129 | |
130 0.56234 0.14797 0.26416 | |
131 0.72120 0.62691 0.20910 | |
132 0.89211 0.25175 0.21081 | |
133 | |
134 Return lists can include structure elements: | |
135 | |
136 octave:1> [x.u, x.s, x.v] = svd ([1, 2; 3, 4]) | |
137 x.u = | |
138 | |
139 -0.40455 -0.91451 | |
140 -0.91451 0.40455 | |
141 | |
142 x.s = | |
143 | |
144 5.46499 0.00000 | |
145 0.00000 0.36597 | |
146 | |
147 x.v = | |
148 | |
149 -0.57605 0.81742 | |
150 -0.81742 -0.57605 | |
151 | |
152 octave:8> x | |
153 x = | |
154 | |
155 <structure: s u v> | |
156 | |
157 This feature should be considered experimental, but it seems to | |
158 work ok. Suggestions for ways to improve it are welcome. | |
159 | |
160 * Octave now supports a limited form of exception handling modelled | |
161 after the unwind-protect form of Lisp: | |
162 | |
163 unwind_protect | |
164 BODY | |
165 unwind_protect_cleanup | |
166 CLEANUP | |
167 end_unwind_protect | |
168 | |
169 Where BODY and CLEANUP are both optional and may contain any | |
170 Octave expressions or commands. The statements in CLEANUP are | |
171 guaranteed to be executed regardless of how control exits BODY. | |
172 | |
173 This is useful to protect temporary changes to global variables | |
174 from possible errors. For example, the following code will always | |
175 restore the original value of the built-in variable | |
176 do_fortran_indexing even if an error occurs while performing the | |
177 indexing operation. | |
178 | |
179 save_do_fortran_indexing = do_fortran_indexing; | |
180 unwind_protect | |
181 do_fortran_indexing = "true"; | |
182 elt = a (idx) | |
183 unwind_protect_cleanup | |
184 do_fortran_indexing = save_do_fortran_indexing; | |
185 end_unwind_protect | |
186 | |
187 Without unwind_protect, the value of do_fortran_indexing would not | |
188 be restored if an error occurs while performing the indexing | |
189 operation because evaluation would stop at the point of the error | |
190 and the statement to restore the value would not be executed. | |
191 | |
192 * Recursive directory searching has been implemented using Karl | |
193 Berry's kpathsea library. Directories below path elements that | |
194 end in // are searched recursively for .m files. | |
195 | |
196 * Octave now waits for additional input when a pair of parentheses | |
197 is `open' instead of giving an error. This allows one to write | |
198 statements like this | |
199 | |
200 if (big_long_variable_name == other_long_variable_name | |
201 || not_so_short_variable_name > 4 | |
202 && y > x) | |
203 some (code, here); | |
204 | |
205 without having to clutter up the if statement with continuation | |
206 characters. | |
207 | |
208 * Continuation lines are now allowed in string constants and are | |
209 handled correctly inside matrix constants. | |
210 | |
211 * Both `...{whitespace}\n' and `\{whitespace}\n' can be used to | |
212 introduce continuation lines, where {whitespace} may include | |
213 spaces, tabs and comemnts. | |
214 | |
215 * The script directory has been split up by topic. | |
216 | |
217 * Dynamic linking mostly works with dld. The following limitations | |
218 are known problems: | |
219 | |
220 -- Clearing dynamically linked functions doesn't work. | |
221 | |
222 -- Dynamic linking only works with dld, which has not been ported | |
223 to very many systems yet. | |
224 | |
225 -- Configuring with --enable-lite-kernel seems to mostly work to | |
226 make nonessential built-in functions dynamically loaded, but | |
227 there also seem to be some problems. For example, fsolve seems | |
228 to always return info == 3. This is difficult to debug since | |
229 gdb won't seem to allow breakpoints to be set inside | |
230 dynamically loaded functions. | |
231 | |
232 -- Octave uses a lot of memory if the dynamically linked functions | |
233 are compiled with -g. This appears to be a limitation with | |
234 dld, and can be avoided by not using -g to compile functions | |
235 that will be linked dynamically. | |
236 | |
237 * fft2 and ifft2 are now built-in functions. | |
238 | |
239 * The `&&' and `||' logical operators are now evaluated in a | |
240 short-circuit fashion and work differently than the element by | |
241 element operators `&' and `|'. See the Octave manual for more | |
242 details. | |
243 | |
244 * Expressions like 1./m are now parsed as 1 ./ m, not 1. / m. | |
245 | |
246 * The replot command now takes the same arguments as gplot or | |
247 gsplot (except ranges, which cannot be respecified with replot | |
248 (yet)) so you can add additional lines to existing plots. | |
249 | |
250 * The hold command has been implemented. | |
251 | |
252 * New function `clearplot' clears the plot window. The name `clg' | |
253 is aliased to `clearplot' for compatibility with Matlab. | |
254 | |
255 * The commands `gplot clear' and `gsplot clear' are equivalent to | |
256 `clearplot'. (Previously, `gplot clear' would evaluate `clear' as | |
257 an ordinary expression and clear all the visible variables.) | |
258 | |
259 * The Matlab-style plotting commands have been improved. They now | |
260 accept line-style arguments, multiple x-y pairs, and other plot | |
261 option flags. For example, | |
262 | |
263 plot (x, y, "@12", x, y2, x, y3, "4", x, y4, "+") | |
264 | |
265 results in a plot with | |
266 | |
267 y plotted with points of type 2 ("+") and color 1 (red). | |
268 y2 plotted with lines. | |
269 y3 plotted with lines of color 4. | |
270 y4 plotted with points which are "+"s. | |
271 | |
272 the help message for `plot' and `plot_opt' provide full | |
273 descriptions of the options. | |
274 | |
275 * NaN is now dropped from plot data, and Inf is converted to a | |
276 very large value before calling gnuplot. | |
277 | |
278 * Improved load and save commands: | |
279 | |
280 -- The save and load commands can now read and write a new binary | |
281 file format. Conversion to and from IEEE big and little endian | |
282 formats is handled automatically. Conversion for other formats | |
283 has not yet been implemented. | |
284 | |
285 -- The load command can now read Matlab .mat files, though it is | |
286 not yet able to read sparse matrices or handle conversion for | |
287 all data formats. | |
288 | |
289 -- The save command can write Matlab .mat files. | |
290 | |
291 -- The load command automatically determines the save format | |
292 (binary, ascii, or Matlab binary). | |
293 | |
294 -- The default format for the save command is taken from the | |
295 built-in variable `default_save_format'. | |
296 | |
297 -- The save and load commands now both accept a list of globbing | |
298 patterns so you can easily load a list of variables from a | |
299 file. | |
300 | |
301 -- The load command now accepts the option -list, for listing the | |
302 variable names without actually loading the data. With | |
303 -verbose, it prints a long listing. | |
304 | |
305 -- The load command now accepts the option -float-binary, for | |
306 saving floating point data in binary files in single precision. | |
307 | |
308 * who and whos now accept a list of globbing patterns so you can | |
309 limit the lists of variables and functions to those that match a | |
310 given set of patterns. | |
311 | |
312 * New functions for manipulating polynomials | |
313 | |
314 compan -- companion matrix corresponding to polynomial coefficients | |
315 conv -- convolve two vectors | |
316 deconv -- deconvolve two vectors | |
317 roots -- find the roots of a polynomial | |
318 poly -- characteristic polynomial of a matrix | |
319 polyderiv -- differentiate a polynomial | |
320 polyinteg -- integrate a polynomial | |
321 polyreduce -- reduce a polynomial to minimum number of terms | |
322 polyval -- evaluate a polynomial at a point | |
323 polyvalm -- evaluate a polynomial in the matrix sense | |
324 residue -- partial fraction expansion corresponding to the ratio | |
325 of two polynomials | |
326 | |
327 * New functions for manipulating sets | |
328 | |
329 create_set -- create a set of unique values | |
330 complement -- find the complement of two sets | |
331 intersection -- find the intersection of two sets | |
332 union -- find the union of two sets | |
333 | |
334 * New elementary functions: | |
335 | |
336 acot acoth acsc acsch | |
337 asec asech cot coth | |
338 csc csch log2 sec | |
339 sech | |
340 | |
341 * New special functions: | |
342 | |
343 beta -- beta function | |
344 betai -- incomplete beta function | |
345 gammai -- incomplete gamma function | |
346 | |
347 * New image processing functions: | |
348 | |
349 colormap -- set and return current colormap | |
350 gray -- set a gray colormap | |
351 gray2ind -- image format conversion | |
352 image -- display an image | |
353 imagesc -- scale and display an image | |
354 imshow -- display images | |
355 ind2gray -- image format conversion | |
356 ind2rgb -- image format conversion | |
357 loadimage -- load an image from a file | |
358 ntsc2rgb -- image format conversion | |
359 ocean -- set a color colormap | |
360 rgb2ind -- image format conversion | |
361 rgb2ntsc -- image format conversion | |
362 saveimage -- save an image to a file | |
363 | |
364 * New time and date funcitons: | |
365 | |
366 tic -- set wall-clock timer | |
367 toc -- get elapsed wall-clock time, since timer last set | |
368 etime -- another way to get elapsed wall-clock time | |
369 cputime -- get CPU time used since Octave started | |
370 is_leap_year -- is the given year a leap year? | |
371 | |
372 * Other new functions: | |
373 | |
374 bug_report -- submit a bug report to the bug-octave mailing list | |
375 | |
376 toascii -- convert a string to a matrix of ASCII character codes | |
377 | |
378 octave_tmp_file -- generate a unique temporary file name | |
379 | |
380 undo_string_escapes -- replace special characters in a string by | |
381 their backslash forms | |
382 | |
383 is_struct -- determine whether something is a structure data type | |
384 | |
385 feof -- check EOF condition for a specified file | |
386 ferror -- check error state for a specified file | |
387 fread -- read binary data from a file | |
388 fwrite -- write binary data to a file | |
389 | |
390 file_in_path -- check to see if named file exists in given path | |
391 | |
392 kbhit -- get a single character from the terminal | |
393 | |
394 axis -- change plot ranges | |
395 hist -- plot histograms | |
396 | |
397 diary -- save commands and output to a file | |
398 | |
399 type -- show the definition of a function | |
400 which -- print the type of an identifier or the location of a | |
401 function file | |
402 | |
403 isieee -- Returns 1 if host uses IEEE floating point | |
404 realmax -- Returns largest floating point number | |
405 realmin -- Returns smallest floating point number | |
406 | |
407 gcd -- greatest common divisor | |
408 lcm -- least common multiple | |
409 | |
410 null -- orthonormal basis of the null space of a matrix | |
411 orth -- orthonormal basis of the range space of a matrix | |
412 | |
413 fft2 -- two-dimensional fast fourier transform | |
414 ifft2 -- two-dimensional inverse fast fourier transform | |
415 filter -- digital filter | |
416 fftfilt -- filter using fft | |
417 fftconv -- convolve to vectors using fft | |
418 sinc -- returns sin(pi*x)/(pi*x) | |
419 freqz -- compute the frequency response of a filter | |
420 | |
421 * The meaning of nargin (== args.length ()) in built-in functions | |
422 has been changed to match the meaning of nargin in user-defined | |
423 functions. | |
424 | |
425 * Variable return lists. Octave now has a real mechanism for | |
426 handling functions that return an unspecified number of values, | |
427 so it is no longer necessary to place an upper bound on the number | |
428 of outputs that a function can produce. | |
429 | |
430 Here is an example of a function that uses the new syntax to | |
431 produce n values: | |
432 | |
433 function [...] = foo (n) | |
434 for i = 1:n | |
435 vr_val (i * x); | |
436 endfor | |
437 endfunction | |
438 | |
439 * New keyword, all_va_args, that allows the entire list of va_args | |
440 to be passed to another function. For example, given the functions | |
441 | |
442 function f (...) | |
443 while (nargin--) | |
444 disp (va_arg ()) | |
445 endwhile | |
446 endfunction | |
447 function g (...) | |
448 f ("begin", all_va_args, "end") | |
449 endfunction | |
450 | |
451 the statement | |
452 | |
453 g (1, 2, 3) | |
454 | |
455 prints | |
456 | |
457 begin | |
458 1 | |
459 2 | |
460 3 | |
461 end | |
462 | |
463 all_va_args may be used more than once, but can only be used | |
464 within functions that take a variable number of arguments. | |
465 | |
466 * If given a second argument, svd now returns an economy-sized | |
467 decomposition, eliminating the unecessary rows or columns of U or | |
468 V. | |
469 | |
470 * The max and min functions correctly handle complex matrices in | |
471 which some columns contain real values only. | |
472 | |
473 * The find function now handles 2 and 3 output arguments. | |
474 | |
475 * The qr function now allows computation of QR with pivoting. | |
476 | |
477 * hilb() is much faster for large matrices. | |
478 | |
479 * computer() is now a built-in function. | |
480 | |
481 * pinv() is now a built-in function. | |
482 | |
483 * The output from the history command now goes through the pager. | |
484 | |
485 * If a function is called without assigning the result, nargout is | |
486 now correctly set to 0. | |
487 | |
488 * It is now possible to write functions that only set some return | |
489 values. For example, calling the function | |
490 | |
491 function [x, y, z] = f () x = 1; z = 2; endfunction | |
492 | |
493 as | |
494 | |
495 [a, b, c] = f () | |
496 | |
497 produces: | |
498 | |
499 a = 1 | |
500 | |
501 b = [](0x0) | |
502 | |
503 c = 2 | |
504 | |
505 * The shell_cmd function has been renamed to system (the name | |
506 shell_cmd remains for compatibility). It now returns [output, status]. | |
507 | |
508 * New built-in variable `OCTAVE_VERSION'. Also a new function, | |
509 version, for compatibility with Matlab. | |
510 | |
511 * New built-in variable `automatic_replot'. If it is "true", Octave | |
512 will automatically send a replot command to gnuplot each time the | |
513 plot changes. Since this is fairly inefficient, the default value | |
514 is "false". | |
515 | |
516 * New built-in variable `whitespace_in_literal_matrix' allows some | |
517 control over how Octave decides to convert spaces to commas in | |
518 matrix expressions like `[m (1)]'. | |
519 | |
520 If the value of `whitespace_in_literal_matrix' is "ignore", Octave | |
521 will never insert a comma or a semicolon in a literal matrix list. | |
522 For example, the expression `[1 2]' will result in an error | |
523 instead of being treated the same as `[1, 2]', and the expression | |
524 | |
525 [ 1, 2, | |
526 3, 4 ] | |
527 | |
528 will result in the vector [1 2 3 4] instead of a matrix. | |
529 | |
530 If the value of `whitespace_in_literal_matrix' is "traditional", | |
531 Octave will convert spaces to a comma between identifiers and `('. | |
532 For example, given the matrix | |
533 | |
534 m = [3 2] | |
535 | |
536 the expression | |
537 | |
538 [m (1)] | |
539 | |
540 will be parsed as | |
541 | |
542 [m, (1)] | |
543 | |
544 and will result in | |
545 | |
546 [3 2 1] | |
547 | |
548 and the expression | |
549 | |
550 [ 1, 2, | |
551 3, 4 ] | |
552 | |
553 will result in a matrix because the newline character is converted | |
554 to a semicolon (row separator) even though there is a comma at the | |
555 end of the first line (trailing commas or semicolons are ignored). | |
556 This is apparently how Matlab behaves. | |
557 | |
558 Any other value for `whitespace_in_literal_matrix' results in | |
559 behavior that is the same as traditional, except that Octave does | |
560 not convert spaces to a comma between identifiers and `('. | |
561 For example, the expression | |
562 | |
563 [m (1)] | |
564 | |
565 will produce 3. This is the way Octave has always behaved. | |
566 | |
567 * Line numbers in error messages for functions defined in files and | |
568 for script files now correspond to the file line number, not the | |
569 number of lines after the function keyword appeared. | |
570 | |
571 * Octave now extracts help from script files. The comments must | |
572 come before any other statements in the file. | |
573 | |
574 * In function files, the first block of comments in the file will | |
575 now be interpreted as the help text if it doesn't look like the | |
576 Octave copyright notice. Otherwise, Octave extracts the first set | |
577 of comments after the function keyword. | |
578 | |
579 * The function clock is more accurate on systems that have the | |
580 gettimeofday() function. | |
581 | |
582 * The standard output stream is now automatically flushed before | |
583 reading from stdin with any of the *scanf() functions. | |
584 | |
585 * Expanded reference card. | |
586 | |
587 * The Octave distribution now includes a frequently asked questions | |
588 file, with answers. Better answers and more questions (with | |
589 answers!) are welcome. | |
590 | |
591 * New option --verbose. If Octave is invoked with --verbose and not | |
592 --silent, a message is printed if an octaverc file is read while | |
593 Octave is starting. | |
594 | |
595 * An improved configure script generated by Autoconf 2.0. | |
596 | |
597 * Lots of bug fixes. | |
598 </pre> | |
599 | |
600 <h2>Summary of changes for version 1.0</h2> | |
601 | |
602 <pre> | |
603 * C-style I/O functions now handle files referenced by name or by | |
604 number more consistently. | |
605 </pre> | |
606 | |
607 <h2>Summary of changes for version 0.83</h2> | |
608 | |
609 <pre> | |
610 * Loading global symbols should work now. | |
611 | |
612 * Clearing the screen doesn't reprint the prompt unnecessarily. | |
613 | |
614 * The operations <complex scalar> OP <real matrix> for OP == +, -, | |
615 *, or ./ no longer crash Octave. | |
616 | |
617 * More portability and configuration fixes. | |
618 </pre> | |
619 | |
620 <h2>Summary of changes for version 0.82</h2> | |
621 | |
622 <pre> | |
623 * Octave now comes with a reference card. | |
624 | |
625 * The manual has been improved, but more work remains to be done. | |
626 | |
627 * The atanh function now works for complex arguments. | |
628 | |
629 * The asin, acos, acosh, and atanh functions now work properly when | |
630 given real-valued arguments that produce complex results. | |
631 | |
632 * SEEK_SET, SEEK_CUR, and SEEK_END are now constants. | |
633 | |
634 * The `using' qualifier now works with gplot and gsplot when the | |
635 data to plot is coming directly from a file. | |
636 | |
637 * The strcmp function now works correctly for empty strings. | |
638 | |
639 * Eliminated bogus parse error for M-files that don't end with `end' | |
640 or `endfunction'. | |
641 | |
642 * For empty matrices with one nonzero dimension, the +, -, .*, and | |
643 ./ operators now correctly preserve the dimension. | |
644 | |
645 * Octave no longer crashes if you type ^D at the beginning of a line | |
646 in the middle of defining a loop or if statement. | |
647 | |
648 * On AIX systems, Back off on indexing DiagArray via Proxy class to | |
649 avoid gcc (or possibly AIX assembler?) bug. | |
650 | |
651 * Various other bug and portability fixes. | |
652 </pre> | |
653 | |
654 <h2>Summary of changes for version 0.81</h2> | |
655 | |
656 <pre> | |
657 * Octave no longer dumps core if you try to define a function in | |
658 your .octaverc file. | |
659 | |
660 * Fixed bug in Array class that resulted in bogus off-diagonal | |
661 elements when computing eigenvalue and singular value | |
662 decompositions. | |
663 | |
664 * Fixed bug that prevented lsode from working on the SPARCstation, | |
665 at least with some versions of Sun's f77. This bug was introduced | |
666 in 0.80, when I changed LSODE to allow the user to abort the | |
667 integration from within the RHS function. | |
668 | |
669 * Fixed bug that prevented global attribute of variables from being | |
670 saved with save(), and another that prevented load() from working | |
671 at all. | |
672 </pre> | |
673 | |
674 <h2>Summary of changes for version 0.80</h2> | |
675 | |
676 <pre> | |
677 * I have started working on a manual for the C++ classes. At this | |
678 point, it is little more than a list of function names. If you | |
679 would like to volunteer to help work on this, please contact | |
680 bug-octave@bevo.che.wisc.edu. | |
681 | |
682 * The patterns accepted by the save and clear commands now work like | |
683 file name globbing patterns instead of regular expressions. I | |
684 apologize for any inconvenience this change may cause, but file | |
685 name globbing seems like a more reasonable style of pattern | |
686 matching for this purpose. | |
687 | |
688 * It is now possible to specify tolerances and other optional inputs | |
689 for dassl, fsolve, lsode, npsol, qpsol, and quad. For each of | |
690 these functions, there is a corresponding function X_options, | |
691 which takes a keyword and value arguments. If invoked without any | |
692 arguments, the X_options functions print a list of possible | |
693 keywords and current values. For example, | |
694 | |
695 npsol_options () | |
696 | |
697 prints a list of possible options with values, and | |
698 | |
699 npsol_options ("major print level", 10) | |
700 | |
701 sets the major print level to 10. | |
702 | |
703 The keyword match is not case sensitive, and the keywords may be | |
704 abbreviated to the shortest unique match. For example, | |
705 | |
706 npsol_options ("ma p", 10) | |
707 | |
708 is equivalent to the statement shown above. | |
709 | |
710 * The new built-in variable save_precision can be used to set the | |
711 number of digits preserved by the ASCII save command. | |
712 | |
713 * Assignment of [] now works in most cases to allow you to delete | |
714 rows or columns of matrices and vectors. For example, given a | |
715 4x5 matrix A, the assignment | |
716 | |
717 A (3, :) = [] | |
718 | |
719 deletes the third row of A, and the assignment | |
720 | |
721 A (:, 1:2:5) = [] | |
722 | |
723 deletes the first, third, and fifth columns. | |
724 | |
725 * Variable argument lists. Octave now has a real mechanism for | |
726 handling functions that take an unspecified number of arguments, | |
727 so it is no longer necessary to place an upper bound on the number | |
728 of optional arguments that a function can accept. | |
729 | |
730 Here is an example of a function that uses the new syntax to print | |
731 a header followed by an unspecified number of values: | |
732 | |
733 function foo (heading, ...) | |
734 disp (heading); | |
735 va_start (); | |
736 while (--nargin) | |
737 disp (va_arg ()); | |
738 endwhile | |
739 endfunction | |
740 | |
741 Note that the argument list must contain at least one named | |
742 argument (this restriction may eventually be removed), and the | |
743 ellipsis must appear as the last element of the argument list. | |
744 | |
745 Calling va_start() positions an internal pointer to the first | |
746 unnamed argument and allows you to cycle through the arguments | |
747 more than once. It is not necessary to call va_start() if you | |
748 do not plan to cycle through the arguments more than once. | |
749 | |
750 * Recursive functions should work now. | |
751 | |
752 * The environment variable OCTAVE_PATH is now handled in the same | |
753 way as TeX handles TEXINPUTS. If the path starts with `:', the | |
754 standard path is prepended to the value obtained from the | |
755 environment. If it ends with `:' the standard path is appended to | |
756 the value obtained from the environment. | |
757 | |
758 * New functions, from Kurt Hornik (hornik@neuro.tuwien.ac.at) and | |
759 the Department of Probability Theory and Statistics TU Wien, | |
760 Austria: | |
761 | |
762 corrcoef -- corrcoef (X, Y) is the correlation between the i-th | |
763 variable in X and the j-th variable in Y | |
764 corrcoef (X) is corrcoef (X, X) | |
765 cov -- cov (X, Y) is the covariance between the i-th | |
766 variable in X and the j-th variable in Y | |
767 cov (X) is cov (X, X) | |
768 gls -- generalized least squares estimation | |
769 kurtosis -- kurtosis(x) = N^(-1) std(x)^(-4) SUM_i (x(i)-mean(x))^4 - 3 | |
770 If x is a matrix, return the row vector containing | |
771 the kurtosis of each column | |
772 mahalanobis -- returns Mahalanobis' D-square distance between the | |
773 multivariate samples X and Y, which must have the | |
774 same number of components (columns), but may have | |
775 a different number of observations (rows) | |
776 ols -- ordinary least squares estimation | |
777 pinv -- returns the pseudoinverse of X; singular values | |
778 less than tol are ignored | |
779 skewness -- skewness (x) = N^(-1) std(x)^(-3) SUM_i (x(i)-mean(x))^3 | |
780 if x is a matrix, return the row vector containing | |
781 the skewness of each column | |
782 | |
783 * Errors in user-supplied functions called from dassl, fsolve, | |
784 lsode, npsol, and quad are handled more gracefully. | |
785 | |
786 * Programming errors in the use of the C++ classes within Octave | |
787 should no longer cause Octave to abort. Instead, Octave's error | |
788 handler function is called and execution continues as best as is | |
789 possible. This should result in eventually returning control to | |
790 the top-level Octave prompt. (It would be nice to have a real | |
791 exception handling mechanism...) | |
792 | |
793 * A number of memory leaks have been eliminated. Thanks to | |
794 Fong Kin Fui <fui@ee.nus.sg> for reporting them. | |
795 | |
796 * The C++ matrix classes are now derived from a generic | |
797 template-based array class. | |
798 | |
799 * The readline function operate-and-get-next (from bash) is now | |
800 available and bound to C-O by default. | |
801 | |
802 * Octave now uses the version of readline currently distributed with | |
803 bash-1.13. On some systems, interactive invocations of Octave | |
804 will now blink the cursor to show matching parens. | |
805 | |
806 * By default, include files are now installed in | |
807 $prefix/include/octave instead of $prefix/include. | |
808 | |
809 * Octave now uses a config.h file instead of putting all defines on | |
810 the compiler command line. | |
811 </pre> | |
812 | |
813 <h2>Summary of changes for version 0.79</h2> | |
814 | |
815 <pre> | |
816 * New control systems functions: | |
817 | |
818 dgram -- Returns the discrete controllability and observability gramian. | |
819 dlqr -- Discrete linear quadratic regulator design. | |
820 dlqe -- Discrete linear quadratic estimator (Kalman Filter) design. | |
821 c2d -- Convert continuous system description to discrete time | |
822 description assuming zero-order hold and given sample time. | |
823 | |
824 * The max (min) functions can now return the index of the max (min) | |
825 value as a second return value. | |
826 </pre> | |
827 | |
828 <h2>Summary of changes for version 0.78</h2> | |
829 | |
830 <pre> | |
831 * Octave's handling of global variables has been completely | |
832 rewritten. To access global variables inside a function, you must | |
833 now declare them to be global within the function body. Likewise, | |
834 if you do not declare a variable as global at the command line, | |
835 you will not have access to it within a function, even if it is | |
836 declared global there. For example, given the function | |
837 | |
838 function f () | |
839 global x = 1; | |
840 y = 2; | |
841 endfunction | |
842 | |
843 the global variable `x' is not visible at the top level until the | |
844 command | |
845 | |
846 octave:13> global x | |
847 | |
848 has been evaluated, and the variable `y' remains local to the | |
849 function f() even if it is declared global at the top level. | |
850 | |
851 Clearing a global variable at the top level will remove its global | |
852 scope and leave it undefined. For example, | |
853 | |
854 octave:1> function f () # Define a function that accesses | |
855 > global x; # the global variable `x'. | |
856 > x | |
857 > endfunction | |
858 octave:2> global x = 1 # Give the variable `x' a value. | |
859 octave:3> f () # Evaluating the function accesses the | |
860 x = 1 # global `x'. | |
861 octave:4> clear x # Remove `x' from global scope, clear value. | |
862 octave:5> x = 2 # Define new local `x' at the top level | |
863 x = 2 | |
864 octave:6> f # The global `x' is no longer defined. | |
865 error: `x' undefined near line 1 column 25 | |
866 error: evaluating expression near line 1, column 25 | |
867 error: called from `f' | |
868 octave:7> x # But the local one is. | |
869 x = 2 | |
870 | |
871 * The new function, `is_global (string)' returns 1 if the variable | |
872 named by string is globally visible. Otherwise, returns 0. | |
873 | |
874 * The implementation of `who' has changed. It now accepts the | |
875 following options: | |
876 | |
877 -b -builtins -- display info for built-in variables and functions | |
878 -f -functions -- display info for currently compiled functions | |
879 -v -variables -- display info for user variables | |
880 -l -long -- display long info | |
881 | |
882 The long output looks like this: | |
883 | |
884 octave:5> who -l | |
885 | |
886 *** currently compiled functions: | |
887 | |
888 prot type rows cols name | |
889 ==== ==== ==== ==== ==== | |
890 wd user function - - f | |
891 | |
892 *** local user variables: | |
893 | |
894 prot type rows cols name | |
895 ==== ==== ==== ==== ==== | |
896 wd real scalar 1 1 y | |
897 | |
898 *** globally visible user variables: | |
899 | |
900 prot type rows cols name | |
901 ==== ==== ==== ==== ==== | |
902 wd complex matrix 13 13 x | |
903 | |
904 where the first character of the `protection' field is `w' if the | |
905 symbol can be redefined, and `-' if it has read-only access. The | |
906 second character may be `d' if the symbol can be deleted, or `-' | |
907 if the symbol cannot be cleared. | |
908 | |
909 * The new built-in variable ignore_function_time_stamp can be used | |
910 to prevent Octave from calling stat() each time it looks up | |
911 functions defined in M-files. If set to "system", Octave will not | |
912 automatically recompile M-files in subdirectories of | |
913 $OCTAVE_HOME/lib/VERSION if they have changed since they were last | |
914 compiled, but will recompile other M-files in the LOADPATH if they | |
915 change. If set to "all", Octave will not recompile any M-files | |
916 unless their definitions are removed with clear. For any other | |
917 value of ignore_function_time_stamp, Octave will always check to | |
918 see if functions defined in M-files need to recompiled. The | |
919 default value of ignore_function_time_stamp is "system". | |
920 | |
921 * The new built-in variable EDITOR can be used to specify the editor | |
922 for the edit_history command. It is set to the value of the | |
923 environment variable EDITOR, or `vi' if EDITOR is not set, or is | |
924 empty. | |
925 | |
926 * There is a new built-in variable, INFO_FILE, which is used as the | |
927 location of the info file. Its initial value is | |
928 $OCTAVE_HOME/info/octave.info, so `help -i' should now work | |
929 provided that OCTAVE_HOME is set correctly, even if Octave is | |
930 installed in a directory different from that specified at compile | |
931 time. | |
932 | |
933 * There is a new command line option, --info-file FILE, that may be | |
934 used to set Octave's idea of the location of the info file. It | |
935 will override any value of OCTAVE_INFO_FILE found in the | |
936 environment, but not any INFO_FILE="filename" commands found in | |
937 the system or user startup files. | |
938 | |
939 * Octave's Info reader will now recognize gzipped files that have | |
940 names ending in `.gz'. | |
941 | |
942 * The save command now accepts regular expressions as arguments. | |
943 Note that these patterns are regular expressions, and do not work | |
944 like filename globbing. For example, given the variables `a', | |
945 `aa', and `a1', the command `save a*' saves `a' and `aa' but not | |
946 `a1'. To match all variables beginning with `a', you must use an | |
947 expression like `a.*' (match all sequences beginning with `a' | |
948 followed by zero or more characters). | |
949 | |
950 * Line and column information is included in more error messages. | |
951 </pre> | |
952 | |
953 <h2>Summary of changes for version 0.77</h2> | |
954 | |
955 <pre> | |
956 * Improved help. The command `help -i topic' now uses the GNU Info | |
957 browser to display help for the given topic directly from the | |
958 Texinfo documenation. | |
959 | |
960 * New function: chol -- Cholesky factorization. | |
961 </pre> | |
962 | |
963 <h2>Summary of changes for version 0.76</h2> | |
964 | |
965 <pre> | |
966 * Better run-time error messages. Many now include line and column | |
967 information indicating where the error occurred. Octave will also | |
968 print a traceback for errors occurring inside functions. If you | |
969 find error messages that could use improvement, or errors that | |
970 Octave fails to catch, please send a bug report to | |
971 bug-octave@bevo.che.wisc.edu. | |
972 | |
973 * If gplot (or gsplot) is given a string to plot, and the string | |
974 does not name a file, Octave will pass the string along to gnuplot | |
975 directly. This allows commands like | |
976 | |
977 gplot "sin (x)" w l, data w p | |
978 | |
979 to work (assuming that data is a variable containing a matrix of | |
980 values). | |
981 | |
982 * Long options (--help, --version, etc.) are supported. | |
983 </pre> | |
984 | |
985 <h2>Summary of changes for version 0.75</h2> | |
986 | |
987 <pre> | |
988 * The documentation is much more complete, but still could use a lot | |
989 of work. | |
990 | |
991 * The history function now prints line numbers by default. The | |
992 command `history -q' will omit them. | |
993 | |
994 * The clear function now accepts regular expressions. | |
995 | |
996 * If gplot (or gsplot) is given a string to plot, and the string | |
997 names a file, Octave attempts to plot the contents of the file. | |
998 | |
999 * New functions: | |
1000 | |
1001 history: | |
1002 | |
1003 run_history -- run commands from the history list. | |
1004 edit_history -- edit commands from the history list with your | |
1005 favorite editor. | |
1006 | |
1007 linear algebra: | |
1008 | |
1009 balance -- Balancing for algebraic and generalized | |
1010 eigenvalue problems. | |
1011 givens -- Givens rotation. | |
1012 is_square -- Check to see if a matrix is square. | |
1013 qzhess -- QZ decomposition of the matrix pencil (a - lambda b). | |
1014 qzval -- Generalized eigenvalues for real matrices. | |
1015 syl -- Sylvester equation solver. | |
1016 | |
1017 control systems: | |
1018 | |
1019 is_symmetric -- Check to see if a matrix is symmetric. | |
1020 abcddim -- Check dimensions of linear dynamic system [A,B,C,D]. | |
1021 is_controllable -- Check to see if [A,B,C,D] is controllable. | |
1022 is_observable -- Check to see if [A,B,C,D] is observable. | |
1023 are -- Solve algebraic Ricatti equation. | |
1024 dare -- Solve discrete-time algebraic Ricatti equation. | |
1025 lqe -- Kalman filter design for continuous linear system. | |
1026 lqr -- Linear Quadratic Regulator design. | |
1027 lyap -- Solve Lyapunov equation. | |
1028 dlyap -- Solve discrete Lyapunov equation. | |
1029 tzero -- Compute the transmission zeros of [A,B,C,D]. | |
1030 </pre> | |
1031 | |
1032 <h2>Summary of changes for version 0.74</h2> | |
1033 | |
1034 <pre> | |
1035 * Formal parameters to functions are now always considered to be | |
1036 local variables, so things like | |
1037 | |
1038 global x = 0 | |
1039 global y = 0 | |
1040 function y = f (x) x = 1; y = x; end | |
1041 f (x) | |
1042 | |
1043 result in the function returning 1, with the global values of x | |
1044 and y unchanged. | |
1045 | |
1046 * Multiple assignment expressions are now allowed to take indices, | |
1047 so things like | |
1048 | |
1049 octave:13> [a([1,2],[3,4]), b([5,6],[7,8])] = lu ([1,2;3,4]) | |
1050 | |
1051 will work correctly. | |
1052 </pre> | |
1053 | |
1054 <h2>Summary of changes for version 0.73</h2> | |
1055 | |
1056 <pre> | |
1057 * Saving and loading global variables works correctly now. | |
1058 | |
1059 * The save command no longer saves built-in variables. | |
1060 | |
1061 * Global variables are more reliable. | |
1062 | |
1063 * Matrices may now have one or both dimensions zero, so that | |
1064 operations on empty matrices are now handled more consistently. | |
1065 | |
1066 By default, dimensions of the empty matrix are now printed along | |
1067 with the empty matrix symbol, `[]'. For example: | |
1068 | |
1069 octave:13> zeros (3, 0) | |
1070 ans = | |
1071 | |
1072 [](3x0) | |
1073 | |
1074 The new variable `print_empty_dimensions' controls this behavior. | |
1075 | |
1076 See also Carl de Boor, An Empty Exercise, SIGNUM, Volume 25, | |
1077 pages 2--6, 1990, or C. N. Nett and W. M. Haddad, A | |
1078 System-Theoretic Appropriate Realization of the Empty Matrix | |
1079 Concept, IEEE Transactions on Automatic Control, Volume 38, | |
1080 Number 5, May 1993. | |
1081 | |
1082 * The right and left division operators `/' and `\' will now find a | |
1083 minimum norm solution if the system is not square, or if the | |
1084 coefficient matrix is singular. | |
1085 | |
1086 * New functions: | |
1087 | |
1088 hess -- Hessenberg decomposition | |
1089 schur -- Ordered Schur factorization | |
1090 perror -- print error messages corresponding to error codes | |
1091 returned from the functions fsolve, npsol, and qpsol | |
1092 (with others to possibly be added later). | |
1093 | |
1094 * Octave now prints a warning if it finds anything other than | |
1095 whitespace or comments after the final `end' or `endfunction' | |
1096 statement. | |
1097 | |
1098 * The bodies of functions, and the for, while, and if commands are | |
1099 now allowed to be empty. | |
1100 | |
1101 * Support for Gill and Murray's QPSOL has been added. Like NPSOL, | |
1102 QPSOL is not freely redistributable either, so you must obtain | |
1103 your own copy to be able to use this feature. More information | |
1104 about where to find QPSOL and NPSOL are in the file README.NLP. | |
1105 </pre> | |
1106 | |
1107 <h2>Summary of changes for version 0.72</h2> | |
1108 | |
1109 <pre> | |
1110 * For numeric output, columns are now lined up on the decimal point. | |
1111 (This requires libg++-2.3.1 or later to work correctly). | |
1112 | |
1113 * If octave is running interactively and the output intended for the | |
1114 screen is longer than one page and a pager is available, it is | |
1115 sent to the pager through a pipe. You may specify the program to | |
1116 use as the pager by setting the variable PAGER. PAGER may also | |
1117 specify a command pipeline. | |
1118 | |
1119 * Spaces are not always significant inside square brackets now, so | |
1120 commands like | |
1121 | |
1122 [ linspace (1, 2) ] | |
1123 | |
1124 will work. However, some possible sources of confusion remain | |
1125 because Octave tries (possibly too hard) to determine exactly what | |
1126 operation is intended from the context surrounding an operator. | |
1127 For example: | |
1128 | |
1129 -- In the command | |
1130 | |
1131 [ 1 - 1 ] | |
1132 | |
1133 the `-' is treated as a binary operator and the result is the | |
1134 scalar 0, but in the command | |
1135 | |
1136 [ 1 -1 ] | |
1137 | |
1138 the `-' is treated as a unary operator and the result is the | |
1139 vector [ 1 -1 ]. | |
1140 | |
1141 -- In the command | |
1142 | |
1143 a = 1; [ 1 a' ] | |
1144 | |
1145 the single quote character `'' is treated as a transpose operator | |
1146 and the result is the vector [ 1 1 ], but in the command | |
1147 | |
1148 a = 1; [ 1 a ' ] | |
1149 | |
1150 an error message indicating an unterminated string constant is | |
1151 printed. | |
1152 | |
1153 * Assignments are just expressions now, so they are valid anywhere | |
1154 other expressions are. This means that things like | |
1155 | |
1156 if (a = n < m) ... endif | |
1157 | |
1158 are valid. This is parsed as: compare `n < m', assign the result | |
1159 to the variable `a', and use it as the test expression in the if | |
1160 statement. | |
1161 | |
1162 To help avoid errors where `=' has been used but `==' was | |
1163 intended, Octave issues a warning suggesting parenthesis around | |
1164 assignments used as truth values. You can suppress this warning | |
1165 by adding parenthesis, or by setting the value of the new built-in | |
1166 variable `warn_assign_as_truth_value' to 'false' (the default | |
1167 value is 'true'). | |
1168 | |
1169 This is also true for multiple assignments, so expressions like | |
1170 | |
1171 [a, b, c] = [u, s, v] = expression | |
1172 | |
1173 are now possible. If the expression is a function, nargout is set | |
1174 to the number of arguments for the right-most assignment. The | |
1175 other assignments need not contain the same number of elements. | |
1176 Extra left hand side variables in an assignment become undefined. | |
1177 | |
1178 * The default line style for plots is now `lines' instead of | |
1179 `points'. To change it, use the `set data style STYLE' command. | |
1180 | |
1181 * New file handling and I/O functions: | |
1182 | |
1183 fopen -- open a file for reading or writing | |
1184 fclose -- close a file | |
1185 fflush -- flush output to a file | |
1186 fgets -- read characters from a file | |
1187 frewind -- set file position to the beginning of a file | |
1188 fseek -- set file position | |
1189 ftell -- tell file position | |
1190 freport -- print a report for all open files | |
1191 fscanf -- read from a file | |
1192 sscanf -- read from a string | |
1193 scanf -- read from the standard input | |
1194 | |
1195 * New built-in variables for file and I/O functions: | |
1196 | |
1197 stdin -- file number corresponding to the standard input stream. | |
1198 stdout -- file number corresponding to the standard output stream. | |
1199 stderr -- file number corresponding to the standard error stream. | |
1200 | |
1201 The following may be used as the final (optional) argument for | |
1202 fseek: | |
1203 | |
1204 SEEK_SET -- set position relative to the beginning of the file. | |
1205 SEEK_CUR -- set position relative to the current position. | |
1206 SEEK_END -- set position relative to the end of the file. | |
1207 | |
1208 * New function: setstr -- convert vectors or scalars to strings | |
1209 (doesn't work for matrices yet). | |
1210 | |
1211 * If possible, computer now prints the system type instead of | |
1212 always printing `Hi Dave, I'm a HAL-9000'. | |
1213 | |
1214 * Octave now properly saves and restores its internal state | |
1215 correctly in more places. Interrupting Octave while it is | |
1216 executing a script file no longer causes it to exit. | |
1217 | |
1218 * Octave now does tilde expansion on each element of the LOADPATH. | |
1219 | |
1220 * A number of memory leaks have been plugged. | |
1221 | |
1222 * Dependencies for C++ source files are now generated automatically | |
1223 by g++. | |
1224 | |
1225 * There is a new command line option, -p PATH, that may be used to | |
1226 set Octave's loadpath from the command line. It will override any | |
1227 value of OCTAVE_PATH found in the environment, but not any | |
1228 LOADPATH="path" commands found in the system or user startup files. | |
1229 | |
1230 * It is now possible to override Octave's default idea of the | |
1231 location of the system-wide startup file (usually stored in | |
1232 $(prefix)/lib/octave/octaverc) using the environment variable | |
1233 OCTAVE_HOME. If OCTAVE_HOME has a value, Octave will look for | |
1234 octaverc and its M-files in the directory $OCTAVE_HOME/lib/octave. | |
1235 | |
1236 This allows people who are using binary distributions (as is | |
1237 common with systems like Linux) to install the real octave binary | |
1238 in any directory (using a name like octave.bin) and then install | |
1239 a simple script like this | |
1240 | |
1241 #!/bin/sh | |
1242 OCTAVE_HOME=/foo/bar/baz | |
1243 export OCTAVE_HOME | |
1244 exec octave.bin | |
1245 | |
1246 to be invoked as octave. | |
1247 | |
1248 </pre> | |
1249 | |
1250 <h2>Summary of changes for version 0.71</h2> | |
1251 | |
1252 <pre> | |
1253 * Much improved plotting facility. With this release, Octave does | |
1254 not require a specially modified version of gnuplot, so gnuplot | |
1255 sources are no longer distributed with Octave. For a more | |
1256 detailed description of the new plotting features, see the file | |
1257 PLOTTING. | |
1258 | |
1259 * New plotting commands: | |
1260 | |
1261 plot -- 2D plots | |
1262 semilogx -- 2D semilog plot with logscale on the x axis | |
1263 semilogy -- 2D semilog plot with logscale on the y axis | |
1264 loglog -- 2D log-log plot | |
1265 mesh -- 3D mesh plot | |
1266 meshdom -- create matrices for 3D plotting from two vectors | |
1267 contour -- contour plots of 3D data | |
1268 bar -- create bar graphs | |
1269 stairs -- create stairstep plots | |
1270 polar -- 2D plots from theta-R data | |
1271 grid -- turn plot grid lines on or off | |
1272 xlabel, ylabel -- place labels on the x and y axes of 2D plots | |
1273 sombrero -- demonstrate 3D plotting | |
1274 gplot -- 2D plot command with gnuplot-like syntax | |
1275 gsplot -- 3D plot command with gnuplot-like syntax | |
1276 set -- set plot options with gnuplot syntax | |
1277 show -- show plot options with gnuplot syntax | |
1278 closeplot -- close stream to gnuplot process | |
1279 purge_tmp_files -- delete temporary files created by plot command | |
1280 | |
1281 * Other new commands: | |
1282 | |
1283 ls, dir -- print a directory listing | |
1284 shell_cmd -- execute shell commands | |
1285 keyboard -- get input from keyboard, useful for debugging | |
1286 menu -- display a menu of options and ask for input | |
1287 fft -- fast fourier transform | |
1288 ifft -- inverse fast fourier transform | |
1289 | |
1290 * Strings may be enclosed in either single or double quote | |
1291 characters. Double quote characters are not special within single | |
1292 quote strings, and single quotes are not special within double | |
1293 quote strings. | |
1294 | |
1295 * Command name completion now works for M-file names too. | |
1296 | |
1297 * Better help and usage messages for many functions. | |
1298 | |
1299 * Help is now available for functions defined in M-files. The first | |
1300 block of comments is taken as the text of the help message. | |
1301 | |
1302 * Numerous changes in preparation to support dynamic loading of | |
1303 object files with dld. | |
1304 | |
1305 * Bug fixes to make solving DAEs with dassl actually work. | |
1306 | |
1307 * The command `save file' now saves all variables in the named file. | |
1308 | |
1309 * If do_fortran_indexing is 'true', indexing a scalar with | |
1310 [1,1,1,...] (n times) replicates its value n times. The | |
1311 orientation of the resulting vector depends on the value of | |
1312 prefer_column_vectors. | |
1313 | |
1314 * Things like [[1,2][3,4]] no longer cause core dumps, and invalid | |
1315 input like [1,2;3,4,[5,6]] now produces a diagnositic message. | |
1316 | |
1317 * The cd, save, and load commands now do tilde expansion. | |
1318 | |
1319 * It's now possible to clear global variables and functions by name. | |
1320 | |
1321 * Use of clear inside functions is now a parse error. | |
1322 </pre> | |
1323 | |
1324 <h2>Summary of changes for version 0.70</h2> | |
1325 | |
1326 <pre> | |
1327 * Better parse error diagnostics. For interactive input, you get | |
1328 messages like | |
1329 | |
1330 octave:1> a = 3 + * 4; | |
1331 | |
1332 parse error: | |
1333 | |
1334 a = 3 + * 4; | |
1335 ^ | |
1336 | |
1337 and for script files, the message includes the file name and input | |
1338 line number: | |
1339 | |
1340 octave:1> foo | |
1341 | |
1342 parse error near line 4 of file foo.m: | |
1343 | |
1344 a = 3 + * 4; | |
1345 ^ | |
1346 | |
1347 * New built-in variable PS2 which is used as the secondary prompt. | |
1348 The default value is '> '. | |
1349 | |
1350 * New file, octave-mode.el, for editing Octave code with GNU Emacs. | |
1351 This is a modified version of Matthew R. Wette's matlab-mode.el. | |
1352 | |
1353 * Better support for missing math functions. | |
1354 | |
1355 * User preferences are now cached in a global struct so we don't | |
1356 have to do a symbol table lookup each time we need to know what | |
1357 they are. This should mean slightly improved performance for | |
1358 evaluating expressions. | |
1359 </pre> | |
1360 | |
1361 <h2>Summary of changes for version 0.69</h2> | |
1362 | |
1363 <pre> | |
1364 * Multiple assignments are now possible, so statements like | |
1365 | |
1366 a = b = c = 3; | |
1367 a = b = c = [1,2;3,4]; | |
1368 | |
1369 or | |
1370 | |
1371 c = (a = (b = 2) * 3 + 4) * 5 | |
1372 | |
1373 are legal, as are things that have even more bizarre effects, like | |
1374 | |
1375 a(4:6,4:6) = b(2:3,2:3) = [1,2;3,4]; | |
1376 | |
1377 (try it). | |
1378 | |
1379 * Improved parsing of strings (but they still don't work as matrix | |
1380 elements). | |
1381 | |
1382 * An M-file may now either define a function or be a list of | |
1383 commands to execute. | |
1384 | |
1385 * Better detection and conditional compilation of IEEE functions | |
1386 isinf, finite, and isnan. | |
1387 | |
1388 * Replacements for acosh, asinh, atanh, and gamma from the BSD math | |
1389 library for those systems that don't have them. | |
1390 </pre> | |
1391 | |
1392 <h2>Summary of changes for version 0.68</h2> | |
1393 | |
1394 <pre> | |
1395 * New functions: | |
1396 | |
1397 eval -- evaluate a string as a sequence of Octave commands. | |
1398 input -- print a prompt and get user input. | |
1399 </pre> | |
1400 | |
1401 <h2>Summary of changes for version 0.67</h2> | |
1402 | |
1403 <pre> | |
1404 * New functions: | |
1405 | |
1406 find -- return the indices of nonzero elements. | |
1407 | |
1408 * Zero-one style indexing now works. For example, | |
1409 | |
1410 a = [1,2,3,4]; | |
1411 b = a([1,0,0,1]) | |
1412 | |
1413 sets b to the first and fourth elememnts of a. | |
1414 | |
1415 Zero-one style indexing also works for indexing the left hand side | |
1416 of an assignment. For example, | |
1417 | |
1418 a = rand (1,2;3,4); | |
1419 a([0,1],:) = [-1,-2] | |
1420 | |
1421 sets the second row of a to [-1 -2] | |
1422 | |
1423 The behavior for the ambiguous case | |
1424 | |
1425 a = [1,2,3,4]; | |
1426 b = a([1,1,1,1]); | |
1427 | |
1428 is controlled by the new global variable `prefer_zero_one_indexing'. | |
1429 If this variable is equal to 'true', b will be set to [1 2 3 4]. | |
1430 If it is false, b will be set to [1 1 1 1]. The default value is | |
1431 'false'. | |
1432 | |
1433 * Using the new global variable `propagate_empty_matrices', it is | |
1434 possible to have unary andy binary operations on empty matrices | |
1435 return an empty matrix. The default value of this variable is | |
1436 'warn', so that empty matrices are propagated but you get a | |
1437 warning. Some functions, like eig and svd have also been changed | |
1438 to handle this. | |
1439 | |
1440 * Empty matrices can be used in conditionals, but they always | |
1441 evaluate to `false'. With propagate_empty_matrices = 'true', both | |
1442 of the following expressions print 0: | |
1443 | |
1444 if [], 1, else 0, end | |
1445 if ~[], 1, else 0, end | |
1446 | |
1447 * Octave no longer converts input like `3.2 i' or `3 I' to complex | |
1448 constants directly because that causes problems inside square | |
1449 brackets, where spaces are important. This abbreviated notation | |
1450 *does* work if there isn't a space between the number and the i, | |
1451 I, j, or J. | |
1452 </pre> | |
1453 | |
1454 <h2>Summary of changes for version 0.66</h2> | |
1455 | |
1456 <pre> | |
1457 * Logical unary not operator (~ or !) now works for complex. | |
1458 | |
1459 * Left division works. | |
1460 | |
1461 * Right and left element by element division should work correctly | |
1462 now. | |
1463 | |
1464 * Numbers like .3e+2 are no longer errors. | |
1465 | |
1466 * Indexing a matrix with a complex value doesn't cause a core dump. | |
1467 | |
1468 * The min and max functions should work correctly for two arguments. | |
1469 | |
1470 * Improved (I hope!) configuration checks. | |
1471 | |
1472 * Octave is now installed as octave-M.N, where M and N are version | |
1473 numbers, and octave is a link to that file. This makes it | |
1474 possible to have more than one version of the interpreter installed. | |
1475 </pre> | |
1476 | |
1477 <h2>Summary of changes for version 0.63</h2> | |
1478 | |
1479 <pre> | |
1480 * The reshape function works again. | |
1481 | |
1482 * Octave now converts input like `3.2i' or `3 I' or `2.3e5 j' to be | |
1483 complex constants directly, rather than requiring an expression | |
1484 like `3.3 * i' to be evaluated. | |
1485 </pre> | |
1486 | |
1487 <h2>Summary of changes for version 0.61</h2> | |
1488 | |
1489 <pre> | |
1490 * Octave has been successfully compiled using gcc 2.3.3 and libg++ 2.3. | |
1491 on a 486 system running Linux. | |
1492 | |
1493 * The win_texas_lotto function is now called texas_lotto (it's a | |
1494 script file, and win_texas_lotto.m is too long for some Linux and | |
1495 System V systems). | |
1496 </pre> | |
1497 | |
1498 <h2>Summary of changes for version 0.57</h2> | |
1499 | |
1500 <pre> | |
1501 * The C-like formatted print functions printf, fprintf, and sprintf | |
1502 finally work. | |
1503 </pre> | |
1504 | |
1505 <h2>Summary of changes for version 0.56</h2> | |
1506 | |
1507 <pre> | |
1508 * By default, octave prints a short disclaimer when it starts. | |
1509 (You can suppress it by invoking octave with -q). | |
1510 | |
1511 * You can keep octave from reading your ~/.octaverc and .octaverc | |
1512 files by invoking it with -f. | |
1513 | |
1514 * When returning two values, eig now returns [v, d] instead of | |
1515 [lambda, v], where d is a diagonal matrix made from lambda. | |
1516 | |
1517 * The win_texas_lotto function now produces a sorted list. | |
1518 | |
1519 * New functions: | |
1520 | |
1521 expm -- matrix exponential. | |
1522 logm -- matrix logarithm. | |
1523 </pre> | |
1524 | |
1525 <h2>Summary of changes for version 0.55</h2> | |
1526 | |
1527 <pre> | |
1528 * The following (C-style) backslash escape sequences work in quoted | |
1529 strings (useful(?) with printf()): | |
1530 | |
1531 \a bell \r carriage return | |
1532 \b backspace \t horizontal tab | |
1533 \f formfeed \v vertical tab | |
1534 \n newline \\ backslash | |
1535 | |
1536 * Use of `...' at the end of a line will allow a statement to | |
1537 continue over more than one line. | |
1538 | |
1539 * The names `inf' and `nan' are now aliases for `Inf' and `NaN', | |
1540 respectively. | |
1541 | |
1542 * New functions: | |
1543 | |
1544 casesen -- print a warning if the luser tries to turn off case | |
1545 sensitivity. | |
1546 median -- find median value. | |
1547 norm -- compute the norm of a matrix. | |
1548 sort -- sort columns. | |
1549 | |
1550 * New variable, `silent_functions'. If silent_functions == 'true', | |
1551 the results of expressions are not printed even if they are not | |
1552 followed by a semicolon. The disp() and printf() functions still | |
1553 result in output. The default value for this variable is 'false'. | |
1554 | |
1555 * New variable `return_last_value_computed'. If it is 'true', | |
1556 functions defined in script files return the last value computed | |
1557 if a return value has not been explicitly declared. The default | |
1558 value for this variable is 'false'. | |
1559 </pre> | |
1560 | |
1561 <h2>Summary of changes for version 0.52</h2> | |
1562 | |
1563 <pre> | |
1564 * Name completion works for function and variable names currently in | |
1565 the symbol tables. Coming soon: completion for names of functions | |
1566 defined in script files but not yet compiled. | |
1567 | |
1568 * The initial value of do_fortran_indexing is now false, and the | |
1569 initial value of prefer_column_vectors is now true. Swap the | |
1570 values of these variables if you want behavior that is more like | |
1571 Matlab. | |
1572 | |
1573 * All script files check the number of input arguments before doing | |
1574 much real work. | |
1575 | |
1576 * The identifiers `i' and `j' are now also names for sqrt(-1). | |
1577 These symbols may be used for other purposes, but their original | |
1578 definition will reappear if they are cleared. | |
1579 | |
1580 * The symbol tables are now implemented with hash tables for faster | |
1581 searching. | |
1582 | |
1583 * A small amount of help is now available for most built-in | |
1584 operators, keywords and functions. Coming soon: help for script | |
1585 files. | |
1586 | |
1587 * Without any arguments, the help command now lists all known | |
1588 built-in operators, keywords and functions. | |
1589 | |
1590 * Generic parse errors are now signalled by `Eh, what's up doc?', | |
1591 which is closer to what Bugs actually says. | |
1592 | |
1593 * The who command now only prints variable names by default. | |
1594 Use the -fcn (or -fcns, or -functions) switch to print the names of | |
1595 built-in or currently compiled functions. | |
1596 </pre> | |
1597 | |
1598 <h2>Summary of changes for version 0.51</h2> | |
1599 | |
1600 <pre> | |
1601 * Major overhaul of array indexing. | |
1602 | |
1603 * The colloc function actually works now. | |
1604 </pre> | |
1605 | |
1606 <h2>Summary of changes for version 0.50</h2> | |
1607 | |
1608 <pre> | |
1609 * The lsode and dassl functions now return the states only, | |
1610 instead of the time and the states, so you must keep track of | |
1611 the corresponding times (this is easy though, because you have | |
1612 to specify a vector of desired output times anyway). | |
1613 | |
1614 * Solution of NLPs with NPSOL now works on the SPARC. | |
1615 | |
1616 * New keywords `endif', `endfor', `endfunction', `endif', and | |
1617 `endwhile', which allow for better diagnostics. The `end' keyword | |
1618 is still recognized. All script files have been changed to use | |
1619 these new keywords in place of `end'. | |
1620 | |
1621 * It is now possible to uninstall Octave by doing a `make uninstall' | |
1622 in the top level directory. | |
1623 | |
1624 * The Makefiles are much closer to conforming with GNU coding standards. | |
1625 | |
1626 * New functions: | |
1627 | |
1628 win_texas_lotto -- produce six unique random numbers between 1 and 50. | |
1629 quad -- numerical integration. | |
1630 lu -- LU factorization | |
1631 qr -- QR factorization | |
1632 dassl -- Solution of DAEs using DASSL. | |
1633 | |
1634 * New files: | |
1635 | |
1636 THANKS -- A list of people and organazations who have supported | |
1637 the development of Octave. | |
1638 | |
1639 NEWS -- This file, listing recent changes. | |
1640 | |
1641 * Help is now available at the gnuplot prompt. | |
1642 </pre> |