A206960 a(0)=0, a(1)=1, for n>1, a(n) = n<*>n, where k<*>m = k<+>k<+>...<+>k is the m-1-fold iteration of the operation <+> defined in A206853.
0, 1, 4, 9, 31, 66, 190, 385, 1022, 2055, 5112, 10242, 24572, 49153, 114686, 229377, 524287, 1048590, 2359281, 4718599, 10485753, 20971521, 46137342, 92274689, 201326590, 402653191, 872415224, 1744830466, 3758096380, 7516192769, 16106127358, 32212254721
Offset: 0
Programs
-
Mathematica
f[n_,k_]:=Module[{i=n+1},While[Count[IntegerDigits[BitXor[n,i],2],1]!=k,i++]; i]; Join[{0,1},Table[Nest[f[#,k]&,k,k-1],{k,2,18}]] (* Jayanta Basu, May 26 2013 *)
Formula
Extensions
a(11)-a(31) from Alois P. Heinz, Feb 16 2012
Comments