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.

Showing 1-7 of 7 results.

A219866 Number A(n,k) of tilings of a k X n rectangle using dominoes and straight (3 X 1) trominoes; square array A(n,k), n>=0, k>=0, read by antidiagonals.

Original entry on oeis.org

1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 1, 2, 1, 1, 1, 1, 4, 4, 1, 1, 1, 2, 7, 14, 7, 2, 1, 1, 2, 15, 41, 41, 15, 2, 1, 1, 3, 30, 143, 184, 143, 30, 3, 1, 1, 4, 60, 472, 1069, 1069, 472, 60, 4, 1, 1, 5, 123, 1562, 5624, 9612, 5624, 1562, 123, 5, 1
Offset: 0

Views

Author

Alois P. Heinz, Nov 30 2012

Keywords

Examples

			A(2,3) = A(3,2) = 4, because there are 4 tilings of a 3 X 2 rectangle using dominoes and straight (3 X 1) trominoes:
  .___.   .___.   .___.   .___.
  | | |   |___|   | | |   |___|
  | | |   |___|   |_|_|   | | |
  |_|_|   |___|   |___|   |_|_|
Square array A(n,k) begins:
  1,  1,  1,    1,     1,      1,        1,         1, ...
  1,  0,  1,    1,     1,      2,        2,         3, ...
  1,  1,  2,    4,     7,     15,       30,        60, ...
  1,  1,  4,   14,    41,    143,      472,      1562, ...
  1,  1,  7,   41,   184,   1069,     5624,     29907, ...
  1,  2, 15,  143,  1069,   9612,    82634,    707903, ...
  1,  2, 30,  472,  5624,  82634,  1143834,  15859323, ...
  1,  3, 60, 1562, 29907, 707903, 15859323, 354859954, ...
		

Crossrefs

Columns (or rows) k=0-10 give: A000012, A000931(n+3), A129682, A219867, A219862, A219868, A219869, A219870, A219871, A219872, A219873.
Main diagonal gives: A219874.

Programs

  • Maple
    b:= proc(n, l) option remember; local k, t;
          if max(l[])>n then 0 elif n=0 or l=[] then 1
        elif min(l[])>0 then t:=min(l[]); b(n-t, map(h->h-t, l))
        else for k do if l[k]=0 then break fi od;
             b(n, subsop(k=3, l))+ b(n, subsop(k=2, l))+
             `if`(k `if`(n>=k, b(n, [0$k]), b(k, [0$n])):
    seq(seq(A(n, d-n), n=0..d), d=0..10);
  • Mathematica
    b[n_, l_] := b[n, l] = Module[{k, t}, If [Max[l] > n, 0, If[ n == 0 || l == {}, 1, If[Min[l] > 0, t = Min[l]; b[n-t, l-t], k = Position[l, 0, 1][[1, 1]]; b[n, ReplacePart[l, k -> 3]] + b[n, ReplacePart[l, k -> 2]] + If[k < Length[l] && l[[k+1]] == 0, b[n, ReplacePart[l, {k -> 1, k+1 -> 1}]], 0] + If[k+1 < Length[l] && l[[k+1]] == 0 && l[[k+2]] == 0, b[n, ReplacePart[l, {k -> 1, k+1 -> 1, k+2 -> 1}]], 0]]]]]; a[n_, k_] := If[n >= k, b[n, Array[0&, k]], b[k, Array[0&, n]]]; Table[Table[a[n, d-n], {n, 0, d}], {d, 0, 10}] // Flatten (* Jean-François Alcover, Dec 16 2013, translated from Maple *)

A233313 Number of tilings of a 2 X 3 X n box using bricks of shape 3 X 1 X 1 and 2 X 1 X 1.

Original entry on oeis.org

1, 4, 45, 717, 9787, 148414, 2282036, 34688229, 530613082, 8119995275, 124183342755, 1899899589557, 29066650643742, 444678773140018, 6803102237763707, 104079849391557116, 1592303310404361651, 24360457647669398381, 372687643806340329749, 5701702230014416236396
Offset: 0

Views

Author

Alois P. Heinz, Dec 07 2013

Keywords

Examples

			a(1) = A219866(3,2) = A129682(3) = A219866(2,3) = A219867(2) = 4:
._____.  ._____.  ._____.  ._____.
|_____|  | | | |  |___| |  | |___|
|_____|  |_|_|_|  |___|_|  |_|___|.
		

Crossrefs

Programs

  • Maple
    s:= subsop:
    b:= proc(n, l) option remember; local k, t; t:= min(l[]);
          if n=0 then 1 elif t>0 then b(n-t, map(h->h-t, l))
        else for k while l[k]>0 do od; add(`if`(n>=j,
             b(n, s(k=j, l)), 0), j=2..3)+ `if`(k<=4 and l[k+2]=0,
             b(n, s(k=1, k+2=1, l))+ `if`(k<=2 and l[k+4]=0,
             b(n, s(k=1, k+2=1, k+4=1, l)), 0), 0)+ `if`(
             irem(k, 2)>0 and l[k+1]=0, b(n, s(k=1, k+1=1, l)), 0)
          fi
        end:
    a:=n-> b(n, [0$6]):
    seq(a(n), n=0..25);
  • Mathematica
    b[n_, l_] := b[n, l] = Module[{k, t}, t = Min[l]; If [n == 0, 1, If[t > 0, b[n-t, l-t], k = 1; While[l[[k]] > 0 , k++]; Sum[If[n >= j, b[n, ReplacePart[l, k -> j]], 0], {j, 2, 3}] + If[k <= 4 && l[[k+2]] == 0, b[n, ReplacePart[l, {k -> 1, k+2 -> 1}]] + If[k <= 2 && l[[k+4]] == 0, b[n, ReplacePart[l, {k -> 1, k+2 -> 1, k+4 -> 1}]], 0], 0] + If[Mod[k, 2] > 0 && l[[k+1]] == 0, b[n, ReplacePart[l, {k -> 1, k+1 -> 1}]], 0] ] ] ]; a[n_] := b[n, Array[0&, 6]]; Table[a[n], {n, 0, 25}] (* Jean-François Alcover, Dec 16 2013, translated from Maple *)

A233505 Number of tilings of a 2 X 2 X n box using bricks of shape 3 X 1 X 1 and 2 X 1 X 1.

Original entry on oeis.org

1, 2, 9, 45, 201, 1062, 5564, 28859, 152012, 799387, 4202165, 22117465, 116385352, 612443308, 3223118545, 16961953022, 89264218645, 469766599585, 2472212575433, 13010374123502, 68468999197712, 360328057238019, 1896278913278432, 9979444454056631
Offset: 0

Views

Author

Alois P. Heinz, Dec 11 2013

Keywords

Crossrefs

Programs

  • Maple
    a:= n-> coeff(series((x^17 +3*x^16 -x^15 -5*x^14 +8*x^13 -8*x^12 -22*x^10 -20*x^9 -62*x^8 -20*x^7 -42*x^6 +18*x^5 +19*x^3 +x^2 +3*x -1)/(-x^20 -2*x^19 +2*x^18 +9*x^17 -12*x^16 +27*x^15 +41*x^14 +66*x^13 +62*x^12 +184*x^11 +76*x^10 +156*x^9 -92*x^8 +20*x^7 -141*x^6 +28*x^5 -62*x^4 +19*x^3 +5*x -1), x, n+1), x, n):
    seq(a(n), n=0..40);

Formula

G.f.: (x^17 +3*x^16 -x^15 -5*x^14 +8*x^13 -8*x^12 -22*x^10 -20*x^9 -62*x^8 -20*x^7 -42*x^6 +18*x^5 +19*x^3 +x^2 +3*x -1) / (-x^20 -2*x^19 +2*x^18 +9*x^17 -12*x^16 +27*x^15 +41*x^14 +66*x^13 +62*x^12 +184*x^11 +76*x^10 +156*x^9 -92*x^8 +20*x^7 -141*x^6 +28*x^5 -62*x^4 +19*x^3 +5*x -1).

A233506 Number of tilings of a 3 X 3 X n box using bricks of shape 3 X 1 X 1 and 2 X 1 X 1.

Original entry on oeis.org

1, 14, 717, 62253, 4732061, 382882762, 31449389548, 2571574546111, 210607584419520, 17254476918858789, 1413637025226131703, 115812392270890399373, 9488271882367228634756, 777357166136453697810804, 63686950935296529029018801, 5217741644362129948411085318
Offset: 0

Views

Author

Alois P. Heinz, Dec 11 2013

Keywords

Crossrefs

Programs

  • Maple
    b:= proc(n, l) option remember; local k, t; t:= min(l[]);
          if n=0 then 1 elif t>0 then b(n-t, map(h->h-t, l))
        else for k while l[k]>0 do od;
             add(`if`(n>=j, b(n, s(k=j, l)), 0), j=2..3)+
             `if`(k<=6 and l[k+3]=0, b(n, s(k=1, k+3=1, l)), 0)+
             `if`(k<=3 and l[k+3]=0 and l[k+6]=0,
                b(n, s(k=1, k+3=1, k+6=1, l)), 0)+
             `if`(irem(k, 3)>0 and l[k+1]=0,
                b(n, s(k=1, k+1=1, l)), 0)+
             `if`(irem(k, 3)=1 and l[k+1]=0 and l[k+2]=0,
                b(n, subsop(k=1, k+1=1, k+2=1, l)), 0)
          fi
        end:
    a:=n-> b(n, [0$9]): s:=subsop:
    seq(a(n), n=0..10);
  • Mathematica
    b[n_, l_] := b[n, l] = Module[{k, t}, t := Min[l]; If [n == 0, 1, If[t > 0, b[n-t, l-t], k = 1; While[l[[k]] > 0, k++ ]; Sum[If[n >= j, b[n, ReplacePart[l, k -> j]], 0], {j, 2, 3}] + If[k <= 6 && l[[k+3]] == 0, b[n, ReplacePart[l, {k -> 1, k+3 -> 1}]], 0] + If[k <= 3 && l[[k+3]] == 0 && l[[k+6]] == 0, b[n, ReplacePart[l, {k -> 1, k+3 -> 1, k+6 -> 1}]], 0] + If[Mod[k, 3] > 0 && l[[k+1]] == 0, b[n, ReplacePart[l, {k -> 1, k+1 -> 1}]], 0] + If[Mod[k, 3] == 1 && l[[k+1]] == 0 && l[[k+2]] == 0, b[n, ReplacePart[l, {k -> 1, k+1 -> 1, k+2 -> 1}]], 0] ]] ]; a[n_] := b[n, Array[0&, 9]]; Table[a[n], {n, 0, 10}] // Flatten (* Jean-François Alcover, Dec 16 2013, translated from Maple *)

A233507 Number of tilings of a 2 X 4 X n box using bricks of shape 3 X 1 X 1 and 2 X 1 X 1.

Original entry on oeis.org

1, 7, 201, 9787, 379688, 16512483, 726964790, 31549810845, 1378740599284, 60239603421159, 2630166605483293, 114886450998314920, 5017916294582867990, 219163121582772423673, 9572435654283943792842, 418094220600909382190818, 18261053013117932038592765
Offset: 0

Views

Author

Alois P. Heinz, Dec 11 2013

Keywords

Examples

			a(1) = A219866(4,2) = A129682(4) = A219866(2,4) = A219862(2) = 7:
._______. ._______. ._______. ._______.
|_____| | | |_____| | | | | | |___| | |
|_____|_| |_|_____| |_|_|_|_| |___|_|_|
._______. ._______. ._______.
| |___| | | | |___| |___|___|
|_|___|_| |_|_|___| |___|___|.
		

Crossrefs

Programs

  • Maple
    b:= proc(n, l) option remember; local k, t; t:= min(l[]);
          if n=0 then 1
        elif t>0 then b(n-t, map(h->h-t, l))
        else for k while l[k]>0 do od;
             add(`if`(n>=j, b(n, s(k=j, l)), 0), j=2..3)+
             `if`(k<=6 and l[k+2]=0, b(n, s(k=1, k+2=1, l)), 0)+
             `if`(k<=4 and l[k+2]=0 and l[k+2*2]=0, b(n, s(k=1,
             k+2=1, k+2*2=1, l)), 0)+ `if`(irem(k, 2)>0 and
             l[k+1]=0, b(n, s(k=1, k+1=1, l)), 0)
          fi
        end:
    a:=n-> b(n, [0$8]): s:= subsop:
    seq(a(n), n=0..10);
  • Mathematica
    b[n_, l_] := b[n, l] = Module[{k, t}, t = Min[l]; Which[n == 0, 1, t > 0, b[n-t, l-t], True, For[k = 1, l[[k]] > 0, k++]; Sum[If[n >= j, b[n, ReplacePart[l, k -> j]], 0], {j, 2, 3}] + If[k <= 6 && l[[k + 2]] == 0, b[n, ReplacePart[l, {k -> 1, k+2 -> 1}]], 0] + If[k <= 4 && l[[k+2]] == 0 && l[[k+2*2]] == 0, b[n, ReplacePart[l, {k -> 1, k+2 -> 1, k+2*2 -> 1}]], 0] + If[Mod[k, 2] > 0 && l[[k+1]] == 0, b[n, ReplacePart[l, {k -> 1, k+1 -> 1}]], 0]]]; a[n_] := b[n, Array[0&, 8]]; Table[Print[an = a[n]]; an, {n, 0, 16}] (* Jean-François Alcover, Dec 30 2013, translated from Maple *)

A233509 Number of tilings of a 2 X 5 X n box using bricks of shape 3 X 1 X 1 and 2 X 1 X 1.

Original entry on oeis.org

1, 15, 1062, 148414, 16512483, 2043497465, 257251613508, 31941208907916, 3990164870713039, 498504394558488109, 62237975023439983192, 7773270324407375580946, 970802515607358269506951, 121240108673115249961266051, 15141593230837339625055971170
Offset: 0

Views

Author

Alois P. Heinz, Dec 11 2013

Keywords

Examples

			a(1) = A219866(5,2) = A129682(5) = A219866(2,5) = A219868(2) = 15:
.___.  .___.  .___.  .___.  .___.  .___.  .___.  .___.
| | |  |___|  | | |  |___|  | | |  |___|  | | |  |___|
| | |  |___|  |_|_|  | | |  | | |  |___|  |_|_|  | | |
|_|_|  |___|  |___|  |_|_|  |_|_|  |___|  |___|  |_|_|
| | |  | | |  | | |  | | |  |___|  |___|  |___|  |___|
|_|_|  |_|_|  |_|_|  |_|_|  |___|  |___|  |___|  |___|
.___.  .___.  .___.  .___.  .___.  .___.  .___.
| | |  | | |  |___|  |___|  | | |  | | |  |___|
|_|_|  |_|_|  |___|  |___|  |_| |  | |_|  | | |
| | |  | | |  | | |  | | |  | |_|  |_| |  | | |
| | |  |_|_|  | | |  |_|_|  | | |  | | |  |_|_|
|_|_|  |___|  |_|_|  |___|  |_|_|  |_|_|  |___|.
		

Crossrefs

Programs

  • Maple
    b:= proc(n, l) option remember; local k, t; t:= min(l[]);
          if n=0 then 1 elif t>0 then b(n-t, map(h->h-t, l))
        else for k while l[k]>0 do od;
             add(`if`(n>=j, b(n, s(k=j, l)), 0), j=2..3)+
             `if`(k<=5 and l[k+5]=0, b(n, s(k=1, k+5=1, l)), 0)+
             `if`(irem(k, 5)>0 and l[k+1]=0, b(n, s(k=1, k+1=1, l)), 0)+
             `if`(irem(k, 5) in [$1..3] and l[k+1]=0 and l[k+2]=0,
             b(n, s(k=1, k+1=1, k+2=1, l)), 0)
          fi
        end:
    a:=n-> b(n, [0$10]): s:=subsop:
    seq(a(n), n=0..4);
  • Mathematica
    b[n_, l_] := b[n, l] = Module[{k, t}, t = Min[l]; Which[n == 0, 1, t > 0, b[n-t, l-t], True, For[k = 1, l[[k]] > 0, k++]; Sum[If[n >= j, b[n, ReplacePart[l, k -> j]], 0], {j, 2, 3}] + If[k <= 5 && l[[k+5]] == 0, b[n, ReplacePart[l, {k -> 1, k+5 -> 1}]], 0] + If[Mod[k, 5] > 0 && l[[k+1]] == 0, b[n, ReplacePart[l, {k -> 1, k+1 -> 1}]], 0] + If[1 <= Mod[k, 5] <= 3 && l[[k+1]] == 0 && l[[k+2]] == 0, b[n, ReplacePart[l, {k -> 1, k+1 -> 1, k+2 -> 1}]], 0]]];a[n_] := b[n, Array[0&, 10]]; Table[Print[an = a[n]]; an, {n, 0, 14}] (* Jean-François Alcover, Dec 30 2013, translated from Maple *)

A278815 Number of tilings of a 2 X n grid with monomers, dimers, and trimers.

Original entry on oeis.org

1, 2, 7, 29, 109, 416, 1596, 6105, 23362, 89415, 342193, 1309593, 5011920, 19180976, 73406985, 280933906, 1075154535, 4114694797, 15747237101, 60265824784, 230641706484, 882682631025, 3378090801226, 12928199853783, 49477163668857, 189352713633433
Offset: 0

Views

Author

Kathryn Haymaker, Nov 28 2016

Keywords

Comments

The first three terms are the same as A030186 because there are only monomers and dimers in boards with n<3.

Crossrefs

Programs

  • GAP
    a:=[1,2,7,29,109,416];; for n in [7..30] do a[n]:=3*a[n-1]+2*a[n-2] +5*a[n-3]-2*a[n-4]-a[n-6]; od; a; # G. C. Greubel, Oct 28 2019
  • Magma
    R:=PowerSeriesRing(Integers(), 30); Coefficients(R!( (1-x-x^2-x^3)/(1-3*x-2*x^2-5*x^3+2*x^4+x^6) )); // G. C. Greubel, Oct 28 2019
    
  • Maple
    seq(coeff(series((1-x-x^2-x^3)/(1-3*x-2*x^2-5*x^3+2*x^4+x^6), x, n+1), x, n), n = 0..30); # G. C. Greubel, Oct 28 2019
  • Mathematica
    LinearRecurrence[{3,2,5,-2,0,-1}, {1,2,7,29,109,416}, 30] (* G. C. Greubel, Oct 28 2019 *)
  • PARI
    my(x='x+O('x^30)); Vec((1-x-x^2-x^3)/(1-3*x-2*x^2-5*x^3+ 2*x^4 +x^6)) \\ G. C. Greubel, Oct 28 2019
    
  • Sage
    def A278815_list(prec):
        P. = PowerSeriesRing(ZZ, prec)
        return P( (1-x-x^2-x^3)/(1-3*x-2*x^2-5*x^3+2*x^4+x^6) ).list()
    A278815_list(30) # G. C. Greubel, Oct 28 2019
    

Formula

a(n) = 3*a(n-1) + 2*a(n-2) + 5*a(n-3) - 2*a(n-4) - a(n-6).
G.f.: (1 - x - x^2 - x^3)/(1 - 3*x - 2*x^2 - 5*x^3 + 2*x^4 + x^6).
Showing 1-7 of 7 results.