login
Numbers n such that n is prime and is equal to the product of the first k primes minus the sum of the first k primes, for some k.
1

%I #7 Dec 19 2018 03:44:31

%S 193,29989,13082761331669749

%N Numbers n such that n is prime and is equal to the product of the first k primes minus the sum of the first k primes, for some k.

%C It is in the spirit of A096345 (only for 2 consecutive primes).

%C The corresponding values of k are 4, 6, 14, 548, 1190, ... a(4) = 2.452... * 10^1691, a(5) = 1.263... x 10^4142. - _Amiram Eldar_, Dec 19 2018

%e 193 = -(2+3+5+7)+(2*3*5*7) and 193 is prime.

%t tb = {}; Do[pq = -Plus @@ Prime[Range[1, k]] + Times @@ Prime[Range[1, k]]; If[PrimeQ[pq], AppendTo[tb, pq]], {k, 1, 200}]; tb

%Y Cf. A096345, A096342, A120850.

%K nonn,bref

%O 1,1

%A _Carlos Alves_, Jul 08 2006

%E The next term is too large to include.