login
Primes of the form p*q + p + q, where p and q are two successive primes.
17

%I #17 Nov 25 2018 14:43:53

%S 11,23,47,167,251,359,479,719,1847,2111,2591,3719,6719,7559,8819,

%T 10607,12539,14591,19319,27551,29231,31319,51071,53819,68111,97967,

%U 149759,155219,172199,177239,195359,199799,234239,273527,305783,314711,339863

%N Primes of the form p*q + p + q, where p and q are two successive primes.

%C a(n) == 3 mod 4.

%C Primes arising in A126148. - _Jonathan Vos Post_, Mar 08 2007

%C Number of primes <10^n: 0, 3, 8, 15, 26, 49, 99, 220, 514, 1228, 2991, 7746, 20218, 54081, ..., . - _Robert G. Wilson v_

%H Vincenzo Librandi and Charles R Greathouse IV, <a href="/A096342/b096342.txt">Table of n, a(n) for n = 1..10000</a> (first 1000 terms from Librandi)

%e a(4)=167 because 11*13 + 11 + 13=167.

%t a = {}; Do[p = Prime[n]Prime[n + 1] + Prime[n] + Prime[n + 1]; If[ PrimeQ[p], AppendTo[a, p]], {n, 110}]; a (* _Robert G. Wilson v_, Jul 01 2004 *)

%t Select[Times@@#+Total[#]&/@Partition[Prime[Range[200]],2,1],PrimeQ] (* _Harvey P. Dale_, Nov 25 2018 *)

%o (PARI) list(lim)=my(v=List(),p=2,t); forprime(q=3,, t=p*q+p+q; if (t>lim, return(Set(v))); if(isprime(t), listput(v,t)); p=q) \\ _Charles R Greathouse IV_, Sep 15 2015

%Y Cf. A000040, A001043, A006094, A126148, A126199.

%K nonn

%O 1,1

%A _Giovanni Teofilatto_, Jun 29 2004

%E More terms from _Robert G. Wilson v_, Jul 02 2004