login
A082498
a(0)=0, a(1)=1, a(2n)=a(n), a(2n+1)=a(n)+a(n-1).
5
0, 1, 1, 1, 1, 2, 1, 2, 1, 2, 2, 3, 1, 3, 2, 3, 1, 3, 2, 3, 2, 4, 3, 5, 1, 4, 3, 4, 2, 5, 3, 5, 1, 4, 3, 4, 2, 5, 3, 5, 2, 5, 4, 6, 3, 7, 5, 8, 1, 6, 4, 5, 3, 7, 4, 7, 2, 6, 5, 7, 3, 8, 5, 8, 1, 6, 4, 5, 3, 7, 4, 7, 2, 6, 5, 7, 3, 8, 5, 8, 2, 7, 5, 7, 4, 9, 6, 10, 3, 9, 7, 10, 5, 12, 8
OFFSET
0,6
LINKS
PROG
(PARI) a(n) = if(n<2, n, if(n%2==0, a(n/2), a((n-1)/2)+a((n-3)/2)))
(Haskell)
a082498 n = a082498_list !! n
a082498_list = 0 : 1 : concat
(zipWith (\u v -> [u, u + v]) (tail a082498_list) a082498_list)
-- Reinhard Zumkeller, Jul 19 2013
CROSSREFS
Cf. A020951.
Sequence in context: A332897 A026904 A057828 * A112223 A324810 A353351
KEYWORD
nonn
AUTHOR
Ralf Stephan, Apr 29 2003
STATUS
approved