login
This site is supported by donations to The OEIS Foundation.
Logo

Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A123996 Smallest prime q such that the gap between q and the previous prime, p, is a perfect power. 1
3, 11, 97, 1847, 5623, 9587, 89753, 396833, 3851587, 11981587, 70396589, 202551883, 1872852203, 10958688203, 47203303559, 767644375301, 8817792099037, 78610833115937, 497687231721941, 2069461000670881 (list; graph; refs; listen; history; internal format)
OFFSET

1,1

COMMENTS

So far the powers have occurred in numerical order. Here is the list of primes and powers: [11, 4], [97, 8], [1847, 16], [5623, 32], [9587, 36], [89753, 64], [396833, 100], [3851587, 128], [11981587, 144], [70396589, 196], [202551883, 216], [1872852203, 256], [10958688203, 324]. I have searched out to the prime p=26689111613.

LINKS

Thomas R. Nicely, First occurrence prime gaps.

FORMULA

Next prime after A123995.

EXAMPLE

a(2)=97 since 97-prevprime(97)=97-89=8 is the first occurrence of 8 as a difference between successive primes.

MAPLE

with(numtheory); egcd := proc(n::posint) local L; if n>1 then L:=ifactors(n)[2]; L:=map(z->z[2], L); return igcd(op(L)) else return 1 fi end: P:={}; Q:=[]; p:=2; for w to 1 do for k from 0 do # keep track if k mod 10^6 = 0 then print(k, p) fi; lastprime:=p; q:=nextprime(p); d:=q-p; x:=egcd(d); if x>1 and not d in P then P:=P union {d}; Q:=[op(Q), [q, d]]; print(q, d); print(P); print(Q); fi ; p:=q; od od; # let it run with AutoSave enabled.

MATHEMATICA

NextPrim[n_] := Block[{k = n + 1}, While[ !PrimeQ@k, k++ ]; k]; perfectPowerQ[x_] := GCD @@ Last /@ FactorInteger@x > 1; dd = {1}; pp = {2}; qq = {3}; p = 3; Do[q = NextPrim@p; d = q - p; If[perfectPowerQ@d && !MemberQ[dd, d], Print@q; AppendTo[qq, q]; AppendTo[dd, d]]; p = q, {n, 10^7}]; qq (* Robert G. Wilson v *)

CROSSREFS

Cf. A080370, A113472, A000230, A001597, A075090.

Sequence in context: A066384 A120587 A086914 * A201425 A008561 A072640

Adjacent sequences:  A123993 A123994 A123995 * A123997 A123998 A123999

KEYWORD

nonn

AUTHOR

Walter A. Kehowski (wkehowski(AT)cox.net), Oct 31 2006

EXTENSIONS

Edited and extended by Robert G. Wilson v Nov 03 2006, corrected Nov 04 2006

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Transforms | Puzzles | Hot | Classics
Recent Additions | More pages | Superseeker | Maintained by The OEIS Foundation Inc.

Content is available under The OEIS End-User License Agreement .

Last modified February 17 05:54 EST 2012. Contains 205985 sequences.