Note: There are errors here, see revised article for corrected analysis.

The same approach as was used for the 5x5 torus can apply to other tori. For each possible offset between the termini, count up the number of distinct neighbors and the number of neighbor clusters. Their sum is a lower limit on the minimal number of moves for a non-extendable path. If a cluster doesn’t have a Hamiltonian path, though, extra moves are needed; likewise if a single intermediate position isn’t enough to get from one cluster to another. In the 5x5 case with a knight’s move offset there are 11 neighbors and two clusters with Hamiltonian paths, so the limit is 13 moves (14 positions), and paths of that length do exist.

For the 6x6 torus it’s a little complicated. The optimum offset appears to be a knight’s move: There are 14 neighbors all in a single cluster, for a 15 move minimum. But on examination the cluster does not have a Hamiltonian path. I think three extra moves are needed.

Meanwhile the apparent second best offset is (3, 3). With this offset every neighbor of the start position is also a neighbor of the end position and vice versa! There are therefore only 8 distinct neighbors. Each is a singleton cluster so the lower limit on the path length with that offset is 16. But singleton clusters do have Hamiltonian paths (ha ha) and you can link all 8 using 7 intermediate positions, ending up with a 16-move, 17-position path:

For 7x7, the optimum offset turns out to be (3, 2). That gives 15 neighbors in 4 clusters, for a lower limit of 19 moves or 20 positions… and behold, that’s possible.

Here’s 8x8. We’re back to a knight’s move offset. 14 neighbors and 5 clusters, so a 19 move minimum again, but one cluster isn’t Hamiltonian so an extra move is needed, and then another by a parity coloring argument. That means 22 positions is minimal, and here is one example:

9x9 is interesting! There are three optimal offsets. (4, 0) gives 14 neighbors and 8 clusters (two 4-clusters and 6 singletons), summing to 22 moves. The other two are (1, 0) and (2, 1), resulting in the same neighbors and clusters as in the infinite plane case. They also sum to 22 moves.

On the infinite plane, coloring says there must be an odd number of moves, so 22 bumps up to 23. However, 9x9 has odd diameters, so cannot be globally 2-colored; the coloring argument doesn’t work. In fact, by wrapping around the torus, you can connect everything up with 22 moves, 23 positions. Here’s a path using the (4, 0) offset:

On the 10x10 torus the best offset is (5, 0). 16 neighbors in 4 clusters for a sum of 20, but by coloring the number of moves must be odd, hence 21, and that is possible:

For a torus 11x11 or larger, the situation is similar to 9x9, though with only (1,0) and (2,1) offsets being optimal. Even sizes are subject to the same coloring argument as the infinite plane, so the shortest paths are 24 positions. Odd sizes do not have global 2-colorings, but unlike in the 9x9 case, I think 11x11 and larger allow local 2-coloring in a large enough area to make the same argument apply. Basically I don’t think you can connect neighbors by wrapping around the torus in few enough moves to get an advantage. So I’m fairly sure 24 positions is the minimum for all tori 11x11 or larger.

Summarizing, it appears we have these minimum paths:

Torus size Min positions # solutions
1x1 1 1
2x2 4 1
3x3 8 32
4x4 10 24
5x5 14 ?
6x6 17 ?
7x7 20 ?
8x8 22 ?
9x9 23 ?
10x10 22 ?
11x11+ 24 ?

<– 2023-08-07_nonextendable-knights-paths-part-32023-11-09_prime-time –>