A178620 Sum of binary digits ( = sum of ternary digits ) of terms in A037301.
0, 1, 2, 3, 2, 3, 2, 3, 2, 3, 3, 2, 3, 4, 5, 4, 5, 4, 5, 4, 4, 4, 5, 4, 5, 4, 5, 4, 5, 4, 5, 4, 5, 4, 5, 4, 5, 6, 7, 3, 3, 4, 5, 5, 4, 5, 4, 5, 4, 5, 5, 6, 7, 4, 4, 5, 5, 5, 4, 5, 5, 4, 5, 6, 7, 5, 7, 6, 4, 5, 4, 5, 6, 7, 6, 7, 6, 7, 6, 7, 7, 7, 6, 4, 5, 4, 5, 6, 7, 4, 5, 5, 6, 7, 6, 7, 6, 7, 5, 5, 7, 4, 5, 6, 6
Offset: 0
Links
- G. C. Greubel, Table of n, a(n) for n = 0..10000
Crossrefs
Cf. A037301 (sum of base 2 digits of n) = (sum of base 3 digits of n).
Programs
-
Mathematica
s = {}; Do[id3 = IntegerDigits[n, 3]; id2 = IntegerDigits[n, 2]; If[(t = Total[id2]) == Total[id3], AppendTo[s, t]], {n, 0, 10^3}]; s
Comments