A327700 Primes p such that p + q*(q-p) and q + p*(q-p) are prime, where q is the next prime after p.
2, 3, 5, 23, 59, 61, 83, 151, 233, 263, 269, 293, 373, 401, 433, 503, 541, 619, 701, 971, 1103, 1433, 1493, 1601, 1621, 1861, 1949, 2099, 2179, 2371, 2441, 2543, 2741, 2851, 2903, 2999, 3083, 3181, 3313, 3413, 3559, 3631, 4073, 4093, 4549, 4591, 4643, 5039, 5081, 5471, 5711, 5749
Offset: 1
Keywords
Links
- Robert Israel, Table of n, a(n) for n = 1..10000
Crossrefs
Includes A174920.
Programs
-
Maple
R:= NULL: count:= 0: q:= 2: do p:= q; q:= nextprime(p); if isprime(p+(q-p)*q) and isprime(q+(q-p)*p) then count:= count+1; R:= R, p; if count = 100 then break fi fi od: R;
-
Mathematica
Do[a=Prime[k]+Prime[k+1]*(Prime[k+1]-Prime[k]);b=Prime[k+1]+Prime[k]*(Prime[k+1]-Prime[k]);If[PrimeQ[a]&&PrimeQ[b],Print[Prime[k]]],{k,1,757}] (* Metin Sariyar, Sep 23 2019 *) chpQ[{a_,b_}]:=AllTrue[{a+b(b-a),b+a(b-a)},PrimeQ]; Select[Partition[ Prime[ Range[800]],2,1],chpQ][[All,1]] (* Requires Mathematica version 10 or later *) (* Harvey P. Dale, Jul 05 2021 *)