login
a(0)=0, a(1)=1, a(2)=0; thereafter, if k>=0 and a block of the first 3*2^k terms is known, then a(3*2^k+i)=1-a(i) for 0<=i<3*2^k.
0

%I #19 Jul 10 2019 02:59:48

%S 0,1,0,1,0,1,1,0,1,0,1,0,1,0,1,0,1,0,0,1,0,1,0,1,1,0,1,0,1,0,0,1,0,1,

%T 0,1,0,1,0,1,0,1,1,0,1,0,1,0,1,0,1,0,1,0,0,1,0,1,0,1,0,1,0,1,0,1,1,0,

%U 1,0,1,0,0,1,0,1,0,1,1,0,1,0,1,0,1,0,1,0,1,0,0

%N a(0)=0, a(1)=1, a(2)=0; thereafter, if k>=0 and a block of the first 3*2^k terms is known, then a(3*2^k+i)=1-a(i) for 0<=i<3*2^k.

%C Take the Thue-Morse sequence 0,1,1,0,1,0,0,1,... and insert (1,0) after each 0 and (0,1) after each 1. This gives : 0,(1,0),1,(0,1),1,(0,1),0,(1,0),1,(0,1),0,(1,0),... and sequence begins 0,1,0,1,0,1,1,0,1,0,1,0,1,0,1,0,1,0,... - _Benoit Cloitre_, Nov 10 2003

%F a(n) = (hammingweight(n\3) + (n%3)) % 2. - _Kevin Ryde_, Sep 09 2017

%K nonn

%O 0,1

%A _Benoit Cloitre_, Apr 25 2003

%E Entries and description corrected by _Kevin Ryde_, Sep 09 2017