comp.lang.ada
 help / color / mirror / Atom feed
* Simple hash or pseudo-random function
@ 2018-07-16  8:20 gautier_niouzes
  2018-07-16 13:34 ` Shark8
                   ` (4 more replies)
  0 siblings, 5 replies; 12+ messages in thread
From: gautier_niouzes @ 2018-07-16  8:20 UTC (permalink / raw)


Hello,
Does someone have a function that would take an integer (range 0 .. 2**63), not uniformily distributed (it's a code with some meaning) and return a number that is pseudo-random, uniformily distributed (could be a floating-point number or an integer in a range of minimum length 365) ?
The difficulty for me is to find a very simple function. There are many that are for hashing strings, but they could be too time-consuming: it's for a number-crunching program where this function will be called billions of times, so I'm looking for something really simple (and fast :-) ).
TIA
_________________________ 
Gautier's Ada programming 
http://gautiersblog.blogspot.com/search/label/Ada 
NB: follow the above link for a valid e-mail address 


^ permalink raw reply	[flat|nested] 12+ messages in thread

end of thread, other threads:[~2018-08-01  9:08 UTC | newest]

Thread overview: 12+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-07-16  8:20 Simple hash or pseudo-random function gautier_niouzes
2018-07-16 13:34 ` Shark8
2018-07-17  4:44   ` robin.vowels
2018-07-16 14:52 ` Marius Amado-Alves
2018-07-16 20:59   ` gautier_niouzes
2018-07-16 17:17 ` Jeffrey R. Carter
2018-07-16 21:14   ` gautier_niouzes
2018-07-17  6:09     ` Jeffrey R. Carter
2018-07-18 13:38       ` gautier_niouzes
2018-08-01  9:08         ` gautier_niouzes
2018-07-17  0:40 ` Dan'l Miller
2018-07-17  6:44 ` Paul Rubin

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox