Hacker News new | ask | show | jobs
by susam 1843 days ago
It is not possible to randomly select an integer from the set of integers (a countably infinite set) with uniform distribution. The reason is that there is no uniform probability distribution on the set of integers. So how do we correctly express what you have intuitively arrived at? (By the way, the note that the result you have arrived at is incorrect but we will get to that later.)

Define set A = {x : x ∈ ℤ and -n <= x < n}. Now it is possible to define a uniform probability distribution over this set A. Let the probability of any integer chosen from this set be 1/(2n). The set A has n even integers and n odd integers. Let a and b two integers chosen randomly from this set. The probability of a being even is 0.5, i.e., P(a is even) = 0.5. Likewise for b, i.e., P(b is even) = 0.5.

Now a + b is even if and only if either a and b are both even or a and b are both odd. The probability that a and b are both even is P(a is even) * P(b is even) = 0.5 * 0.5 = 0.25. Similarly, the probability that a and b are both odd is P(a is odd) * P(b is odd) = 0.5 * 0.5 = 0.25. Thus, the probability that a + b is even is P((a + b) is even) = 0.25 + 0.25 = 0.5.

Since the result does not depend on the value of n, we can now claim that lim nā†’āˆž P((a + b) is even) = 0.5.

1 comments

Case 4 should be P(b is even)