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-10 of 10 results.

A077957 Powers of 2 alternating with zeros.

Original entry on oeis.org

1, 0, 2, 0, 4, 0, 8, 0, 16, 0, 32, 0, 64, 0, 128, 0, 256, 0, 512, 0, 1024, 0, 2048, 0, 4096, 0, 8192, 0, 16384, 0, 32768, 0, 65536, 0, 131072, 0, 262144, 0, 524288, 0, 1048576, 0, 2097152, 0, 4194304, 0, 8388608, 0, 16777216, 0, 33554432, 0, 67108864, 0, 134217728, 0, 268435456
Offset: 0

Views

Author

N. J. A. Sloane, Nov 17 2002

Keywords

Comments

Normally sequences like this are not included, since with the alternating 0's deleted it is already in the database.
Inverse binomial transform of A001333. - Paul Barry, Feb 25 2003
"Sloping binary representation" of powers of 2 (A000079), slope=-1 (see A037095 and A102370). - Philippe Deléham, Jan 04 2008
0,1,0,2,0,4,0,8,0,16,... is the inverse binomial transform of A000129 (Pell numbers). - Philippe Deléham, Oct 28 2008
Number of maximal self-avoiding walks from the NW to SW corners of a 3 X n grid.
Row sums of the triangle in A204293. - Reinhard Zumkeller, Jan 14 2012
Pisano period lengths: 1, 1, 4, 1, 8, 4, 6, 1, 12, 8, 20, 4, 24, 6, 8, 1, 16, 12, 36, 8, ... . - R. J. Mathar, Aug 10 2012
This sequence occurs in the length L(n) = sqrt(2)^n of Lévy's C-curve at the n-th iteration step. Therefore, L(n) is the Q(sqrt(2)) integer a(n) + a(n-1)*sqrt(2), with a(-1) = 0. For a variant of this C-curve see A251732 and A251733. - Wolfdieter Lang, Dec 08 2014
a(n) counts walks (closed) on the graph G(1-vertex,2-loop,2-loop). Equivalently the middle entry (2,2) of A^n where the adjacency matrix of digraph is A=(0,1,0;1,0,1;0,1,0). - David Neil McGrath, Dec 19 2014
a(n-2) is the number of compositions of n into even parts. For example, there are 4 compositions of 6 into even parts: (6), (222), (42), and (24). - David Neil McGrath, Dec 19 2014
Also the number of alternately constant compositions of n + 2, ranked by A351010. The alternately strict version gives A000213. The unordered version is A035363, ranked by A000290, strict A035457. - Gus Wiseman, Feb 19 2022
a(n) counts degree n fixed points of GF(2)[x]'s automorphisms. Proof: given a field k, k[x]'s automorphisms are determined by k's automorphisms and invertible affine maps x -> ax + b. GF(2) is rigid and has only one unit so its only nontrivial automorphism is x -> x + 1. For n = 0 we have 1 fixed point, the constant polynomial 1. (Taking the convention that 0 is not a degree 0 polynomial.) For n = 1 we have 0 fixed points as x -> x + 1 -> x are the only degree 1 polynomials. Note that if f(x) is a fixed point, then f(x) + 1 is also a fixed point. Given f(x) a degree n fixed point, we can assume WLOG x | f(x). Applying the automorphism, we then have x + 1 | f(x). Now note that f(x) / (x^2 + x) must be a fixed point, so any fixed point of degree n must either be of the form g(x) * (x^2 + x) or g(x) * (x^2 + x) + 1 for a unique degree n - 2 fixed point g(x). Therefore we have the recurrence relation a(n) = 2 * a(n - 2) as desired. - Keith J. Bauer, Mar 19 2024

Crossrefs

Column k=3 of A219946. - Alois P. Heinz, Dec 01 2012
Cf. A016116 (powers repeated).

Programs

  • GAP
    Flat(List([0..30],n->[2^n,0])); # Muniru A Asiru, Aug 05 2018
  • Haskell
    a077957 = sum . a204293_row  -- Reinhard Zumkeller, Jan 14 2012
    
  • Magma
    &cat [[2^n,0]: n in [0..20]]; // Vincenzo Librandi, Apr 03 2018
    
  • Maple
    seq(op([2^n,0]),n=0..100); # Robert Israel, Dec 23 2014
  • Mathematica
    a077957[n_] := Riffle[Table[2^i, {i, 0, n - 1}], Table[0, {n}]]; a077957[29] (* Michael De Vlieger, Dec 22 2014 *)
    CoefficientList[Series[1/(1 - 2*x^2), {x,0,50}], x] (* G. C. Greubel, Apr 12 2017 *)
    LinearRecurrence[{0, 2}, {1, 0}, 54] (* Robert G. Wilson v, Jul 23 2018 *)
    Riffle[2^Range[0,30],0,{2,-1,2}] (* Harvey P. Dale, Jan 06 2022 *)
  • PARI
    a(n)=if(n<0||n%2, 0, 2^(n/2))
    
  • Sage
    def A077957():
        x, y = -1, 1
        while True:
            yield -x
            x, y = x + y, x - y
    a = A077957(); [next(a) for i in range(40)]  # Peter Luschny, Jul 11 2013
    

Formula

G.f.: 1/(1-2*x^2).
E.g.f.: cosh(x*sqrt(2)).
a(n) = (1 - n mod 2) * 2^floor(n/2).
a(n) = sqrt(2)^n*(1+(-1)^n)/2. - Paul Barry, May 13 2003
a(n) = 2*a(n-2) with a(0)=1, a(1)=0. - Jim Singh, Jul 12 2018

A052947 Expansion of 1/(1-x^2-2*x^3).

Original entry on oeis.org

1, 0, 1, 2, 1, 4, 5, 6, 13, 16, 25, 42, 57, 92, 141, 206, 325, 488, 737, 1138, 1713, 2612, 3989, 6038, 9213, 14016, 21289, 32442, 49321, 75020, 114205, 173662, 264245, 402072, 611569, 930562, 1415713, 2153700, 3276837, 4985126, 7584237, 11538800
Offset: 0

Views

Author

encyclopedia(AT)pommard.inria.fr, Jan 25 2000

Keywords

Comments

a(n) is the number of compositions (ordered partitions) of n into parts 1 of one kind and part 2 of two kinds. - Joerg Arndt, Oct 22 2019

Crossrefs

Column k=2 of A219946. - Alois P. Heinz, Dec 01 2012

Programs

  • GAP
    a:=[1,0,1];; for n in [4..50] do a[n]:=a[n-2]+2*a[n-3]; od; a; # G. C. Greubel, Oct 21 2019
  • Magma
    R:=PowerSeriesRing(Integers(), 50); Coefficients(R!( 1/(1-x^2-2*x^3) )); // G. C. Greubel, Oct 21 2019
    
  • Maple
    spec:= [S,{S=Sequence(Prod(Union(Prod(Union(Z,Z),Z),Z),Z))}, unlabeled]: seq(combstruct[count ](spec,size=n), n=0..20);
    seq(coeff(series(1/(1-x^2-2*x^3), x, n+1), x, n), n = 0..50); # G. C. Greubel, Oct 21 2019
  • Mathematica
    LinearRecurrence[{0,1,2}, {1,0,1}, 50] (* G. C. Greubel, Oct 21 2019 *)
  • PARI
    my(x='x+O('x^50)); Vec(1/(1-x^2-2*x^3)) \\ G. C. Greubel, Oct 21 2019
    
  • Sage
    def A052947_list(prec):
        P. = PowerSeriesRing(ZZ, prec)
        return P(1/(1-x^2-2*x^3)).list()
    A052947_list(50) # G. C. Greubel, Oct 21 2019
    

Formula

a(n) = a(n-2) + 2*a(n-3).
a(n) = Sum_{alpha=RootOf(-1+z^2+2*z^3)} (1/52)*(3 +17*alpha -2*alpha^2)*alpha^(-1-n).
a(n) = Sum_{k=0..floor(n/2)} C(k,n-2*k)*2^(n-2*k). - Paul Barry, Oct 16 2004
If p[1]=0, p[2]=1, p[3]=2, p[i]=0, (i>3), and if A is Hessenberg matrix of order n defined by: A[i,j]=p[j-i+1], (i<=j), A[i,j]=-1, (i=j+1), and A[i,j]=0 otherwise. Then, for n>=1, a(n-1)=det A. - Milan Janjic, May 02 2010

Extensions

More terms from James Sellers, Jun 05 2000

A165799 Number of tilings of a 4 X n rectangle using right trominoes and 2 X 2 tiles.

Original entry on oeis.org

1, 0, 1, 4, 6, 16, 37, 92, 245, 560, 1426, 3720, 9069, 22808, 58177, 145660, 366318, 925536, 2331269, 5872212, 14802941, 37311528, 94038250, 236999064, 597348237, 1505640016, 3794761257, 9564393972, 24106951622, 60759989040, 153141435269, 385986293964
Offset: 0

Views

Author

Alois P. Heinz, Sep 27 2009

Keywords

Examples

			a(4) = 6, because there are 6 tilings of a 4 X 4 rectangle using right trominoes and 2 X 2 tiles:
  .___.___. .___.___. .___.___. .___.___. .___.___. .___.___.
  | . | . | | ._|_. | | ._| . | | ._|_. | | ._|_. | | . |_. |
  |___|___| |_| . |_| |_| |___| |_| ._|_| |_|_. |_| |___| |_|
  | . | . | | |___| | | |___| | | |_| . | | . |_| | | |___| |
  |___|___| |___|___| |___|___| |___|___| |___|___| |___|___|
		

Crossrefs

Column k=4 of A219946.

Programs

  • Maple
    a:= n-> (Matrix([[4, 1, 0, 1, 0$5]]). Matrix(9, (i,j)-> if i=j-1 then 1 elif j=1 then [1, 1, 9, 1, -3, -22, -16, 0, -4][i] else 0 fi)^n)[1,4]: seq(a(n), n=0..30);
  • Mathematica
    Series[ (-6*x^3 - x + 1) / (4*x^9 + 16*x^7 + 22*x^6 + 3*x^5 - x^4 - 9*x^3 - x^2 - x + 1), {x, 0, 31}] // CoefficientList[#, x] & (* Jean-François Alcover, Jun 18 2013, after Alois P. Heinz *)
    LinearRecurrence[{1,1,9,1,-3,-22,-16,0,-4},{1,0,1,4,6,16,37,92,245},40] (* Harvey P. Dale, Nov 09 2024 *)

Formula

G.f.: -(6*x^3+x-1) / (4*x^9+16*x^7+22*x^6+3*x^5-x^4-9*x^3-x^2-x+1).
a(n) = a(n-1) +a(n-2) +9*a(n-3) +a(n-4) -3*a(n-5) -22*a(n-6) -16*a(n-7) -4*a(n-9).

A190759 Number of tilings of a 5 X n rectangle using right trominoes and 2 X 2 tiles.

Original entry on oeis.org

1, 0, 4, 0, 16, 0, 136, 0, 1128, 384, 8120, 6912, 60904, 75136, 491960, 720640, 4023592, 6828928, 32819320, 63472640, 270471784, 574543744, 2256221368, 5119155712, 18940876712, 45266369152, 159625747960, 397949457408, 1350573713256
Offset: 0

Views

Author

Alois P. Heinz, May 18 2011

Keywords

Examples

			a(2) = 4, because there are 4 tilings of a 5 X 2 rectangle using right trominoes and 2 X 2 tiles:
.___. .___. .___. .___.
| . | | . | | ._| |_. |
|___| |___| |_| | | |_|
| ._| |_. | |___| |___|
|_| | | |_| | . | | . |
|___| |___| |___| |___|
		

Crossrefs

Column k=5 of A219946.

Programs

  • Maple
    a:= n-> (Matrix(14, (i, j)-> `if`(i=j-1, 1, `if`(i=14, [-80, -160, 308, -88, -2, 396, -453, -10, 190, -12, -57, 2, 13, 0][j], 0)))^n. <<0, 1/4, 0, 1, 0, 4, 0, 16, 0, 136, 0, 1128, 384, 8120>>)[4,1]: seq(a(n), n=0..30);
  • Mathematica
    a[n_] := (MatrixPower[ Table[ If[i == j-1, 1, If[i == 14, {-80, -160, 308, -88, -2, 396, -453, -10, 190, -12, -57, 2, 13, 0}[[j]], 0]], {i, 1, 14}, {j, 1, 14}], n] . {0, 1/4, 0, 1, 0, 4, 0, 16, 0, 136, 0, 1128, 384, 8120})[[4]]; Table[a[n], {n, 0, 30}] (* Jean-François Alcover, Dec 05 2013, translated from Alois P. Heinz's Maple program *)

Formula

G.f.: (20*x^12+40*x^11 +18*x^10+52*x^9 +35*x^8-26*x^7 +34*x^6-4*x^5 -21*x^4 +2*x^3 +9*x^2-1) / (-80*x^14-160*x^13 +308*x^12-88*x^11 -2*x^10+396*x^9 -453*x^8-10*x^7 +190*x^6-12*x^5 -57*x^4+2*x^3 +13*x^2-1).

A219952 Number of tilings of an n X n square using right trominoes and 2 X 2 tiles.

Original entry on oeis.org

1, 0, 1, 0, 6, 0, 545, 5504, 652036, 44013568, 11112714624, 3517475475328, 2781543486427548, 3568483481372543360, 9829161878198755474915, 48599777948701165162242560, 484370819140388708451108625276, 9036085159101926537420075859958528
Offset: 0

Views

Author

Alois P. Heinz, Dec 01 2012

Keywords

Examples

			a(4) = 6, because there are 6 tilings of a 4 X 4 square using right trominoes and 2 X 2 tiles:
  .___.___. .___.___. .___.___. .___.___. .___.___. .___.___.
  | . | . | | ._|_. | | ._| . | | ._|_. | | ._|_. | | . |_. |
  |___|___| |_| . |_| |_| |___| |_| ._|_| |_|_. |_| |___| |_|
  | . | . | | |___| | | |___| | | |_| . | | . |_| | | |___| |
  |___|___| |___|___| |___|___| |___|___| |___|___| |___|___|
		

Crossrefs

Main diagonal of A219946.
Cf. A233807.

Extensions

a(15)-a(16) from Alois P. Heinz, Sep 24 2014
a(17) from Alois P. Heinz, Nov 18 2018

A219947 Number of tilings of a 6 X n rectangle using right trominoes and 2 X 2 tiles.

Original entry on oeis.org

1, 0, 5, 8, 37, 136, 545, 2376, 10534, 46824, 212926, 961552, 4374949, 19888832, 90570555, 412561096, 1880381253, 8572076760, 39086502817, 178240531672, 812868845530, 3707227380920, 16907856403612, 77113848855920, 351705509804137, 1604084309231360
Offset: 0

Views

Author

Alois P. Heinz, Dec 01 2012

Keywords

Examples

			a(2) = 5, because there are 5 tilings of a 6 X 2 rectangle using right trominoes and 2 X 2 tiles:
.___.  .___.  .___.  .___.  .___.
| . |  | ._|  | ._|  |_. |  |_. |
|___|  |_| |  |_| |  | |_|  | |_|
| . |  |___|  |___|  |___|  |___|
|___|  | ._|  |_. |  | ._|  |_. |
| . |  |_| |  | |_|  |_| |  | |_|
|___|  |___|  |___|  |___|  |___|
		

Crossrefs

Column k=6 of A219946.

Programs

  • Maple
    gf:= -(6080*x^25 -7104*x^24 -21936*x^23 -4112*x^22 +82016*x^21 +39064*x^20 -139520*x^19 -103312*x^18 +102180*x^17 +165884*x^16 -18076*x^15 -101470*x^14 -41918*x^13 +35248*x^12 +29374*x^11 -1107*x^10 -10608*x^9 -3089*x^8 +1636*x^7 +1092*x^6 -26*x^5 -178*x^4 -22*x^3 +13*x^2 +4*x -1) /
    (16640*x^29 -14592*x^28 +11840*x^27 -165952*x^26 +87952*x^25 +141200*x^24 +521244*x^23 -541484*x^22 -781380*x^21 +1310*x^20 +1242434*x^19 +476620*x^18 -673176*x^17 -725593*x^16 +92654*x^15 +393128*x^14 +137172*x^13 -107125*x^12 -88592*x^11 -1136*x^10 +24088*x^9 +7488*x^8 -2806*x^7 -2014*x^6 +12*x^5 +263*x^4 +34*x^3 -18*x^2 -4*x +1):
    a:= n-> coeff (series (gf, x, n+1), x, n):
    seq(a(n), n=0..30);

Formula

G.f.: see Maple program.

A219948 Number of tilings of a 7 X n rectangle using right trominoes and 2 X 2 tiles.

Original entry on oeis.org

1, 0, 6, 0, 92, 0, 2376, 5504, 71248, 253952, 2175992, 10140032, 72393152, 377186688, 2462850896, 13696293888, 85330361248, 489397951936, 2980753350440, 17385409283712, 104607950578584, 615347939509760, 3679860151206528, 21744078445007360, 129606354640045704
Offset: 0

Views

Author

Alois P. Heinz, Dec 01 2012

Keywords

Examples

			a(2) = 6, because there are 6 tilings of a 7 X 2 rectangle using right trominoes and 2 X 2 tiles:
.___.  .___.  .___.  .___.  .___.  .___.
| . |  | . |  | ._|  | . |  | . |  |_. |
|___|  |___|  |_| |  |___|  |___|  | |_|
| . |  | ._|  |___|  | . |  |_. |  |___|
|___|  |_| |  | . |  |___|  | |_|  | . |
| ._|  |___|  |___|  |_. |  |___|  |___|
|_| |  | . |  | . |  | |_|  | . |  | . |
|___|  |___|  |___|  |___|  |___|  |___|
		

Crossrefs

Column k=7 of A219946.

Programs

  • Maple
    gf:= -(65536*x^53 -1146880*x^52 +1056768*x^51 -11173888*x^50 -509952*x^49 +33372672*x^48 -46419968*x^47 +225738880*x^46 -47477504*x^45 -389283328*x^44 +1604376704*x^43 -193165168*x^42 +1816657344*x^41 +843167448*x^40 -5731518112*x^39 +3110216464*x^38 -11976005632*x^37 +6543273808*x^36 -5367184032*x^35 +9797996038*x^34 +2933363944*x^33 +6282799800*x^32 -2982763584*x^31 +85793812*x^30 -8254807988*x^29 +58758079*x^28 -1538296008*x^27 +1483118884*x^26 +420789512*x^25 +260010263*x^24 -408844686*x^23 +66645661*x^22 -78341234*x^21 -34068549*x^20 +45496788*x^19 +25092255*x^18 -16579172*x^17 -6253012*x^16 +4608446*x^15 +354299*x^14 -225506*x^13 -189351*x^12 +193666*x^11 -51177*x^10 +17850*x^9 -15917*x^8 +8086*x^7 -18*x^6 -566*x^5 +161*x^4 -56*x^3 +17*x^2 +4*x -1) /
    (393216*x^55 -8060928*x^54 +26296320*x^53 -79364096*x^52 +307560448*x^51 -223708160*x^50 +178826240*x^49 +1759063552*x^48 -6323347968*x^47 +6084576320*x^46 +1430120704*x^45 -7979568544*x^44 -3157624320*x^43 -44741808416*x^42 +44217857024*x^41 -44055137768*x^40 +94984995808*x^39 -37654878912*x^38 +90109498688*x^37 -70728329804*x^36 +574037808*x^35 -93062076382*x^34 +18476692408*x^33 -28473878368*x^32 +82151994152*x^31 +18394521038*x^30 +31896621428*x^29 -26926334975*x^28 -5199134488*x^27 -9226439666*x^26 +7282850020*x^25 -149204601*x^24 +1876828610*x^23 -760215019*x^22 +174549722*x^21 -578867289*x^20 +158364404*x^19 +54073841*x^18 +68603352*x^17 -51185474*x^16 -5563402*x^15 +2604251*x^14 +3992062*x^13 -846767*x^12 -588502*x^11 +146051*x^10 -7046*x^9 +29225*x^8 -14170*x^7 +448*x^6 +454*x^5 -115*x^4 +80*x^3 -23*x^2 -4*x +1):
    a:= n-> coeff (series (gf, x, n+1), x, n):
    seq(a(n), n=0..30);

Formula

G.f.: see Maple program.

A219949 Number of tilings of an 8 X n rectangle using right trominoes and 2 X 2 tiles.

Original entry on oeis.org

1, 0, 13, 16, 245, 1128, 10534, 71248, 652036, 5141408, 45081311, 377481816, 3256166909, 27751269104, 238314397799, 2040642918208, 17506339185192, 150079258587200, 1287249575901534, 11038702753296720, 94675989650833007, 811957493293460552, 6963826351562090734
Offset: 0

Views

Author

Alois P. Heinz, Dec 01 2012

Keywords

Examples

			a(2) = 13, because there are 13 tilings of an 8 X 2 rectangle using right trominoes and 2 X 2 tiles:
.___.  .___.  .___.  .___.  .___.  .___.
| ._|  | ._|  |_. |  |_. |  | ._|  | ._|
|_| |  |_| |  | |_|  | |_|  |_| |  |_| |
|___|  |___|  |___|  |___|  |___|  |___|
| ._|  |_. |  | ._|  |_. |  | . |  | . |
|_| |  | |_|  |_| |  | |_|  |___|  |___|
|___|  |___|  |___|  |___|  | ._|  |_. |
| . |  | . |  | . |  | . |  |_| |  | |_|
|___|  |___|  |___|  |___|  |___|  |___|
.___.  .___.  .___.  .___.  .___.  .___.  .___.
|_. |  |_. |  | . |  | . |  | . |  | . |  | . |
| |_|  | |_|  |___|  |___|  |___|  |___|  |___|
|___|  |___|  | ._|  | ._|  |_. |  |_. |  | . |
| . |  | . |  |_| |  |_| |  | |_|  | |_|  |___|
|___|  |___|  |___|  |___|  |___|  |___|  | . |
| ._|  |_. |  | ._|  |_. |  | ._|  |_. |  |___|
|_| |  | |_|  |_| |  | |_|  |_| |  | |_|  | . |
|___|  |___|  |___|  |___|  |___|  |___|  |___|
		

Crossrefs

Column k=8 of A219946.

A219950 Number of tilings of a 9 X n rectangle using right trominoes and 2 X 2 tiles.

Original entry on oeis.org

1, 0, 16, 0, 560, 384, 46824, 253952, 5141408, 44013568, 628801280, 6441106368, 81395792936, 898467518528, 10813539098984, 123094927843072, 1452323503655432, 16743873126866752, 195934939996794440, 2270867565108570304, 26483057736012701952
Offset: 0

Views

Author

Alois P. Heinz, Dec 01 2012

Keywords

Crossrefs

Column k=9 of A219946.

A219951 Number of tilings of a 10 X n rectangle using right trominoes and 2 X 2 tiles.

Original entry on oeis.org

1, 0, 25, 32, 1426, 8120, 212926, 2175992, 45081311, 628801280, 11112714624, 173179768136, 2908344290540, 46894928400912, 774211745673930, 12617601589397384, 207178457948099771, 3387766419366893632, 55527737283695335309, 908939402189646871904
Offset: 0

Views

Author

Alois P. Heinz, Dec 01 2012

Keywords

Crossrefs

Column k=10 of A219946.
Showing 1-10 of 10 results.