Smallest number distinct from n, not occurring earlier and having in binary representation exactly as many ones as n.

A094510

Smallest number distinct from n, not occurring earlier and having in binary representation exactly as many ones as n.

Terms

    a(0) =2a(1) =1a(2) =5a(3) =8a(4) =3a(5) =9a(6) =11a(7) =4a(8) =6a(9) =12a(10) =7a(11) =10a(12) =14a(13) =13a(14) =23a(15) =32a(16) =18a(17) =17a(18) =21a(19) =24a(20) =19a(21) =25a(22) =15a(23) =20a(24) =22a(25) =28a(26) =29a(27) =26a(28) =27a(29) =39

External references