A026492 a(n) = t(3n), where t = A001285 (Thue-Morse sequence).
1, 1, 1, 1, 1, 1, 1, 2, 1, 1, 1, 1, 1, 1, 2, 1, 1, 1, 1, 1, 1, 1, 1, 2, 1, 1, 1, 2, 2, 2, 1, 2, 1, 1, 1, 1, 1, 1, 1, 2, 1, 1, 1, 1, 1, 1, 2, 1, 1, 1, 1, 1, 1, 1, 2, 1, 2, 2, 2, 1, 1, 1, 2, 1, 1, 1, 1, 1, 1, 1, 1, 2, 1, 1, 1, 1, 1, 1, 2, 1, 1, 1, 1, 1, 1, 1, 1, 2, 1, 1
Offset: 0
Keywords
Links
- Michael De Vlieger, Table of n, a(n) for n = 0..10000
- Michael Gilleland, Some Self-Similar Integer Sequences
Programs
-
Mathematica
Array[1 + Mod[DigitCount[3 #, 2, 1], 2] &, 105, 0] (* Michael De Vlieger, Oct 03 2019 *)
-
PARI
a(n)=1+hammingweight(3*n)%2 \\ Charles R Greathouse IV, May 09 2016
Extensions
Name and Pari adapted to match offset in A001285 by Sean A. Irvine, Oct 02 2019