%I #33 Nov 03 2024 02:02:46
%S 1,4,14,3,11,2,8,22,7,19,5,15,33,13,29,12,28,10,24,9,23,45,21,41,20,6,
%T 18,38,17,35,16,34,60,32,58,31,55,30,54,86,52,26,48,25,47,77,46,76,44,
%U 74,43,71,42,70,40,68,39,67,37,63,36,62,96,61,95,59,93
%N Squares visited by a king moving on a walled, spirally numbered board, where a wall must be jumped on each move, always to the lowest available unvisited square.
%C Board is numbered with the walled, square spiral:
%C .
%C 17 16 15 14 13 | .
%C ------------- | .
%C 18 | 5 4 3 |12 | .
%C | ----- | | .
%C 19 | 6 | 1 2 |11 | .
%C | --------- | .
%C 20 | 7 8 9 10 | .
%C ----------------- .
%C 21 22 23 24 25 26
%C .
%C Walls mark off the path of the spiral.
%C A king move must go through a wall when drawing a line between the center of the start and end square. Note that some moves touch a wall but do not pass through a wall (e.g. 1 to 3), these are not permissible.
%C Due to the wall rule, the next term cannot be +/-1 or +/-2.
%H Sameer Khan, <a href="/A375925/b375925.txt">Table of n, a(n) for n = 1..100</a>
%H Kevin Ryde, <a href="/A375925/a375925_1.pdf">Path Plot</a>
%e For n = 2, a(n) = 4 because moving to 2 or 3 does not pass through a wall.
%Y Cf. A033638, A316667 (trapped knight), A336038 (trapped king).
%K nonn
%O 1,2
%A _Sameer Khan_, Sep 03 2024