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.

A099894 XOR BINOMIAL transform of A038712.

This page as a plain text file.
%I A099894 #18 Dec 30 2016 16:04:48
%S A099894 1,2,0,4,0,0,0,8,0,0,0,0,0,0,0,16,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,32,0,
%T A099894 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,64,0,0,0,
%U A099894 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0
%N A099894 XOR BINOMIAL transform of A038712.
%C A099894 See A099884 for the definitions of the XOR BINOMIAL transform and the XOR difference triangle.
%C A099894 a(n) = A062383(n+1) - A062383(n). - _Reinhard Zumkeller_, Aug 06 2009
%C A099894 A038712 has offset 1, but we need to use offset 0 for the XOR BINOMIAL. - _Michael Somos_, Dec 30 2016
%F A099894 a(2^n-1) = 2^n for n>=0 and a(k)=0 otherwise. a(n) = SumXOR_{i=0..n} (C(n, i)mod 2)*A038712(n-i) and SumXOR is summation under XOR.
%F A099894 a(n) = A048298(n+1). - _Michael Somos_, Dec 30 2016
%e A099894 G.f. = 1 + 2*x + 4*x^3 + 8*x^7 + 16*x^15 + 32*x^31 + 64*x^63 + 128*x^127 + ...
%e A099894 XOR difference triangle of A038712 begins:
%e A099894 [1],
%e A099894 [3,2],
%e A099894 [1,2,0],
%e A099894 [7,6,4,4],
%e A099894 [1,6,0,4,0],
%e A099894 [3,2,4,4,0,0],
%e A099894 [1,2,0,4,0,0,0],
%e A099894 [15,14,12,12,8,8,8,8],...
%e A099894 where A038712 is in the leftmost column and A099894 (this sequence) forms the main diagonal.
%e A099894 a(1) = 1*1 XOR 0*1 = 1, a(2) = 1*1 XOR 0*3 XOR 1*1 = 0, a(3) = 1*1 XOR 1*3 XOR 1*1 XOR 1*7 = 4 where (1, 3, 1, 7) are the first four terms of A038712. - _Michael Somos_, Dec 30 2016
%t A099894 a[ n_] := With[ {m = n+1}, If[ m >=0 && Total[ IntegerDigits[ m, 2]] == 1, m, 0]]; (* _Michael Somos_, Dec 30 2016 *)
%o A099894 (PARI) {a(n)=local(B);B=0;for(i=0,n,B=bitxor(B,binomial(n,i)%2*A038712(n-i) ));B}
%o A099894 (PARI) {a(n) = my(m = n+1); m * ( m>=0 && hammingweight(m) == 1)}; /* _Michael Somos_, Dec 30 2016 */
%Y A099894 Cf. A099884, A038712, A099895, A062383, A048298.
%K A099894 nonn
%O A099894 0,2
%A A099894 _Paul D. Hanna_, Oct 29 2004