Propability of getting dice values difference equal 1 or 5

$\begingroup$

We toss the dice until we get the same value twice in a row. What is the probability that in some two tosses, the difference between next and previous value divided by $6$ gives the reminder $1$ or $5$?

So I know that probability of getting the same value twice in a row is $\frac1 6$. And two tosses should look like $(1,6),(5,6),(4,5),(3,4),(2,3),(1,2)$How can I calculate the probability of this situation now?

$\endgroup$

1 Answer

$\begingroup$

We can think as follows. The results of a first toss are $1,2,3,4,5,6$, but for the purpose of the problem, let us better use these values in the ring $\Bbb Z/6$, so they are $1,2,3,4,5,0$ modulo six, ok, the better order is $0,1,2,3,4,5$ (modulo six, and from now on we work only modulo six with such values).

Without loss of generality, we can and do restrict to the case where the first toss is $0$. (Since we work modulo six.)

Now we consider the following ramifications:

 0 LOSE /
0-1,5 WIN \ 2,3,4 GO ON

So we win at first step with probability $1/3$, stop and lose with probability $1/6$, and continue in the other $1/2$ cases. Now, if we go on, we can "rescale the further values" as we did at the beginning, and the same scheme repeats itself. The win probability $p$ is thus:

$$ \begin{aligned} p &=\frac 13 +\frac 12\cdot \frac 13 +\left(\frac 12\right)^2\cdot \frac 13 +\left(\frac 12\right)^3\cdot \frac 13 +\dots \\ &=\frac 13\cdot \frac 1{1-\frac 12} \\ &=\frac 23\ . \end{aligned} $$


In such cases i always write the simulation, here using sage:

import random
R = Zmod(6)
L = list( R ) # the list 0,1,2,3,4,5 mod 6
N = 10**6 # trials
success = 0 # counter
for trial in xrange(N): a, b = random.choice( L ), random.choice( L ) while (a-b) not in (R(0), R(1), R(5)): a, b = b, random.choice( L ) if a != b: success += 1
print "Winning rate (experimental) = %s / %s ~ %f" % (success, N, success/N)

And this time i've got:

Winning rate (experimental) = 666256 / 1000000 ~ 0.666256
$\endgroup$ 1

Your Answer

Sign up or log in

Sign up using Google Sign up using Facebook Sign up using Email and Password

Post as a guest

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

You Might Also Like