

A151552


G.f.: Prod_{ k >= 1} (1 + x^(2^k1) + x^(2^k)).


18



1, 1, 1, 1, 2, 2, 1, 1, 2, 2, 2, 3, 4, 3, 1, 1, 2, 2, 2, 3, 4, 3, 2, 3, 4, 4, 5, 7, 7, 4, 1, 1, 2, 2, 2, 3, 4, 3, 2, 3, 4, 4, 5, 7, 7, 4, 2, 3, 4, 4, 5, 7, 7, 5, 5, 7, 8, 9, 12, 14, 11, 5, 1, 1, 2, 2, 2, 3, 4, 3, 2, 3, 4, 4, 5, 7, 7, 4, 2, 3, 4, 4, 5, 7, 7, 5, 5, 7, 8, 9, 12, 14, 11, 5, 2, 3, 4, 4, 5, 7, 7, 5, 5
(list;
graph;
refs;
listen;
history;
text;
internal format)



OFFSET

0,5


LINKS

N. J. A. Sloane, Table of n, a(n) for n = 0..16383
David Applegate, Omar E. Pol and N. J. A. Sloane, The Toothpick Sequence and Other Sequences from Cellular Automata
N. J. A. Sloane, Catalog of Toothpick and Cellular Automata Sequences in the OEIS


FORMULA

a(n) = 1 for 0 <= n <= 3; thereafter write n = 2^i + j, with 0 <= j < 2^i, then a(n) = a(j) + a(j+1), except that a(2^(i+1)2) = a(2^(i+1)1) = 1.
a(n) = sum_{k >= 1, n+k even} binomial(A000120(n+k),k); the sum may be restricted further to k <= A000523(n+1). [From Hagen von Eitzen, May 20 2009]


EXAMPLE

Written as a triangle:
1,
1,
1,1,
2,2,1,1,
2,2,2,3,4,3,1,1,
2,2,2,3,4,3,2,3,4,4,5,7,7,4,1,1,
2,2,2,3,4,3,2,3,4,4,5,7,7,4,2,3,4,4,5,7,7,5,5,7,8,9,12,14,11,5,1,1,
2,2,2,3,4,3,2,3,4,4,5,7,7,4,2,3,4,4,5,7,7,5,5,7,8,9,12,14,11,5,2,3,4,4,5,7,7,5,5,...
The rows converge to A151714.


MAPLE

G := mul( 1 + x^(2^n1) + x^(2^n), n=1..20);
wt := proc(n) local w, m, i; w := 0; m := n; while m > 0 do i := m mod 2; w := w+i; m := (mi)/2; od; w; end:
f:=proc(n) local t1, k; global wt; t1:=0; for k from 0 to 20 do if n+k mod 2 = 0 then t1:=t1+binomial(wt(n+k), k); fi; od; t1; end;


CROSSREFS

For generating functions of the form Prod_{k>=c} (1+a*x^(2^k1)+b*x^2^k)) for the following values of (a,b,c) see: (1,1,0) A160573, (1,1,1) A151552, (1,1,2) A151692, (2,1,0) A151685, (2,1,1) A151691, (1,2,0) A151688 and A152980, (1,2,1) A151550, (2,2,0) A151693, (2,2,1) A151694
Cf. A139250, A151550, A151551, A160573, A151702, A151714.
Sequence in context: A156268 A053257 A151702 * A160418 A168115 A153864
Adjacent sequences: A151549 A151550 A151551 * A151553 A151554 A151555


KEYWORD

nonn


AUTHOR

N. J. A. Sloane, May 19 2009, Dec 26 2009


STATUS

approved



