login
The OEIS is supported by the many generous donors to the OEIS Foundation.

 

Logo
Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A226545 Number A(n,k) of squares in all tilings of a k X n rectangle using integer-sided square tiles; square array A(n,k), n>=0, k>=0, read by antidiagonals. 12

%I #23 Sep 06 2021 01:44:23

%S 0,0,0,0,1,0,0,2,2,0,0,3,5,3,0,0,4,12,12,4,0,0,5,25,34,25,5,0,0,6,50,

%T 98,98,50,6,0,0,7,96,256,386,256,96,7,0,0,8,180,654,1402,1402,654,180,

%U 8,0,0,9,331,1625,4938,6940,4938,1625,331,9,0

%N Number A(n,k) of squares in all tilings of a k X n rectangle using integer-sided square tiles; square array A(n,k), n>=0, k>=0, read by antidiagonals.

%H Alois P. Heinz, <a href="/A226545/b226545.txt">Antidiagonals n = 0..30, flattened</a>

%e A(3,3) = 1 + 6 + 6 + 6 + 6 + 9 = 34:

%e ._____. ._____. ._____. ._____. ._____. ._____.

%e | | | |_| |_| | |_|_|_| |_|_|_| |_|_|_|

%e | | |___|_| |_|___| |_| | | |_| |_|_|_|

%e |_____| |_|_|_| |_|_|_| |_|___| |___|_| |_|_|_|

%e Square array A(n,k) begins:

%e 0, 0, 0, 0, 0, 0, 0, 0, ...

%e 0, 1, 2, 3, 4, 5, 6, 7, ...

%e 0, 2, 5, 12, 25, 50, 96, 180, ...

%e 0, 3, 12, 34, 98, 256, 654, 1625, ...

%e 0, 4, 25, 98, 386, 1402, 4938, 16936, ...

%e 0, 5, 50, 256, 1402, 6940, 33502, 157279, ...

%e 0, 6, 96, 654, 4938, 33502, 221672, 1426734, ...

%e 0, 7, 180, 1625, 16936, 157279, 1426734, 12582472, ...

%p b:= proc(n, l) option remember; local i, k, s, t;

%p if max(l[])>n then [0,0] elif n=0 or l=[] then [1,0]

%p elif min(l[])>0 then t:=min(l[]); b(n-t, map(h->h-t, l))

%p else for k do if l[k]=0 then break fi od; s:=[0$2];

%p for i from k to nops(l) while l[i]=0 do s:=s+(h->h+[0, h[1]])

%p (b(n, [l[j]$j=1..k-1, 1+i-k$j=k..i, l[j]$j=i+1..nops(l)]))

%p od; s

%p fi

%p end:

%p A:= (n, k)-> `if`(n>=k, b(n, [0$k]), b(k, [0$n]))[2]:

%p seq(seq(A(n, d-n), n=0..d), d=0..14);

%t b[n_, l_List] := b[n, l] = Module[{i, k, s, t}, Which[Max[l] > n, {0, 0}, n == 0 || l == {}, {1, 0}, Min[l] > 0, t=Min[l]; b[n-t, l-t], True, k = Position[l, 0, 1][[1, 1]]; s={0, 0}; For[i=k, i <= Length[l] && l[[i]] == 0, i++, s = s + Function[h, h+{0, h[[1]]}][b[n, Join[l[[1 ;; k-1]], Table[1+i-k, {j, k, i}], l[[i+1 ;; -1]]]]] ]; s]]; a[n_, k_] := If[n >= k, b[n, Array[0&, k]], b[k, Array[0&, n]]][[2]]; Table[Table[a[n, d-n], {n, 0, d}], {d, 0, 14}] // Flatten (* _Jean-François Alcover_, Dec 13 2013, translated from Maple *)

%Y Columns (or rows) k=0-10 give: A000004, A001477, A067331(n-1) for n>0, A226546, A226547, A226548, A226549, A226550, A226551, A226552, A226553.

%Y Main diagonal gives A226554.

%Y Cf. A113881, A219924.

%K nonn,tabl

%O 0,8

%A _Alois P. Heinz_, Jun 10 2013

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recents
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified April 23 18:16 EDT 2024. Contains 371916 sequences. (Running on oeis4.)