Unexpected Snakes and Ladders

Your beloved friend Zack has designed you a special variant of snakes and ladders board game which, ironically, has no snakes and ladders! How lovely!

Game rules:

  • You start from square number 1, your goal is to reach square number 100 by advancing through squares 2 to 99

  • In each "move", you roll a conveniently designed fair 6-sided dice which has numbers 1 1 , 1 1 , 2 2 , 2 2 , 3 3 , 3 3 on it and advance your token forwards by the same number of squares as indicated by your dice

  • You do not need to roll the exact number to reach the final square, for example, if you are on square 99 and you roll a 3, you still win the game

  • Zack didn't bother to put any snakes or ladders, so there's no climbing up or sliding down

  • No magic teleportation!

What is the expected number of moves needed (correct to 5 significant digits) in order for you to win the game?


The answer is 49.833.

This section requires Javascript.
You are seeing this because something didn't load right. We suggest you, (a) try refreshing the page, (b) enabling javascript if it is disabled on your browser and, finally, (c) loading the non-javascript version of this page . We're sorry about the hassle.

1 solution

Kenneth Tan
Jun 26, 2018

Suppose E n E_n is the expected number of moves required to reach square number 1 + n 1+n from square number 1, our goal is to find E 99 E_{99} .

Note that the starting square is arbitrary here, so this is exactly equivalent to saying that E n E_n is the expected number of moves required to advance at least n n squares.

First and foremost, let's look at some trivial values:

  • E 0 = 0 E_0=0 , we don't need to do anything to advance 0 squares, we are already at the target square!

  • E 1 = 0 E_{-1}=0 , we already went past the target square (it is 1 square behind us), again we don't need to do anything (we define this as this will become useful later on).

  • E 1 = 1 E_1=1 , no matter what number we roll, we will always advance at least 1 square, the expected number of moves to advance at least 1 square is 1.


Awesome, now that's out of the way, let's think about E n E_n , in order to advance at least n n squares, you must either:

  • Roll a 1 1 , taking a move, and advance at least n 1 n-1 more squares

  • Roll a 2 2 , taking a move, and advance at least n 2 n-2 more squares

  • Roll a 3 3 , taking a move, and advance at least n 3 n-3 more squares

Since the probabilities of rolling each number are equal ( = 1 3 =\frac{1}{3} ), we thus have, for n 2 n\geqslant2 , E n = 1 3 ( 1 + E n 1 ) + 1 3 ( 1 + E n 2 ) + 1 3 ( 1 + E n 3 ) E_n=\frac{1}{3}(1+E_{n-1})+\frac{1}{3}(1+E_{n-2})+\frac{1}{3}(1+E_{n-3})\text{ } 3 E n = E n 1 + E n 2 + E n 3 + 3 (1) \therefore 3E_n=E_{n-1}+E_{n-2}+E_{n-3}+3\tag{1}

Shift n n by 1: 3 E n + 1 = E n + E n 1 + E n 2 + 3 (2) 3E_{n+1}=E_{n}+E_{n-1}+E_{n-2}+3\tag{2}

( 2 ) ( 1 ) 3 E n + 1 3 E n = E n E n 3 (2)-(1)\implies 3E_{n+1}-3E_n=E_n-E_{n-3}

3 E n + 1 = 4 E n E n 3 \therefore 3E_{n+1}=4E_n-E_{n-3}

This is a fourth order linear recurrence relation, its characteristic polynomial is 3 r 4 4 r 3 + 1 = ( r 1 ) 2 ( 3 r 2 + 2 r + 1 ) 3r^4-4r^3+1=(r-1)^2(3r^2+2r+1) ( look up how to solve linear recurrence relations here ), equating this to 0 and solving this polynomial would yield roots 1 1 (repeated) and 1 3 ± 2 3 i = 1 3 e ± i θ -\frac{1}{3}\pm\frac{\sqrt2}{3}i=\frac{1}{\sqrt3}e^{\pm i\theta} , where θ = π tan 1 2 \theta=\pi-\tan^{-1}\sqrt2 , hence a solution to this recurrence relation is in the form E n = ( 1 3 ) n ( c 1 cos n θ + c 2 sin n θ ) + ( c 3 + c 4 n ) ( 1 ) n E_n=\left(\frac{1}{\sqrt3}\right)^n(c_1\cos n\theta+c_2\sin n\theta)+(c_3+c_4n)(1)^n

Using ( 1 ) (1) to derive E 2 E_2 by plugging n = 2 n=2 , we get E 2 = 4 3 E_2=\frac{4}{3} .

Now with the initial conditions E 1 = E 0 = 0 E_{-1}=E_0=0 , E 1 = 1 E_1=1 , E 2 = 4 3 E_2=\frac{4}{3} , we can solve for c 1 c_1 , c 2 c_2 , c 3 c_3 and c 4 c_4 . After plugging in n = 1 , 0 , 1 , 2 n=-1, 0, 1, 2 , we will get the following system of equations:

{ 3 ( c 1 cos θ c 2 sin θ ) + c 3 c 4 = 0 c 1 + c 3 = 0 1 3 ( c 1 cos θ + c 2 sin θ ) + c 3 + c 4 = 1 1 3 ( c 1 cos 2 θ + c 2 sin 2 θ ) + c 3 + 2 c 4 = 4 3 \begin{cases} \sqrt3(c_1\cos\theta-c_2\sin\theta)+c_3-c_4=0 \\ c_1+c_3=0 \\ \frac{1}{\sqrt3}(c_1\cos\theta+c_2\sin\theta)+c_3+c_4=1 \\ \frac{1}{3}(c_1\cos2\theta+c_2\sin2\theta)+c_3+2c_4=\frac{4}{3}\end{cases}

Where, cos θ = cos ( π tan 1 2 ) = 1 3 , sin θ = sin ( π tan 1 2 ) = 2 3 , cos 2 θ = 2 cos 2 θ 1 = 1 3 , sin 2 θ = 2 sin θ cos θ = 2 2 3 \cos\theta=\cos(\pi-\tan^{-1}\sqrt2)=-\frac{1}{\sqrt3},\text{ }\sin\theta=\sin(\pi-\tan^{-1}\sqrt2)=\sqrt{\frac{2}{3}},\text{ }\cos2\theta=2\cos^2\theta-1=-\frac{1}{3},\text{ } \sin2\theta=2\sin\theta\cos\theta=-\frac{2\sqrt2}{3} .

Solving the system of equations above, we have c 1 = 1 3 c_1=-\frac13 , c 2 = 1 6 2 c_2=\frac1{6\sqrt2} , c 3 = 1 3 c_3=\frac13 , c 4 = 1 2 c_4=\frac12 .

E n = ( 1 3 ) n ( 1 3 cos n θ + 1 6 2 sin n θ ) + 1 3 + 1 2 n \therefore E_n=\left(\frac1{\sqrt3}\right)^n\left(-\frac13\cos n\theta+\frac1{6\sqrt2}\sin n\theta\right)+\frac13+\frac12n

Finally, to find E 99 E_{99} , all we need to do now is to set n = 99 n=99 and it would give E 99 49.833 E_{99}\approx49.833 .

0 pending reports

×

Problem Loading...

Note Loading...

Set Loading...