login
Perfect powers which are the sum of two consecutive primes.
1

%I #11 Jan 22 2019 20:48:11

%S 8,36,100,128,144,216,576,1764,2304,3844,5184,7056,8100,8192,12100,

%T 14400,14884,21952,30276,41616,43264,48400,53824,57600,69696,74088,

%U 93636,106276,112896,138384,148996,166464,168100,197136,206116,207936,219024,220900,224676,272484,279936

%N Perfect powers which are the sum of two consecutive primes.

%H Jens Kruse Andersen, <a href="/A245360/b245360.txt">Table of n, a(n) for n = 1..10000</a>

%e 47 + 53 = 100 = 10^2, so 100 is a member of this sequence.

%t Select[Total/@Partition[Prime[Range[13100]],2,1],GCD@@FactorInteger[#][[All,2]]>1&] (* _Harvey P. Dale_, Jan 22 2019 *)

%o (PARI) for(n=1,10^5,q=prime(n)+prime(n+1);if(ispower(q),print1(q,", ")))

%o (PARI) m=10^8; v=[]; forstep(b=2, sqrt(m), 2, forprime(p=2, 40, n=b^p; if(n>m,break); if(n==precprime(n/2)+nextprime(n/2+1), v=concat(v,n)))); v=vecsort(v) \\ Faster program. _Jens Kruse Andersen_, Jul 20 2014

%Y Cf. A091624, A062703, A226524.

%K nonn

%O 1,1

%A _Derek Orr_, Jul 18 2014