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!)
A164203 Number of binary strings of length n with equal numbers of 00001 and 10000 substrings. 1
1, 2, 4, 8, 16, 30, 58, 114, 226, 452, 904, 1808, 3616, 7232, 14464, 28928, 57856, 115712, 231424, 462848, 925696, 1851392, 3702784, 7405568, 14811136, 29622272, 59244544, 118489088, 236978176, 473956352, 947912704, 1895825408, 3791650816, 7583301632 (list; graph; refs; listen; history; text; internal format)
OFFSET
0,2
LINKS
FORMULA
a(n) = 113*2^(n-7) for n >= 8. - Brad Clardy, Feb 11 2012
G.f.: (2*x^8+2*x^7+2*x^6+2*x^5-1)/(2*x-1). - Alois P. Heinz, Aug 17 2019
MATHEMATICA
CoefficientList[Series[(2x^8+2x^7+2x^6+2x^5-1)/(2x-1), {x, 0, 50}], x] (* or *) LinearRecurrence[{2}, {1, 2, 4, 8, 16, 30, 58, 114, 226}, 50] (* Harvey P. Dale, Apr 23 2022 *)
PROG
(Empirical) (bc) (z is number of 0's) z=4; for(i=0; i<=500; i++) { if(i<=z)a=2^i else if(i<=2*z)a=2*a-2 else a=2*a; a }
CROSSREFS
Sequence in context: A164245 A164236 A164259 * A164178 A335542 A027423
KEYWORD
nonn,easy
AUTHOR
R. H. Hardin, Aug 11 2009
STATUS
approved

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 24 20:08 EDT 2024. Contains 371963 sequences. (Running on oeis4.)