login
Difference between 2 consecutive primes between which a nontrivial power of prime is found.
1

%I #14 Mar 23 2020 13:22:08

%S 2,4,4,4,6,6,6,6,6,4,14,14,4,6,10,6,10,10,8,12,18,12,6,14,14,10,34,6,

%T 24,14,14,24,24,6,12,16,16,22,8,6,10,10,12,10,18,10,6,16,8,18,10,18,6,

%U 20,20,34,18,14,10,12,30,24,8,16,14,6,36,20,12,28,12,10,12,14,20,22,22

%N Difference between 2 consecutive primes between which a nontrivial power of prime is found.

%H Michel Marcus, <a href="/A060849/b060849.txt">Table of n, a(n) for n = 1..10000</a>

%F a(n) = nextprime(A246547(n)) - prevprime(A246547(n)) = A013633(A246547(n)). [corrected by _Michel Marcus_, Mar 23 2020]

%e 59049=3^10 is between 59029 and 59051, so the corresponding term is 59051-59029=22.

%o (PARI) ispp(n) = isprimepower(n) >= 2; \\ A246547

%o lista(nn) = {for (n=1, nn, if (ispp(n), print1(nextprime(n) - precprime(n), ", ")););} \\ _Michel Marcus_, Mar 23 2020

%Y Cf. A246547, A007917, A007918, A013632, A013633, A049711.

%K nonn

%O 1,1

%A _Labos Elemer_, May 03 2001