Logo

Greetings from The On-Line Encyclopedia of Integer Sequences!

Hints

Search: id:A087770
Displaying 1-1 of 1 results found. page 1
     Format: long | short | internal | text      Sort: relevance | references | number      Highlight: on | off
A087770 "Lonely primes": those primes that are locally maximally isolated from the nearest other primes. The differences between each lonely prime and the immediately preceding prime and following primes are both greater than the corresponding differences for all lonely primes earlier in the sequence. +0
2
2, 3, 7, 23, 89, 211, 1847, 2179, 14107, 33247, 38501, 58831, 268343, 1272749, 2198981, 10938023, 72546283, 162821917, 325737821, 2888688863 (list; graph; listen)
OFFSET

0,1

COMMENT

The concept of "lonely prime" is similar to that of maximal prime gaps since lonely primes are increasingly distant from each other.

EXAMPLE

a(0) = 2

a(1) = 3 because 3 - 2 = 1 and 5 - 3 = 2

a(2) = 7 because 7 - 5 = 2 (and 2 > 3 - 2) and 11 - 7 = 4 (and 4 > 5 - 3)

a(3) = 23 because 23 - 19 = 4 ( 23 - 19 > 7 - 5) and 29 - 23 = 6 (29 - 23 > 11 - 7)

a(4) = 89 because 89 - 83 = 6 > 23 - 19 and 97 - 89 = 8 > 29 - 23

Note, for example, that 53 is not a lonely prime because 53 - 47 = 6, which is > 23 - 19 however 59 - 53 = 6, which is not > 29 - 23.

MATHEMATICA

NextPrim[n_] := Block[{k = n + 1}, While[ !PrimeQ[k], k++ ]; k]; p = 2; q = 2; r = 3; d = e = 0; Do[ While[ q - p <= d || r - q <= e, p = q; q = r; r = NextPrim[r]]; Print[q]; d = Max[q - p, d]; e = Max[r - q, e]; p = q; q = r; r = NextPrim[r], {n, 1, 40}] (from Robert G. Wilson v)

CROSSREFS

Cf. A000230, A002386.

Sequence in context: A002386 A000230 A133429 this_sequence A087164 A077213 A112601

Adjacent sequences: A087767 A087768 A087769 this_sequence A087771 A087772 A087773

KEYWORD

nonn

AUTHOR

Walter G. Carlini (541carlini(AT)charter.net), Oct 03 2003

EXTENSIONS

Corrected and extended by Ray Chandler (rayjchandler(AT)sbcglobal.net), Oct 06 2003

page 1

Search completed in 0.002 seconds

Lookup | Welcome | Find friends | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Transforms | Puzzles | Hot | Classics
More pages | Superseeker | Maintained by N. J. A. Sloane (njas@research.att.com)

Last modified July 26 13:41 EDT 2008. Contains 142293 sequences.


AT&T Labs Research