OFFSET
0,1
COMMENTS
Unlike the first quadrant diagonal numbering of A316588 which has infinite paths when starting from certain squares (see A307422), it appears that in this variation all paths are finite. This was confirmed by checking all the paths for starting squares up to one million, and noting the subsequent largest visited square on these paths after the first time a step was taken to a larger square than the previous square. This removes the initial very long inward trajectory the knight takes toward the origin when starting from large starting square numbers. These data show that the largest visited square for all paths, ignoring the initial inward trajectory, is 791. As paths with starting squares up to one million easily cover all possible inward trajectories to squares one unit further from the origin than 791, this shows all paths are finite.
For large n (>10000) the last square appears to always be one of the set of nine squares: 24, 25, 35, 48, 63, 143, 168, 224, 528; 168 being the most common followed by 24 and 25. The set of all last squares when starting from any square is the set of twenty-nine squares: 15, 16, 24, 25, 35, 48, 63, 79, 80, 81, 99, 100, 120, 143, 168, 195, 224, 255, 288, 323, 324, 360, 399, 400, 440, 483, 528, 575, 675. Of those 79, 100, 323, 400, 440, 575, 675 can each only be reached by starting from one particular square.
The largest last square number is 675, which can only be reached by starting from square 413, while the smallest last square number is 15, which can only be reached by starting from squares 18, 34, or 63. See the attached images.
The only last square reachable that is not next to the very edge of the quadrant is 79, which can only be reached by starting from square 48. See the attached image.
LINKS
Scott R. Shannon, Table of n, a(n) for n = 0..10000
Scott R. Shannon, The knight's path for a(34) = 15. In this and other images the starting square is green, the last square is red, and the squares surrounding the last square that block the knight are surrounded by blue.
Scott R. Shannon, The knight's path for a(413) = 675.
Scott R. Shannon, The knight's path for a(48) = 79.
EXAMPLE
a(34) = 15 as when starting at square 34 the complete knight's path is 34 -> 13 -> 2 -> 9 -> 6 -> 1 -> 4 -> 7 -> 0 -> 5 -> 8 -> 3 -> 14 -> 11 -> 18 -> 15, and the sequence ends as from square 15 all available squares have been previously visited. See the attached image.
CROSSREFS
KEYWORD
nonn,walk
AUTHOR
Scott R. Shannon, Feb 15 2026
STATUS
approved
