|
Search: id:A118898
|
|
|
| A118898 |
|
Number of binary sequences of length n containing exactly one subsequence 0000. |
|
+0 2
|
|
| 0, 0, 0, 0, 1, 2, 5, 12, 28, 62, 136, 294, 628, 1328, 2787, 5810, 12043, 24840, 51016, 104380, 212848, 432732, 877400, 1774672, 3581605, 7213746, 14502449, 29106100, 58323844, 116702074, 233199000, 465405058, 927744428, 1847359520, 3674769991
(list; graph; listen)
|
|
|
OFFSET
|
0,6
|
|
|
COMMENT
|
Column 1 of A118897.
|
|
FORMULA
|
G.f.=z^4/(1-z-z^2-z^3-z^4)^2.
Contribution from Bobby Milazzo [bobbym] (mpopyft(AT)lycos.com), Aug 30 2009: (Start)
a(1)=0,a(2)=0,a(3)=0,a(4)=1,a(5)=2,a(6)=5,a(7)=12,a(8)=28
a(n)=2a(n-1)+a(n-2)-a(n-4)-4a(n-5)-3a(n-6)-2a(n-7)-a(n-8) (End)
|
|
EXAMPLE
|
a(6)=5 because we have 000010,000011,010000,100001 and 110000.
sage: taylor( mul(x/(1-x-x^2-x^3-x^4)^2 for i in xrange(1,2)),x,0,31)# solution>> x + 2*x^2 + 5*x^3 + 12*x^4 + 28*x^5 + 62*x^6 +...+ 465405058*x^28 + 927744428*x^29 + 1847359520*x^30 + 3674769991*x^31+etc... and if sage: taylor( mul(x^4/(1-x-x^2-x^3-x^4)^2 for i in xrange(1,2)),x,0,34)#(Emeric Deutsch) then solution: x^4 + 2*x^5 + 5*x^6 + 12*x^7 + 28*x^8 + 62*x^9 +...+ 465405058*x^31 + 927744428*x^32 + 1847359520*x^33 + 3674769991*x^34+etc... [From Zerinvary Lajos (zerinvarylajos(AT)yahoo.com), Jun 02 2009]
|
|
MAPLE
|
g:=z^4/(1-z-z^2-z^3-z^4)^2: gser:=series(g, z=0, 40): seq(coeff(gser, z, n), n=0..37);
|
|
MATHEMATICA
|
Contribution from Bobby Milazzo [bobbym] (mpopyft(AT)lycos.com), Aug 30 2009: (Start)
With Mathematica 7.01
RecurrenceTable[{a[1]==0, a[2]==0, a[3]==0, a[4]==1, a[5]==2, a[6]==5,
a[7]==12, a[8]==28, a[n]==2a[n-1]+a[n-2]-a[n-4]-4a[n-5]
-3a[n-6]-2a[n-7]-a[n-8]}, a, {n, 9, 50}] (End)
|
|
PROGRAM
|
(Other) sage: taylor( mul(x/(1-x-x^2-x^3-x^4)^2 for i in xrange(1, 2)), x, 0, 31)# [From Zerinvary Lajos (zerinvarylajos(AT)yahoo.com), Jun 02 2009]
|
|
CROSSREFS
|
Cf. A118897, A000078.
Adjacent sequences: A118895 A118896 A118897 this_sequence A118899 A118900 A118901
Sequence in context: A128096 A018010 A026710 this_sequence A111586 A006979 A019301
|
|
KEYWORD
|
nonn
|
|
AUTHOR
|
Emeric Deutsch (deutsch(AT)duke.poly.edu), May 04 2006
|
|
|
Search completed in 0.002 seconds
|