Why not? If the PRNG is at all reasonable then getting the same number twice in a row is not only valid, but should happen reasonably often. A generator that never emits the same number twice in a row is not even close to random. A homogenous distribution does not imply that you can't have the same number twice running.Oidche said:I know.
I meant that if you set up a PRNG, number N and number N+1 will never be the same. Ofcourse this depends on the implementation, but most PRGNs give a pretty homogenous distribution of values.
Consider if you are generating integers in the range [1,2]. If the generator never emits the same number twice in a row you'd get 1, 2, 1, 2, ... which is clearly not random in the least. Thinks it's a meaningless example? What if you're simulating flipping a coin, or deciding between two alternatives, it happens all the time.