OFFSET
1,2
COMMENTS
This is a permutation of the positive integers.
Apparently, a self-inverse permutation.
The powers of 2 (A000079) are the fixed points.
LINKS
MATHEMATICA
s = {}; Do[j=1; While[ MemberQ[s, j] || (b = BitAnd[j, n]) == 0 || BitAnd[b, b-1] > 0, j++]; AppendTo[s, j], {n, 62}]; s (* Giovanni Resta, Mar 05 2014 *)
PROG
(Perl) See Link section.
CROSSREFS
KEYWORD
nonn
AUTHOR
Paul Tek, Mar 05 2014
STATUS
approved