login

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”).

A026498
a(n) = t(1+3n), where t = A001285 (Thue-Morse sequence).
4
2, 2, 2, 1, 2, 2, 2, 2, 2, 2, 2, 1, 2, 1, 1, 1, 2, 2, 2, 1, 2, 2, 2, 2, 2, 2, 2, 2, 1, 2, 2, 2, 2, 2, 2, 1, 2, 2, 2, 2, 2, 2, 2, 1, 2, 1, 1, 1, 2, 2, 2, 1, 2, 1, 1, 1, 1, 1, 1, 1, 2, 1, 1, 1, 2, 2, 2, 1, 2, 2, 2, 2, 2, 2, 2, 1, 2, 1, 1, 1, 2, 2, 2, 1, 2, 2, 2, 2, 2, 2
OFFSET
0,1
LINKS
MATHEMATICA
Array[1 + Mod[DigitCount[3 # + 1, 2, 1], 2] &, 105, 0] (* Michael De Vlieger, Oct 03 2019 *)
PROG
(PARI) a(n)=1+hammingweight(3*n+1)%2 \\ Charles R Greathouse IV, May 09 2016
CROSSREFS
KEYWORD
nonn
EXTENSIONS
Name and Pari adapted to match offset in A001285 by Sean A. Irvine, Oct 03 2019
STATUS
approved