Lisa the Innumerate called a few minutes ago to ask about affine transformations, so I figure there must be some general interest among my readers for more math. (For the uninitiated an affine transformation in 2D is essentially a particular kind of geometric operation that preserves parallel lines and proportions.)
Jeff Atwood at Coding Horror wrote a pretty good article comparing pseudo-random number generators. So what’s the difference between randomness and merely “pseudo-randomness?” I remember Prof. Goldberg in the Philosophy Department at Grinnell asking me this a decade ago. Naturally, I had no idea. So I went to Knuth.
Simply, a true random sequence is most tersely described by listing the entire sequence. That is, there is no algorithm for producing the next number from any of the preceeding numbers. That kind of randomness has been difficult for both computers and people to approach. (In fact, computer science has the concept of “oracles,” mythical black box operations that give answers in completely inscrutable ways, in order to cope with this kind of difficulty.)
Pseudo-randomness, uses an algorithm to produce a set of numbers that appears random — but of course it can’t be because it’s generated by a rule. If you know a small number of the beginning numbers and the algorithm itself, you can determine all of the rest of the numbers. (In which case you can always beat the computer at rock-paper-scissors or break codes or whatever.) A good pseudo-random number generator has two very important parts: (1) an algorithm capable of producing a large set of nonrepeating numbers, and (2) a seed generator that picks the initial values for the algorithm. Without a good seed the algorithm produces the same numbers over and over.
Seed generation is often quite clever and interesting. All good magic tricks oracles are.




No user commented in " Pseudo-randomness "
Follow-up comment rss or Leave a TrackbackLeave A Reply