OFFSET
1,1
LINKS
Amiram Eldar, Table of n, a(n) for n = 1..10000
EXAMPLE
7 is a term since (3, 5, 7) are consecutive primes, 3*5*7 + 2 + 2 - 1 = 108, and 108 +-1 = are twin primes.
MATHEMATICA
lst = {}; Do[p1 = Prime[n]; p2 = Prime[n + 1]; p3 = Prime[n + 2]; d1 = p2 -p1; d2 = p3 - p2; a = p1 * p2 * p3 + d1 + d2 - 1; If[PrimeQ[a - 1] && PrimeQ[a + 1], AppendTo[lst, p3]], {n, 8!}]; lst (* Vladimir Joseph Stephan Orlovsky *)
okQ[{a_, b_, c_}] := Module[{x = a b c + (b - a) + (c - b) - 1}, PrimeQ[x - 1] && PrimeQ[x + 1]]
Transpose[Select[Partition[Prime[Range[15000]], 3, 1], okQ]][[3]] (* Harvey P. Dale, Jan 18 2011 *)
PROG
(Magma) [p3:k in [1..14000]| IsPrime(p1*p2*p3+p3-p1-2) and IsPrime(p1*p2*p3+p3-p1) where p1 is NthPrime(k) where p2 is NthPrime(k+1) where p3 is NthPrime(k+2) ]; // Marius A. Burtea, Dec 31 2019
CROSSREFS
KEYWORD
nonn
AUTHOR
Vladimir Joseph Stephan Orlovsky, Dec 25 2008
STATUS
approved