cp's OEIS Frontend

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.

A322495 Number of tilings of an n X n square using V (2m+1)-ominoes (m >= 0) in standard orientation.

This page as a plain text file.
%I A322495 #14 Apr 22 2021 08:48:36
%S A322495 1,1,2,8,68,1262,51420,4577274,888837716,376116199534,346688563051200,
%T A322495 695975307003529228
%N A322495 Number of tilings of an n X n square using V (2m+1)-ominoes (m >= 0) in standard orientation.
%C A322495 The shapes of the tiles are:
%C A322495                        ._.
%C A322495               ._.      | |
%C A322495        ._.    | |      | |
%C A322495   ._.  | |_.  | |_._.  | |_._._.
%C A322495   |_|  |___|  |_____|  |_______|  ... .
%H A322495 Wikipedia, <a href="https://en.wikipedia.org/wiki/Polyomino">Polyomino</a>
%e A322495 a(3) = 8:
%e A322495   ._____.  ._____.  ._____.  ._____.  ._____.  ._____.  ._____.  ._____.
%e A322495   |_|_|_|  | |_|_|  |_|_|_|  |_| |_|  |_|_|_|  |_| |_|  | |_|_|  | | |_|
%e A322495   |_|_|_|  |___|_|  | |_|_|  |_|___|  |_| |_|  | |___|  | |_|_|  | |___|
%e A322495   |_|_|_|  |_|_|_|  |___|_|  |_|_|_|  |_|___|  |___|_|  |_____|  |_____|.
%e A322495 .
%p A322495 b:= proc(n, l) option remember; local k, m, r;
%p A322495       if n=0 or l=[] then 1
%p A322495     elif min(l)>0 then (t-> b(n-t, map(h->h-t, l)))(min(l))
%p A322495     elif l[-1]=n then b(n, subsop(-1=[][], l))
%p A322495     else for k while l[k]>0 do od; r:= 0;
%p A322495          for m from 0 while k+m<=nops(l) and l[k+m]=0 and n>m do
%p A322495            r:= r+b(n, [l[1..k-1][], 1$m, m+1, l[k+m+1..nops(l)][]])
%p A322495          od; r
%p A322495       fi
%p A322495     end:
%p A322495 a:= n-> b(n, [0$n]):
%p A322495 seq(a(n), n=0..9);
%t A322495 b[n_, l_] := b[n, l] = Module[{k, m, r}, Which[n == 0 || l == {}, 1, Min[l] > 0, Function[t, b[n-t, l-t]][Min[l]], l[[-1]] == n, b[n, ReplacePart[l, -1 -> Nothing]], True, For[k = 1, l[[k]] > 0, k++]; r = 0; For[m = 0, k + m <= Length[l] && l[[k+m]] == 0 && n > m, m++, r = r + b[n, Join[l[[1 ;; k-1]], Array[1&, m], {m+1}, l[[k+m+1 ;; Length[l]]]]]]; r]];
%t A322495 a[n_] := b[n, Array[0&, n]];
%t A322495 a /@ Range[0, 9] (* _Jean-François Alcover_, Apr 22 2021, after _Alois P. Heinz_ *)
%Y A322495 Main diagonal of A322494.
%K A322495 nonn,more
%O A322495 0,3
%A A322495 _Alois P. Heinz_, Dec 12 2018