%I #8 Jul 03 2013 08:32:30
%S 0,1,0,1,-1,0,-1,0,0,1,0,1,-1,0,-1,0,1,2,1,2,0,1,0,1,1,2,1,2,0,1,0,1,
%T 0,1,0,1,-1,0,-1,0,0,1,0,1,-1,0,-1,0,1,2,1,2,0,1,0,1,1,2,1,2,0,1,0,1,
%U -1,0,-1,0,-2,-1,-2,-1,-1,0,-1,0,-2,-1,-2,-1,0,1,0,1,-1,0,-1,0,0,1,0,1,-1,0,-1,0,-1,0,-1,0,-2,-1,-2,-1,-1,0,-1,0,-2,-1,-2
%N Real part of the function z(n)=Sum(d(k)*i^k: d as in n=Sum(d(k)*2^k), i=sqrt(-1)).
%C A131852(n) = Im(z(n));
%C z(A000079(n))=(A056594(n),A056594(n+3)); a(A000079(n))=A056594(n);
%C a(A131854(n))=0; a(A131861(n))>0; a(A131859(n))=1; a(A131863(n))<0;
%C z(A131853(n))=(0,0); z(A131856(n))=(0,1); z(A131858(n))=(1,0); z(A131860(n))=(1,1);
%C for n>0: a(A131865(n))=n and ABS(a(m))<n for m < A131865(n).
%H R. Zumkeller, <a href="/A131851/b131851.txt">Table of n, a(n) for n = 0..10000</a>
%F z(n) = if n=0 then (0, 0) else z(floor(n/2))*(0, 1) + (n mod 2, 0), complex multiplication.
%t z[0] = 0; z[n_] := z[n] = z[Floor[n/2]]*I + Mod[n, 2]; Table[z[n] // Re, {n, 0, 110}] (* _Jean-François Alcover_, Jul 03 2013 *)
%Y Cf. A007088.
%K sign
%O 0,18
%A _Reinhard Zumkeller_, Jul 22 2007