From bug-request at octave dot org Sat Apr 15 10:21:01 2006 Subject: Re: help rand version 2.9.x latest From: "Keith Goodman" To: "Jorge Barros de Abreu" Cc: bug at octave dot org Date: Sat, 15 Apr 2006 08:19:19 -0700 On 4/15/06, Jorge Barros de Abreu wrote: > In the command "help rand" there is: > > This new state will be a hash based on the > the value of at var{v}, not @var{v} itself. > > i think that the correct is: > > This new state will be a hash based on > the value of at var{v}, not @var{v} itself. > > And also there is "numebrs". I think that the correct is "numbers". You have a sharp eye. If anyone would like to help make patches for doc fixes, here's a howto. (Maybe someone can dump this howto in the Octave wiki so it can be improved to point where it is useful.) Make a new directory for the patch: $ mkdir rand_doc_patch Download rand.cc. (If you don't know it is rand.cc, you can download all of octave and then search all files for a phrase from the rand doc string.): $ cvs -d :ext:anoncvs at www dot octave dot org:/cvs -z 9 checkout octave/src/DLD-FUNCTIONS/rand.cc Open rand.cc in a text editor, fix the typos, and save the file (writing over the original). Generate a patch (rand.cc.patch) that contains the changes you made to the doc string: $ cd octave/ $ cvs diff -u > rand.cc.patch Open rand.cc.patch in a text editor and insert a changelog entry at the top of the file: 2006-04-15 Keith Goodman * DLD-FUNCTIONS/rand.cc: Doc string fix. (Do I need to specify where in rand.cc the change was made? As in * DLD-FUNCTIONS/rand.cc (rand): Doc string fix.) Attach the patch to an email and send it to bug at octave dot org dot Here's what the patch looks like: 2006-04-15 Keith Goodman * DLD-FUNCTIONS/rand.cc: Doc string fix. ? rand.cc.patch Index: src/DLD-FUNCTIONS/rand.cc =================================================================== RCS file: /cvs/octave/src/DLD-FUNCTIONS/rand.cc,v retrieving revision 1.28 diff -u -r1.28 rand.cc --- src/DLD-FUNCTIONS/rand.cc 14 Apr 2006 04:01:40 -0000 1.28 +++ src/DLD-FUNCTIONS/rand.cc 15 Apr 2006 14:49:50 -0000 at @ -324,7 +324,7 @@ at noindent\n\ You may also initialize the state vector from an arbitrary vector of\n\ length <= 625 for at var{v} dot This new state will be a hash based on the\n\ -the value of at var{v}, not @var{v} itself.\n\ +value of at var{v}, not @var{v} itself.\n\ \n\ By default, the generator is initialized from at code{/dev/urandom} if it is\n\ available, otherwise from cpu time, wall clock time and the current\n\ at @ -342,7 +342,7 @@ at code{rand} includes a second random number generator, that was the\n\ previous generator used in octave. The new generator is used by default\n\ as it is significantly faster than the old generator, and produces\n\ -random numebrs with a significantly longer cycle time. However, in\n\ +random numbers with a significantly longer cycle time. However, in\n\ some circumstances it might be desireable to obtain the same random\n\ sequences as used by the old generators. To do this the keyword\n\ \"seed\" is used to specify that the old generators should be use,\n\ ------------------------------------------------------------- Octave is freely available under the terms of the GNU GPL. Octave's home on the web: http://www.octave.org How to fund new projects: http://www.octave.org/funding.html Subscription information: http://www.octave.org/archive.html -------------------------------------------------------------