OFFSET
1,1
COMMENTS
Every odd prime occurs at least once at positions given by A005097.
LINKS
Robert Israel, Table of n, a(n) for n = 1..825
EXAMPLE
a(4)=29 because 4^1+5^2=29 is prime, whereas 4^1+5^1=9, 4^2+5=21 are composite.
MAPLE
f:= proc(n) local t, pq;
uses priqueue;
initialize(pq);
insert([-2*n-1, 1, 1], pq);
do
t:= extract(pq);
if isprime(-t[1]) then return -t[1] fi;
insert([-n^(t[2]+1)-(n+1)^t[3], t[2]+1, t[3]], pq);
insert([-n^t[2]-(n+1)^(t[3]+1), t[2], t[3]+1], pq);
od;
end proc:
map(f, [$1..60]); # Robert Israel, May 17 2024
CROSSREFS
KEYWORD
nonn,look
AUTHOR
Hugo Pfoertner, Apr 01 2004
STATUS
approved