This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.
%I A333580 #27 Jan 31 2022 15:51:21 %S A333580 1,1,1,1,0,1,1,1,1,1,1,0,2,0,1,1,1,4,4,1,1,1,0,8,0,8,0,1,1,1,16,20,20, %T A333580 16,1,1,1,0,32,0,104,0,32,0,1,1,1,64,111,378,378,111,64,1,1,1,0,128,0, %U A333580 1670,0,1670,0,128,0,1,1,1,256,624,6706,10204,10204,6706,624,256,1,1 %N A333580 Square array T(n,k), n >= 1, k >= 1, read by antidiagonals, where T(n,k) is the number of Hamiltonian paths in an n X k grid starting at the lower left corner and finishing in the upper right corner. %H A333580 Andrew Howroyd, <a href="/A333580/b333580.txt">Table of n, a(n) for n = 1..378</a> %H A333580 <a href="/index/Gra#graphs">Index entries for sequences related to graphs, Hamiltonian</a> %F A333580 T(n,k) = T(k,n). %e A333580 Square array T(n,k) begins: %e A333580 1, 1, 1, 1, 1, 1, 1, 1, ... %e A333580 1, 0, 1, 0, 1, 0, 1, 0, ... %e A333580 1, 1, 2, 4, 8, 16, 32, 64, ... %e A333580 1, 0, 4, 0, 20, 0, 111, 0, ... %e A333580 1, 1, 8, 20, 104, 378, 1670, 6706, ... %e A333580 1, 0, 16, 0, 378, 0, 10204, 0, ... %e A333580 1, 1, 32, 111, 1670, 10204, 111712, 851073, ... %e A333580 1, 0, 64, 0, 6706, 0, 851073, 0, ... %o A333580 (Python) %o A333580 # Using graphillion %o A333580 from graphillion import GraphSet %o A333580 import graphillion.tutorial as tl %o A333580 def A333580(n, k): %o A333580 if n == 1 or k == 1: return 1 %o A333580 universe = tl.grid(n - 1, k - 1) %o A333580 GraphSet.set_universe(universe) %o A333580 start, goal = 1, k * n %o A333580 paths = GraphSet.paths(start, goal, is_hamilton=True) %o A333580 return paths.len() %o A333580 print([A333580(j + 1, i - j + 1) for i in range(12) for j in range(i + 1)]) %Y A333580 Rows n=1..10 (with 0 omitted) give: A000012, A000035, A011782(n-1), A014523, A014584, A333581, A333582, A333583, A333584, A333585. %Y A333580 T(2*n-1,2*n-1) gives A001184(n-1). %Y A333580 Cf. A271592. %K A333580 nonn,tabl %O A333580 1,13 %A A333580 _Seiichi Manyama_, Mar 27 2020