Dismiss Notice
Join Physics Forums Today!
The friendliest, high quality science and math community on the planet! Everyone who loves science is here!

Randomness of Computer & Calculator

  1. Jul 28, 2004 #1
    Here's the question, what should u do to check whether the randomness of number given uot by computer is indeed random?
  2. jcsd
  3. Jul 28, 2004 #2

    matt grime

    User Avatar
    Science Advisor
    Homework Helper

    there's no such thing as a genuinely random number in this sense. or at least that's my two penn'th. isn't there some quote about if you want a random number generator then you'd better make sure that the numbers aren't picked "randomly"?

    you could hypothesis test a sample, say on the assumption they are uniformly chosen from the interval [0,1] i suppose, though why is this in calculus?
  4. Jul 28, 2004 #3


    User Avatar
    Science Advisor
    Homework Helper

    Digital computers are deterministic. Consequently, the typical answer is that people use pseudo-random number generators. There is actually a good bit of theory that goes into them. Knuth is (as usual) excellent on this topic. I think it's volume two of the art of programming and covers designing and test PRNG algorithms.

    Quantum physics suggests that there are techniques, for example certain types of two slit experiments, that generate truly random numbers.
  5. Jul 28, 2004 #4


    User Avatar
    Staff Emeritus
    Science Advisor

    There is no way to say if A number given by a random number generator is "random". There exist ways to determine the "randomness" of a sequence of random numbers.
  6. Jul 28, 2004 #5
    What I do to get rid of the pseudo-randomness as much as possible is this...
    When writing a program or whatever, I'll make several loops that randomly generate a seed value for my random number generator, then generate the number. After looping this 100 times, I've at least arrived at a number that is more random than a pseudo random, but still isn't perfectly random..

    hmm.. what's that called when you have a phrase like "pretty ugly"? that "perfectly random" kinda seems that way.
  7. Jul 29, 2004 #6

    So, what is the ways to determine the randomness of a sequence of random numbers?
  8. Jul 30, 2004 #7


    User Avatar
    Staff Emeritus
    Science Advisor

    I was afraid you'd ask that! It's been a long time since I have studied that. Here is a website that has a number of references:
  9. Jul 30, 2004 #8
    There are some random number generators that attempt to generate numbers not from some prescribed formula, but by using noise coming from computer parts (like the sound card). I don't know the specifics, but you can imagine that would be comparably better. If you browse around the web, you might find some source files that would let you get a hold of those kind of numbers inside a program.
Know someone interested in this topic? Share this thread via Reddit, Google+, Twitter, or Facebook

Have something to add?

Similar Discussions: Randomness of Computer & Calculator
  1. Make the method random (Replies: 5)

  2. Random taylor series (Replies: 1)