A162958 Equals A162956 convolved with (1, 3, 3, 3, ...).
1, 4, 10, 19, 25, 40, 67, 94, 100, 115, 142, 175, 208, 280, 388, 469, 475, 490, 517, 550, 583, 655, 763, 850, 883, 955, 1069, 1201, 1372, 1696, 2101, 2344, 2350, 2365, 2392, 2425, 2458, 2530, 2638, 2725, 2758, 2830, 2944, 3076, 3247, 3571, 3976, 4225, 4258
Offset: 1
Keywords
Links
- Alois P. Heinz, Table of n, a(n) for n = 1..16384
- David Applegate, Omar E. Pol and N. J. A. Sloane, The Toothpick Sequence and Other Sequences from Cellular Automata, Congressus Numerantium, Vol. 206 (2010), 157-191. [There is a typo in Theorem 6: (13) should read u(n) = 4.3^(wt(n-1)-1) for n >= 2.]
- N. J. A. Sloane, Catalog of Toothpick and Cellular Automata Sequences in the OEIS
Programs
-
Maple
b:= proc(n) option remember; `if`(n<2, n, (j-> 3*b(j)+b(j+1))(n-2^ilog2(n))) end: a:= proc(n) option remember; `if`(n=0, 0, a(n-1)+2*b(n-1)+b(n)) end: seq(a(n), n=1..100); # Alois P. Heinz, Jan 28 2017
-
Mathematica
b[n_] := b[n] = If[n<2, n, Function[j, 3*b[j]+b[j+1]][n-2^Floor[Log[2, n]] ]]; a[n_] := a[n] = If[n == 0, 0, a[n-1] + 2*b[n-1] + b[n]]; Array[a, 100] (* Jean-François Alcover, Jun 11 2018, after Alois P. Heinz *)
Extensions
Clarified definition by Omar E. Pol, Feb 06 2017
Comments