%I #21 Mar 30 2021 18:58:16
%S 0,1,1,7,1,13,7,43,1,19,13,85,7,85,43,259,1,25,19,127,13,163,85,517,7,
%T 127,85,553,43,517,259,1555,1,31,25,169,19,241,127,775,13,241,163,
%U 1063,85,1027,517,3109,7,169,127,847,85,1063,553,3361,43,775,517,3361,259,3109,1555,9331,1
%N a(0) = 0, a(1) = 1; a(2*n) = a(n), a(2*n+1) = 6*a(n) + a(n+1).
%H Alois P. Heinz, <a href="/A342603/b342603.txt">Table of n, a(n) for n = 0..16384</a>
%F G.f.: x * Product_{k>=0} (1 + x^(2^k) + 6*x^(2^(k+1))).
%F a(2^n-1) = (6^n - 1)/5 = A003464(n); a(2^n) = 1; a(2^n+1) = 6*n + 1 = A016921(n). - _Alois P. Heinz_, Mar 17 2021
%p a:= proc(n) option remember; `if`(n<2, n, (q->
%p `if`(d=1, 6*a(q)+a(q+1), a(q)))(iquo(n, 2, 'd')))
%p end:
%p seq(a(n), n=0..70); # _Alois P. Heinz_, Mar 17 2021
%t a[0] = 0; a[1] = 1; a[n_] := If[EvenQ[n], a[n/2], 6 a[(n - 1)/2] + a[(n + 1)/2]]; Table[a[n], {n, 0, 64}]
%t nmax = 64; CoefficientList[Series[x Product[(1 + x^(2^k) + 6 x^(2^(k + 1))), {k, 0, Floor[Log[2, nmax]] + 1}], {x, 0, nmax}], x]
%Y Cf. A002487, A003464, A016921, A116528, A178243, A342633, A342634, A342635, A342636, A342637, A342638.
%K nonn
%O 0,4
%A _Ilya Gutkovskiy_, Mar 17 2021