OFFSET
2,1
COMMENTS
LINKS
Robert Israel, Table of n, a(n) for n = 2..10000
FORMULA
(a(k) + prime(k)) mod (2*prime(k+1)) = 0.
EXAMPLE
a(3) = 23 is the least prime == -5 (mod 14), where prime(3) = 5 and prime(4) = 7.
MAPLE
f:= proc(n) local k;
for k from 2*ithprime(n+1)-ithprime(n) by 2*ithprime(n+1) do
if isprime(k) then return k fi
od;
end proc:
map(f, [$2..100]);
PROG
(PARI) a(n) = forprime(p=2, , if (Mod(p, 2*prime(n+1)) == -prime(n), return (p))); \\ Michel Marcus, Feb 25 2021
CROSSREFS
KEYWORD
nonn,look
AUTHOR
J. M. Bergot and Robert Israel, Feb 25 2021
STATUS
approved