OFFSET
1,4
COMMENTS
This sequence is a variant of A165418.
LINKS
FORMULA
EXAMPLE
The first terms, alongside the corresponding k's, are:
n a(n) k's
-- ---- ------------------
1 1 N/A
2 1 {1}
3 1 {1}
4 2 {1, 2}
5 3 {1, 2, 3}
6 3 {1, 2, 3}
7 2 {1, 3}
8 4 {1, 2, 4}
9 8 {1, 2, 3, 4, 5}
10 11 {1, 2, 3, 4, 5, 6}
11 8 {1, 2, 3, 5, 7}
12 8 {1, 2, 3, 4, 6}
13 11 {1, 2, 3, 5, 6, 7}
14 8 {1, 2, 3, 6, 7}
15 4 {1, 3, 7}
16 8 {1, 2, 4, 8}
PROG
(PARI) { for (n=1, #a=vector(64), print1 (a[n]=if (n==1, 1, s = [1]; b = binary(n); for (k=2, #b, s = setunion(s, apply(v -> 2*v+b[k], s))); sum(k=1, #s-1, a[s[k]]); )", ")) }
CROSSREFS
KEYWORD
AUTHOR
Rémy Sigrist, Feb 02 2023
STATUS
approved