login
The OEIS Foundation is supported by donations from users of the OEIS and by a grant from the Simons Foundation.

 

Logo


Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A137771 Prime numbers p such that p +- ((p-1)/8) are primes. 1
241, 433, 1153, 2593, 3121, 5521, 6673, 7393, 8353, 8641, 10513, 13681, 19441, 21121, 22273, 32401, 34273, 43441, 48193, 49201, 54721, 62401, 68881, 69313, 71473, 74161, 77761, 86161, 87121, 104113, 105601, 114913, 116833, 119953 (list; graph; refs; listen; history; text; internal format)
OFFSET

1,1

LINKS

Vincenzo Librandi, Table of n, a(n) for n = 1..1000

EXAMPLE

241+-(240/8) = primes;

433+-(432/8) = primes.

MATHEMATICA

w=8; s=""; For[i=1, i<10^3*2, p=Prime[i]; If[PrimeQ[p-((p-1)/w)]&&PrimeQ[p+((p-1)/w)], (*Print[p, ":", p-((p-1)/w), ", ", p+((p-1)/w)]; *)s=s<>ToString[p]<>", "]; i++ ]; Print[s]

Select[Prime[Range[15000]], PrimeQ[ # + (# - 1)/8] && PrimeQ[ # - (# - 1)/8] &] (* Stefan Steinerberger, May 02 2008 *)

Select[Prime[Range[15000]], AllTrue[#+{(#-1)/8, -(#-1)/8}, PrimeQ]&] (* The program uses the AllTrue function from Mathematica version 10 *) (* Harvey P. Dale, Nov 04 2017 *)

PROG

(MAGMA) [p: p in PrimesInInterval(5, 120000)| IsPrime((9*p-1) div 8 ) and IsPrime((7*p+1) div 8)]; // Vincenzo Librandi, Jun 15 2013

CROSSREFS

Sequence in context: A140629 A325088 A321582 * A342681 A108831 A068706

Adjacent sequences:  A137768 A137769 A137770 * A137772 A137773 A137774

KEYWORD

nonn,easy

AUTHOR

Vladimir Joseph Stephan Orlovsky, Apr 27 2008

EXTENSIONS

More terms from Stefan Steinerberger, May 02 2008

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 July 26 02:10 EDT 2021. Contains 346294 sequences. (Running on oeis4.)