# Probability basics - Heads or Tails thought experiment.

1. May 28, 2012

### Izhaki

Right,

This is very confusing for myself, I'm pretty sure it will be so for everyone else.

My question is really related to quantum theory, but I find it most appropriate to spell it out here as it's more of a maths question on the basics of probability.

Here my experiment:

I stand at a point a throw a coin.
If it's heads, I take a step to the right; tails I take a step to the left.
The throw of the coin is completely random, and my steps are precisely the same distance to left and right.
My time axis is 'throws', so after 10 throws t = 10.

Now it doesn't takes a genius to know that probability has it that I'll be close to my origin point most of the time.

But also, if I'm to run this experiment indefinitely, there will come a point where I will be million steps to the left (same way monkeys will type Shakespeare). Say the time when this happened was M.

Can I not tell that if I run the experiment M more times (so at time 2M), I'll back around my origin point again?

But as my chance to go left or right are equal, that makes no sense whatsoever. Because when I'm million steps to the left of my origin, I still have a similar chance going million steps to the right or left. Yet given I started from my original origin point, at any time my mean should be that origin point.

In other words - when I get heads I 'owe' probability a tail. But that's nonsense, as the chance for heads or tails is equal in every throw.

So what am I getting wrong?

Last edited: May 28, 2012
2. May 29, 2012

### Simon Bridge

You have described the 1D Drunkards Walk problem - go look it up. Over time you will more likely wander away from the start point. The intuitive idea that the equal probabilities will keep you close by is simply incorrect.

Basically - once you have taken a step to the right (say) then, by the argument you used, the remaining tosses should keep you close to that point rather than the origin. See the problem?

Very balanced outcomes like HTTHTHHTHTTHHT that keep you close to the start are quite unlikely and quite long runs are more common than you'd guess. In fact it is possible to tell the difference between a sheet of actual coin tosses and a sheet of made-up coin tosses this way - the actual one will have more long runs on heads or tails.

3. May 29, 2012

### mathman

One interesting fact about random walk. In one or two dimensions the probability that eventually you will return to the origin is one. For higher dimensions it is less.

4. May 30, 2012

### Simon Bridge

That is interesting - so if a 1d random walk starts at position x, then, over a long time, it returns to position x? But if it got to x via a random walk from the origin then it will end up at the origin and not x ... how does it know where it started out?

Or is it more that the long runs of heads are as likely as long runs on tails so, given sufficient time, the walk will eventually return to it's starting point. But that does not sound so interesting... after all, given sufficient time surely the walker will end up and any nominated point?

These things can be good fun to simulate.
I first ran into this problem when I was 13 and trying to program a trs80 to run a snail race ... which I had modeled as a 2d random walk I know now. I spent ages trying to work out how long it would take for the "snails" to exit the circle with different parameters.

5. May 30, 2012

### viraltux

Well, here you have to define "close" but the fact is that the more steps you take the more likely to be "further" and "further" away from the origin.

What you can tell is that in the long run #tails/#heads ~ 1, but, for example, 1.trillion.tails / 1.trillion.minus.100.thousand.heads will be also close to one, but yet, you will find yourself 100 thousand steps away from the origin. The thing is that 100 thousands steps is "close" compare to the 1 trillion steps.

The expected value for a random walk is its origin, but its variance is infinite, so the further you go every point becomes more and more alike and that "closeness" can be eventually of billions of steps away from the origin which is still very close compare to a large number of steps.

So I think if you redefine your concept of "close" you will get it.

Last edited: May 30, 2012
6. May 30, 2012

### mathman

Every point will be hit infinitely often.