| |||||||||||||||||||||||||||||||||||||||||||||
It is also worthwhile to see how long it takes to form such a tower. Such a tower may (when first formed) be on pin 2: let the minimal number of moves to reach this situation be Bn. Let the minimal number of moves to reach the other such situation (the tower on top of a stack on pin 1 or 2) be An. By induction on n, you may obtain:
Finally, cosider the final two layers together with the tower above them. It is necessary to swap the bases, get the next two the right way around, and do this moving the tower as little as possible. The best solution (8 tower moves, 11 other moves) also saves a little time by finishing with the tower in position A, since Ak is in general less than Bk. The sequence, starting with the tower on place 0 and considering the tower as a single object, is: 12.02.01.20.21.01.02.10.12.12.02.10.21.20.20.10.21.02.01 Handily, now that the bottom two layers are right there is no more need to worry: The other layers may be arranged as we wish. So the least number of moves for towers with n disks is Ln, satisfying Ln = An-2 + Bn-2 + 8·Tn-2 + 11. That is:
These two are the same: Lk = 11·(2k-1 - 1) - 3(k-2) for k sufficiently large. Of course, for n <= 2 the values are different: L0 = 0, L1 = 3, L2 = 10. However, it suggests there is a nicer way to get the formula, but I don't know it. It gives an answer of 11·3 - 3 = 30 for k = 3 and the string is Is that right? Anyway, if you generalised the problem any more it would be hard to get exact values, just upper and lower bounds.
|
| ||||||||||||||||||||||||||||||||||||||||||||