Re: 32-bit random numbers
- Posted by Al Getz <Xaxo at aol.com> Jul 10, 2004
- 594 views
Igor Kachan wrote: > I can say nothing about the distribution > on your formula. I just see it is not flat. Ok, it's one thing to *SAY* it's not flat, for example, i can *SAY* YOURS isnt flat, but it's another story to *PROVE* it's not flat. You see now? You can teach a 4 year old to say 'everything is not flat' but it's not true, is it? In other words, PROVE it's not flat. The reason i say this is because it looks like the distribution *IS* flat, but there is of course always the chance i made a mistake in the analysis, im just human! So, if you want me to understand why you say it is *NOT* flat, please show me how you came to this conclusion. BTW, i wasnt saying YOUR function isnt flat, im just asking why you needed another function, that's all, and what the benefits are. I thought maybe you wanted higher and higher random integers so i proposed another solution The proposed solution goes up to ANY desired integer ceiling, not just #FFFFFFFF or whatever. Im not saying there is no chance i made a mistake, im just asking that you show me why you say it's not flat, especially the N*(rand(N)-1)+rand(N)-1, with N=#10000 formula? BTW, by 'flat' i assumed you meant that there is equal chance of getting any number from 0 to max, so there are no preferences. BTW(2), it would also be good to have a formula to specify the max, such as max=N*(N-1)+N-1 or something like that. > But you do see just now that proposed new > function seems to give the flat distribution. Yes, but i was only asking what the reasoning behind developing a new formula would be, if it does the same. If it does something different, that's cool too Take care, Al And, good luck with your Euphoria programming! My bumper sticker: "I brake for LED's"