[sdiy] Best software noise algorithm?
Tom Wiltshire
tom at electricdruid.net
Wed Feb 17 19:01:19 CET 2010
Hi All,
What's the most efficient software pseudo-random noise algorithm?
I have previously used LFSRs, which are reasonably quick and can
produce very long sequences quite easily, but I'm looking for
something really quick and dirty.
I looked into Linear Congruential Generators, and found lots of sites
that said that these can be very quick if you ensure the modulus is a
power of two. But most examples are actually with the Parks-Miller
numbers, which aren't a power of two.
I'll be doing this in dsPIC assembly as usual, and I've currently got
a 64-bit LFSR that generates a new 16-bit number in 19 cycles. The
quality and sequence length of that are more than I really need, so
I'd like to speed it up.
Have people got any good tricks to share for making random numbers
quickly ?
Thanks,
Tom
More information about the Synth-diy
mailing list