OFFSET
1,2
COMMENTS
Apparently, every positive integer appears in the sequence.
LINKS
Rémy Sigrist, Table of n, a(n) for n = 1..10000
Rémy Sigrist, Scatterplot of (n, a(n)) for n = 1..10000000
FORMULA
a(n) = 2*a(2*n) - a(2*n + 1).
EXAMPLE
The first terms, alongside k(n) and associate children, are:
n a(n) k(n) a(2*n) a(2*n+1)
-- ---- ---- ------ --------
1 1 1 2 3
2 2 2 4 6
3 3 2 5 7
4 4 4 8 12
5 6 4 10 14
6 5 4 9 13
7 7 4 11 15
8 8 8 16 24
9 12 5 17 22
10 10 8 18 26
PROG
(PARI) lista(nn) = my (a=[1], s=2^a[1]); for (n=1, ceil(nn/2), for (k=1, oo, if (!bittest(s, a[n]+k) && !bittest(s, a[n]+2*k), a=concat(a, [a[n]+k
, a[n]+2*k]); s+=2^(a[n]+k) + 2^(a[n]+2*k); break))); a[1..nn]
CROSSREFS
KEYWORD
nonn
AUTHOR
Rémy Sigrist, Dec 16 2018
EXTENSIONS
Name corrected by Rémy Sigrist, Apr 26 2020
STATUS
approved