OFFSET
1,4
COMMENTS
LINKS
Rémy Sigrist, Table of n, a(n) for n = 1..25000
Rémy Sigrist, Scatterplot of the first 2^20 terms
Rémy Sigrist, Colored scatterplot of the first 2^20 terms (where the color is function of min(A000120(a(n)), A000120((Max_{k=1..n-1} a(k))+1-a(n))))
FORMULA
a(n) = #{ a(k) such that 0 < k < n and a(k) AND n = 0 } (where AND stands for the bitwise AND operator).
EXAMPLE
The first terms, alongside the distinct earlier terms with no common one bit with n, are:
n a(n) Distinct earlier terms with no common one bit with n
-- ---- ----------------------------------------------------
1 0 {}
2 1 {0}
3 1 {0}
4 2 {0, 1}
5 2 {0, 2}
6 2 {0, 1}
7 1 {0}
8 3 {0, 1, 2}
9 2 {0, 2}
10 2 {0, 1}
11 1 {0}
12 4 {0, 1, 2, 3}
13 2 {0, 2}
14 2 {0, 1}
15 1 {0}
16 5 {0, 1, 2, 3, 4}
17 3 {0, 2, 4}
18 4 {0, 1, 4, 5}
19 2 {0, 4}
20 4 {0, 1, 2, 3}
PROG
(PARI) mx=-1; for (n=1, 86, v=sum(i=0, mx, bitand(i, n)==0); print1(v ", "); mx=max(mx, v))
CROSSREFS
KEYWORD
nonn,base
AUTHOR
Rémy Sigrist, Nov 19 2017
STATUS
approved