OFFSET
1,2
EXAMPLE
The nonunit divisors of 22 are 2,11,22 and none of these are binary palindromes.
MAPLE
dmax:= 10: # to get all terms with at most dmax binary digits
N:= 2^dmax-1:
revdigs:= proc(n)
local L, Ln, i;
L:= convert(n, base, 2);
Ln:= nops(L);
add(L[i]*2^(Ln-i), i=1..Ln);
end proc:
P:= {}:
for d from 2 to dmax do
if d::even then
P:= P union {seq(2^(d/2)*x + revdigs(x), x=2^(d/2-1)..2^(d/2)-1)}
else
m:= (d-1)/2;
B:={seq(2^(m+1)*x + revdigs(x), x=2^(m-1)..2^m-1)};
P:= P union B union map(`+`, B, 2^m)
fi
od:
L:= Vector(N, 1):
for t in P do
L[[seq(k, k=t..N, t)]]:= 0
od:
select(t -> L[t]=1, [$1..N]); # Robert Israel, Aug 21 2018
PROG
(PARI) isok(n) = #select(x->((binary(x) == Vecrev(binary(x))) && (x>1)), divisors(n)) == 0; \\ Michel Marcus, Aug 21 2018
CROSSREFS
KEYWORD
nonn,base
AUTHOR
Jeffrey Shallit, Aug 21 2018
STATUS
approved