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

 

Logo


Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A158754 Courteous prime numbers. 1
31, 41, 101, 109, 137, 191, 193, 239, 283, 311, 313, 569, 641, 659, 661, 821, 1091, 1153, 1289, 1291, 1301, 1303, 1319, 1429, 1453, 1619, 1667, 1877, 2027, 2081, 2129, 2239, 2309, 2341, 2381, 2591, 2593, 2711, 2713, 2971, 3001, 3121, 3253, 3299, 3301 (list; graph; refs; listen; history; text; internal format)
OFFSET

1,1

COMMENTS

Courteous prime numbers are twin prime numbers and can be written as the sum of two or more consecutive twin prime numbers. 7+11+13=31,11+13+17=41,..

LINKS

Table of n, a(n) for n=1..45.

MATHEMATICA

lst={}; Do[pp=Prime[m]; If[PrimeQ[pp-2]||PrimeQ[pp+2], k=1; Do[k++; p=Prime[n]; If[PrimeQ[p-2]||PrimeQ[p+2], pp+=p; If[PrimeQ[pp], If[PrimeQ[pp-2]||PrimeQ[pp+2], AppendTo[lst, pp]]]], {n, m+1, 4*6!}]], {m, 1, 4*6!}]; lst; (*Courteous Prime Numbers.*)Take[Union[lst], 5! ]

upto=3400; With[{tps=Union[Flatten[Select[Partition[Prime[Range[ PrimePi[ upto]]], 2, 1], Last[#]-First[#]==2&]]]}, Select[Union[Flatten[Table[ Total/@Partition[tps, n, 1], {n, 2, 40}]]], MemberQ[tps, #]&&#<=upto&]] (* Harvey P. Dale, Sep 25 2011 *)

CROSSREFS

Cf. A138591, A065867

Sequence in context: A284531 A040987 A040180 * A140458 A101520 A225862

Adjacent sequences:  A158751 A158752 A158753 * A158755 A158756 A158757

KEYWORD

nonn

AUTHOR

Vladimir Joseph Stephan Orlovsky, Mar 25 2009

STATUS

approved

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recent
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified October 16 05:32 EDT 2019. Contains 328044 sequences. (Running on oeis4.)