This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.
%I A083661 #17 Jul 16 2023 02:07:25 %S A083661 0,0,0,1,0,1,0,2,1,1,0,2,1,1,0,3,2,2,1,2,1,1,0,3,2,2,1,2,1,1,0,4,3,3, %T A083661 2,3,2,2,1,3,2,2,1,2,1,1,0,4,3,3,2,3,2,2,1,3,2,2,1,2,1,1,0,5,4,4,3,4, %U A083661 3,3,2,4,3,3,2,3,2,2,1,4,3,3,2,3,2,2,1,3,2,2,1,2,1 %N A083661 G.f.: 1/(1-x) * Sum_{k>=0} x^2^(k+2)/(1+x^2^k). %H A083661 Amiram Eldar, <a href="/A083661/b083661.txt">Table of n, a(n) for n = 1..10000</a> %H A083661 Ralf Stephan, <a href="/somedcgf.html">Some divide-and-conquer sequences with (relatively) simple ordinary generating functions</a>, 2004. %H A083661 Ralf Stephan, <a href="/A079944/a079944.ps">Table of generating functions</a>. %F A083661 a(1) = a(2) = a(3) = 0, a(2n) = a(n)+1, a(2n+1) = a(n). %F A083661 a(n) = A080791(n) + A079944(n-2) - 1. %t A083661 a[n_] := DigitCount[n, 2, 0] + IntegerDigits[n, 2][[2]] - 1; a[1] = 0; Array[a, 100] (* _Amiram Eldar_, Jul 16 2023 *) %o A083661 (PARI) for(n=1, 120, l=ceil(log(n)/log(2)); t=polcoeff(1/(1-x)*sum(k=0, l, (x^2^(k+2))/(1+x^2^k)) + O(x^(n+1)), n); print1(t", ")) %Y A083661 Cf. A000120, A023416, A079944, A080791. %K A083661 nonn,easy %O A083661 1,8 %A A083661 _Ralf Stephan_, Jun 14 2003