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.

A099892 XOR BINOMIAL transform of A003188 (Gray code numbers); also the main diagonal of the XOR difference triangle A099891.

This page as a plain text file.
%I A099892 #24 May 23 2025 10:42:02
%S A099892 0,1,3,0,6,0,0,0,12,0,0,0,0,0,0,0,24,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,48,
%T A099892 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,0,0,96,0,0,
%U A099892 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0
%N A099892 XOR BINOMIAL transform of A003188 (Gray code numbers); also the main diagonal of the XOR difference triangle A099891.
%C A099892 See A099884 for the definitions of the XOR BINOMIAL transform and the XOR difference triangle.
%F A099892 a(2^n) = 3*2^(n-1) for n>0, with a(0)=0, a(1) = 1 and a(k)=0 otherwise. a(n) = SumXOR_{i=0..n} (C(n, i)mod 2)*A003188(n-i), where A003188(k)=bitxor(k, [k/2]) and SumXOR is summation under XOR.
%F A099892 Multiplicative with a(2^e) = 3*2^(e-1), a(p^e) = 0 otherwise. - _David W. Wilson_, Jun 12 2005
%F A099892 Dirichlet g.f.: (2^s+1)/(2^s-2). - _R. J. Mathar_, Apr 14 2011
%t A099892 a[n_] := Module[{e = IntegerExponent[n, 2]}, Switch[n, 0, 0, 1, 1, 2^e, 3*2^(e - 1), _, 0]]; Array[a, 100, 0] (* _Amiram Eldar_, Aug 31 2023, corrected by _Michael Shamos_, May 22 2025 *)
%o A099892 (PARI) {a(n)=local(B);B=0;for(i=0,n,B=bitxor(B,binomial(n,i)%2*(bitxor((n-i),(n-i)\2))));B}
%Y A099892 Cf. A099884, A003188, A099891.
%K A099892 nonn,easy,mult
%O A099892 0,3
%A A099892 _Paul D. Hanna_, Oct 29 2004