A081434 Numbers such that RevBinary() = RevDecimal(), where RevDecimal(n) is the decimal reversal of n (A004086) and RevBinary(n) is the binary reversal of n (A030101).
0, 1, 3, 5, 7, 9, 33, 92, 99, 313, 585, 717, 732, 759, 957, 5485, 5845, 7447, 9009, 15351, 32223, 39993, 53235, 53835, 71869, 73737, 77360, 96817, 319773, 377913, 585585, 1758571, 1934391, 1979791, 3129213, 5071705, 5259525, 5841485, 13162800
Offset: 1
Links
- Amiram Eldar, Table of n, a(n) for n = 1..55
Programs
-
Mathematica
Select[Range[0, 100000], SameQ @@ IntegerReverse[#, {2, 10}] &] (* Amiram Eldar, Aug 05 2025 *)
-
PARI
isok(k) = fromdigits(Vecrev(binary(k)), 2) == fromdigits(Vecrev(digits(k))); \\ Amiram Eldar, Aug 05 2025
-
Python
def ok(n): return int(bin(n)[:1:-1], 2) == int(str(n)[::-1]) print([k for k in range(10**7) if ok(k)]) # Michael S. Branicky, Jan 30 2023
Extensions
More terms from Harry J. Smith, Dec 19 2007