login
The OEIS is supported by the many generous donors to the OEIS Foundation.

 

Logo
Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A226986 Primes p such that both prevprime(p^2) - 2 and nextprime(p^2) + 2 are also primes. 1

%I #19 Apr 21 2023 13:00:56

%S 3,251,409,647,1031,1669,6469,6679,12043,18313,18517,31583,31643,

%T 32957,33479,33529,37783,39733,40163,44071,58441,67189,68279,83009,

%U 83117,83423,87671,90481,96001,98479,112951,120011,130211,149939,152297,155663,156227,158293

%N Primes p such that both prevprime(p^2) - 2 and nextprime(p^2) + 2 are also primes.

%H Charles R Greathouse IV, <a href="/A226986/b226986.txt">Table of n, a(n) for n = 1..10000</a>

%t Select[Prime[Range[15000]],AllTrue[{NextPrime[#^2,-1]-2,NextPrime[ #^2]+2},PrimeQ]&] (* _Harvey P. Dale_, Jun 12 2022 *)

%o (PARI) is(n)=isprime(precprime(n^2)-2) && isprime(nextprime(n^2)+2) && isprime(n) \\ _Charles R Greathouse IV_, Jun 25 2013

%K nonn

%O 1,1

%A _Juri-Stepan Gerasimov_, Jun 25 2013

%E a(3)-a(34) from _Giovanni Resta_, Jun 13 2013

%E a(10) inserted by _Charles R Greathouse IV_, Jun 25 2013

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

License Agreements, Terms of Use, Privacy Policy. .

Last modified April 25 14:08 EDT 2024. Contains 371989 sequences. (Running on oeis4.)