07-07-2017, 05:36 AM
Voted
The square root of the number of winnable lines in a 3 by 3 by 3 nought and crosses (tic tac toe) game (i.e. number of ways to get 3 Xs in a row on cube grid, diagonals allowed). You can do it without counting the lines.
[spoiler]7
This one is pretty cool, so I'm going to generalise it. Suppose you've got a grid of n dimensions and side length k (picture it as a cube or square if it makes it easier for you). Now, surround that grid with an outer layer that's 1 cell thick (so you've now got a new grid with a side length of k+2). Each winnable line in the original grid will go through a distinct pair of cells in the outer layer that was just added. So the number of winnable lines is therefore [(k+2)^n - k^n]/2.
Specifically to the cube case in the question: surround that 3x3x3 grid with a layer of cells that is 1 thick. So now you've got a 5x5x5 grid. Each line in the 3x3x3 grid will go through a distinct pair of cells (one on each side of the new outer layer). So, that would equal (5^3 - 3^3)/2 lines. Which give 49. The square root of 49 is 7.
Pretty cool right? I have a super complicated proof for it as well. And a less complicated one. But I figured the geometric/visual one was probably best for you guys. I spend like half a year of my life dicking about with noughts and crosses so I'm damn well subjecting you guys to it.[/spoiler]
The square root of the number of winnable lines in a 3 by 3 by 3 nought and crosses (tic tac toe) game (i.e. number of ways to get 3 Xs in a row on cube grid, diagonals allowed). You can do it without counting the lines.
[spoiler]7
This one is pretty cool, so I'm going to generalise it. Suppose you've got a grid of n dimensions and side length k (picture it as a cube or square if it makes it easier for you). Now, surround that grid with an outer layer that's 1 cell thick (so you've now got a new grid with a side length of k+2). Each winnable line in the original grid will go through a distinct pair of cells in the outer layer that was just added. So the number of winnable lines is therefore [(k+2)^n - k^n]/2.
Specifically to the cube case in the question: surround that 3x3x3 grid with a layer of cells that is 1 thick. So now you've got a 5x5x5 grid. Each line in the 3x3x3 grid will go through a distinct pair of cells (one on each side of the new outer layer). So, that would equal (5^3 - 3^3)/2 lines. Which give 49. The square root of 49 is 7.
Pretty cool right? I have a super complicated proof for it as well. And a less complicated one. But I figured the geometric/visual one was probably best for you guys. I spend like half a year of my life dicking about with noughts and crosses so I'm damn well subjecting you guys to it.[/spoiler]