Logo

Greetings from The On-Line Encyclopedia of Integer Sequences!

Hints

Search: id:A087383
Displaying 1-1 of 1 results found. page 1
     Format: long | short | internal | text      Sort: relevance | references | number      Highlight: on | off
A087383 Numbers n such that prime(prime(n)) and n are twin primes. +0
1
3, 5, 7, 13, 29, 41, 43, 59, 71, 103, 107, 137, 149, 193, 199, 271, 281, 311, 347, 349, 433, 463, 569, 617, 619, 811, 827, 857, 859, 881, 1031, 1153, 1229, 1289, 1481, 1607, 1699, 1723, 1933, 1949, 1951, 1997, 2113, 2551, 2593, 2657, 3001, 3257, 3373, 3463 (list; graph; listen)
OFFSET

1,1

EXAMPLE

The 29th prime is 109 and prime(109) is 599 paired with the prime 601.

MATHEMATICA

TwinPrimeQ[n_]:=If[PrimeQ[n], If[PrimeQ[n-2]||PrimeQ[n+2], True, False], False](*TwinPrimeQ*) lst={}; Do[If[TwinPrimeQ[Prime[Prime[n]]]&&TwinPrimeQ[n], AppendTo[lst, n]], {n, 7!}]; lst [From Vladimir Orlovsky (4vladimir(AT)gmail.com), Sep 07 2008]

PROGRAM

(PARI) twips(n) = { c1=0; c2=0; forprime(x=3, n, if(isprime(x+2), c1++); x1=prime(prime(x)); if(isprime(x-2) || isprime(x+2), if(isprime(x1-2) || isprime(x1+2), print1(x", "); c2++; ) ) ); print(); print(c2/c1+.0) }

CROSSREFS

Sequence in context: A024946 A096177 A128547 this_sequence A038928 A089740 A047933

Adjacent sequences: A087380 A087381 A087382 this_sequence A087384 A087385 A087386

KEYWORD

easy,nonn

AUTHOR

Cino Hilliard (hillcino368(AT)gmail.com), Oct 21 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 December 20 16:54 EST 2009. Contains 171081 sequences.


AT&T Labs Research