Year-end appeal: Please make a donation to the OEIS Foundation to support ongoing development and maintenance of the OEIS. We are now in our 61st year, we have over 378,000 sequences, and we’ve reached 11,000 citations (which often say “discovered thanks to the OEIS”).
%I #16 May 07 2020 19:38:18
%S 0,-1,-1,-2,0,-1,-1,-2,2,1,1,0,2,1,1,0,4,3,3,2,4,3,3,2,6,5,5,4,6,5,5,
%T 4,4,3,3,2,4,3,3,2,6,5,5,4,6,5,5,4,8,7,7,6,8,7,7,6,10,9,9,8,10,9,9,8,
%U 0,-1,-1,-2,0,-1,-1,-2,2,1,1,0,2,1,1,0,4,3
%N Let S be the sequence generated by these rules: 0 is in S, and if z is in S, then z * (1+i) and (z-1) * (1+i) + 1 are in S (where i denotes the imaginary unit), and duplicates are deleted as they occur; a(n) = the imaginary part of the n-th term of S.
%C See A290884 for the real part of the n-th term of S, and additional comments.
%C See A290886 for the square of the norm of the n-th term of S.
%H Rémy Sigrist, <a href="/A290885/b290885.txt">Table of n, a(n) for n = 1..10000</a>
%H Rémy Sigrist, <a href="/A290885/a290885.gp.txt">PARI program for A290885</a>
%e Let f be the function z -> z * (1+i), and g the function z -> (z-1) * (1+i) + 1.
%e S(1) = 0 by definition; so a(1) = 0.
%e f(S(1)) = 0 has already occurred.
%e g(S(1)) = -i has not yet occurred; so S(2) = -i and a(2) = -1.
%e f(S(2)) = 1 - i has not yet occurred; so S(3) = 1 - i and a(3) = -1.
%e g(S(2)) = 1 - 2*i has not yet occurred; so S(4) = 1 - 2*i and a(4) = -2.
%e f(S(3)) = 2 has not yet occurred; so S(5) = 2 and a(5) = 0.
%e g(S(3)) = 2 - i has not yet occurred; so S(6) = 2 - i and a(6) = -1.
%e f(S(4)) = 3 - i has not yet occurred; so S(7) = 3 - i and a(7) = -1.
%e g(S(4)) = 3 - 2*i has not yet occurred; so S(8) = 3 - 2*i and a(8) = -2.
%o (PARI) See Links section.
%o (PARI) a(n) = -real(subst(Pol(binary(n-1)),'x,I+1)); \\ _Kevin Ryde_, Apr 08 2020
%Y Cf. A290537, A290884, A290886.
%K sign,look
%O 1,4
%A _Rémy Sigrist_, Aug 13 2017