cp's OEIS Frontend

This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.

A279624 Numbers x such that BCR(x) = R(x), where BCR = binary-complement-and-reverse = take one's complement then reverse bit order and R(x) is the digits reverse of n.

Original entry on oeis.org

2, 61, 212, 232, 666, 868, 2222, 642246, 687588, 820491, 885786, 2283822, 2459542, 2807082, 2860682, 45377354, 214878412, 841191148, 841740971, 49126162194
Offset: 1

Views

Author

Paolo P. Lava, Dec 16 2016

Keywords

Examples

			687588 in base 2 is 10100111110111100100. Its binary-complement-and-reverse is 11011000010000011010, which is 885786 in base 10.
		

Crossrefs

Programs

  • Maple
    with(numtheory): T:=proc(w) local x, y, z; x:=w; y:=0;
    for z from 1 to ilog10(x)+1 do y:=10*y+(x mod 10); x:=trunc(x/10); od; y; end:
    P:=proc(q) local a,b, k,n; for n from 1 to q do a:=convert(n,base,2); b:=0;
    for k from 1 to nops(a) do if a[k]=0 then a[k]:=1 else a[k]:=0; fi; b:=2*b+a[k]; od;
    if b=n then print(n); fi; od; end: P(10^6);
  • Mathematica
    Select[Range[10^6], MatchQ @@ {FromDigits[#, 2] &@ Reverse[ IntegerDigits[#, 2] /. {0 -> 1, 1 -> 0}], FromDigits@ Reverse@ IntegerDigits@ #} &] (* Michael De Vlieger, Dec 16 2016 *)

Extensions

a(17)-a(20) from Hans Havermann, Dec 23 2016