Discussion about arrays and matrices in Maxima



dlakelan wrote:
> Richard Fateman wrote:
>
>   
>> I agree entirely with your comments on random. I have written a program 
>> that does something like this.  I found the lisp random number generator 
>> to be too slow (it is too general) and so I found another method to fill 
>> a ring-buffer with "enough" pseudo-random numbers for my purpose and 
>> then I used them one after another for my simulation.  Using a looped 
>> list, I could get the next number by using   (pop random_number_loop).
>> Of course these were not so random if you used it for long enough.
>> RJF
>>     
>
> I have found that the random number generator in SBCL when specialized 
> to produce uniform double floats is pretty darn fast. About the same as 
> the R random number generator. It is also a mersenne twister algorithm 
> so it is high quality.
>   
FWIW, Maxima already includes the same generator (in portable Lisp). 
For CMUCL and SBCL, this generator should be the pretty close to the
same speed as the builtin RNG.  For other lisps, it will depend very
much on how well the compiler optimizes the code.

Ray