??? 09/10/07 10:40 Read: times |
#144276 - HOWTO generate a uniformly-distributed random nu |
Hello all;
I want to generate a uniformly-distributed random number. In C language I use (float) lrand48() which return number in 0..RAND_MAX range. So what's its equivalent in sdcc compiler. I found something at this page http://www.8052.com/forum/read.phtml?id=62945 but I still wonder why in prng_get_double function calls prng_get_ulong which is apparently not uniformly-distributed prng. Am I wrong ? Thanks |