OFFSET
1,2
COMMENTS
a(4*n)=3*n iff b(2n)=0 where b(1)=1, b(2n)=(b(2n-1)+b(n)) mod 2, b(2n+1)=b(2n)+1
FORMULA
a(n) is asymptotic to 3/4*n.
PROG
(PARI) a(n)=if(n<2, 1, if(n%2, a(n-1)+1, a(n-1)+a(n/2)%2))
CROSSREFS
KEYWORD
nonn
AUTHOR
Benoit Cloitre, Mar 13 2004
STATUS
approved