login
A244570
Smallest prime p >= prime(n) such that p*prime(n)+2 is prime.
6
3, 7, 11, 19, 17, 37, 23, 37, 43, 47, 47, 61, 53, 73, 109, 79, 89, 71, 109, 227, 113, 97, 139, 137, 127, 149, 127, 131, 283, 137, 139, 181, 173, 151, 167, 191, 173, 193, 193, 181, 239, 199, 233, 223, 239, 251, 239, 241, 233, 313, 241, 251, 271, 277, 373, 271
OFFSET
2,1
COMMENTS
See comment in A244572.
LINKS
V. Shevelev, Theorems on twin primes-dual case, arXiv:0912.4006 [math.GM], 2009-2014. Sections 10,14.
MATHEMATICA
a[n_] := For[p = Prime[n], True, p = NextPrime[p], If[PrimeQ[p Prime[n] + 2], Return[p]]];
Table[a[n], {n, 2, 60}] (* Jean-François Alcover, Nov 18 2018 *)
sp[n_]:=Module[{p=n}, While[CompositeQ[p*n+2], p=NextPrime[p]]; p]; Table[ sp[k], {k, Prime[Range[2, 60]]}] (* Requires Mathematica version 10 or later *) (* Harvey P. Dale, Jan 19 2020 *)
PROG
(PARI) s=[]; for(n=2, 100, p=q=prime(n); while(!isprime(p*q+2), p=nextprime(p+1)); s=concat(s, p)); s \\ Colin Barker, Jun 30 2014
CROSSREFS
Sequence in context: A335323 A097748 A255000 * A049645 A167181 A049835
KEYWORD
nonn
AUTHOR
Vladimir Shevelev, Jun 30 2014
EXTENSIONS
More terms from Peter J. C. Moses, Jun 30 2014
STATUS
approved