OFFSET
1,1
EXAMPLE
Anti-divisors of 109 are 2, 3, 7, 31, 73 that are all prime numbers
MAPLE
with(numtheory);
P:=proc(i)
local a, b, c, k, j, n, ok;
for n from 3 by 1 to i do
j:=ithprime(n); a:={};
for k from 2 to j-1 do
if abs((j mod k)- k/2) < 1 then a:=a union {k}; fi;
od;
b:=nops(a); c:=op(a);
if b>1 then
ok:=1;
for k from 1 to b do
if (not isprime(c[k])) then ok:=0; break; fi;
od;
if ok=1 then print(j); fi;
else
if isprime(op(a)) then print(j); fi;
fi;
od;
end:
CROSSREFS
KEYWORD
nonn,easy
AUTHOR
Paolo P. Lava, Jul 15 2011
STATUS
approved