OFFSET
1,2
COMMENTS
This sequence is a permutation of the positive integers.
[Proof from N. J. A. Sloane, Apr 20 2022: a(n) always exists, so the sequence is infinite. Every time n is a power of 2, n-reversed is 1, and a(n) is the smallest missing number. Since there are infinitely many powers of 2, every number will eventually appear.]
LINKS
Michael De Vlieger, Table of n, a(n) for n = 1..10000, first 1000 terms from Diana L. Mecum.
Michael De Vlieger, Extended Table of n, a(n) for n = 1..2^16.
Michael De Vlieger, Scatterplot of a(n), n = 1..2^16.
Michael De Vlieger, Log-log scatterplot of a(n), n = 1..2^16.
EXAMPLE
12 in binary is 1100; so its binary reversal is 0011, which is 3 in decimal. Those positive integers not among the first 11 terms of the sequence are 6,8,10,11,14,..., and the third of these is 10, so a(12) = 10.
MATHEMATICA
Block[{a = {1}, nn = 69}, Do[AppendTo[a, #] &@ Complement[Range[i + 2 nn], #][[FromDigits[#, 2] &@ Reverse@ IntegerDigits[i, 2]]] &@ a, {i, 2, nn}]; a] (* Michael De Vlieger, Sep 03 2017 *)
CROSSREFS
KEYWORD
AUTHOR
Leroy Quet, May 19 2006
EXTENSIONS
More terms from Diana L. Mecum, Jul 21 2008
STATUS
approved