cp's OEIS Frontend

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.

A104117 For n=2^k, a(n) = k+1, else 0.

This page as a plain text file.
%I A104117 #25 Aug 31 2023 05:27:54
%S A104117 1,2,0,3,0,0,0,4,0,0,0,0,0,0,0,5,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,6,0,0,
%T A104117 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,7,0,0,0,0,
%U A104117 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0
%N A104117 For n=2^k, a(n) = k+1, else 0.
%C A104117 Row sums of A103994 (conjectured).
%F A104117 a(n) = 1 + log_2(n), for n = 1, 2, 4, 8, ... and the rest zeros.
%F A104117 Dirichlet g.f.: 1/(1-2^(-s))^2, i.e., Dirichlet convolution of A036987 (right-shifted, assuming offset 1 there) with itself.
%F A104117 Multiplicative with a(2^e) = 1+e, and a(p^e) = 0 for odd primes p and e>=1. Dirichlet convolution square of A209229. - _R. J. Mathar_, Mar 12 2012
%e A104117 a(8) = 4 = sum of row 8 terms of A103994: (1 + 1 + 0 + 1 + 0 + 0 + 0 + 1).
%e A104117 a(8) = 4 = 1 + log_2(8).
%t A104117 a[n_] := Module[{e = IntegerExponent[n, 2]}, If[n == 2^e, e+1, 0]]; Array[a, 100] (* _Amiram Eldar_, Aug 31 2023 *)
%o A104117 (PARI) a(n)=direuler(p=1,n,if(p==2,1/(1-X)^2,1))[n] /* _Ralf Stephan_, Mar 28 2015 */
%o A104117 (PARI) a(n)=if(n==2^valuation(n,2),valuation(n,2)+1,0) /* _Ralf Stephan_, Mar 28 2015 */
%Y A104117 Cf. A036987, A103994, A209229.
%K A104117 nonn,easy,mult
%O A104117 1,2
%A A104117 _Gary W. Adamson_, Apr 15 2007
%E A104117 More terms and better name from _Ralf Stephan_, Mar 28 2015