OFFSET
0,2
LINKS
Ivan Neretin, Table of n, a(n) for n = 0..10000
FORMULA
a(n) = m + (n-1)/2 for odd n and a(n) = (m + n)/2 for even n, where m is the greatest power of 2 not exceeding n+2. - Ivan Neretin, Sep 05 2017
MATHEMATICA
Fold[Append[#1, If[OddQ[#2], 2 #1[[-1]] - (#2 - 1)/2, Min@Complement[Range[Max[#1] + 1], #1]]] &, {1}, Range[71]] (* Ivan Neretin, Sep 04 2017 *)
CROSSREFS
KEYWORD
nonn
AUTHOR
Paul Curtz, Nov 05 2007
EXTENSIONS
Edited by R. J. Mathar, Nov 16 2007
STATUS
approved