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!)
A089202 Primes p such that p-2 and p+2 are divisible by a cube. 1

%I

%S 4457,10987,15377,20873,32587,39877,51109,53377,54623,60127,66877,

%T 74873,101873,107377,112997,115589,120877,121123,125197,126443,128873,

%U 135623,143719,148957,155377,161053,161377,162623,168127,169373,174877,176123

%N Primes p such that p-2 and p+2 are divisible by a cube.

%C For any distinct odd primes p,q, includes all primes == 2 (mod p^3) and == -2 (mod q^3), and thus is infinite by Dirichlet's theorem on primes in arithmetic progressions. _Robert Israel_, Jan 11 2019

%H Robert Israel, <a href="/A089202/b089202.txt">Table of n, a(n) for n = 1..10000</a>

%e 4457-2 = 3^4*5*11,4457+2 = 7^3*13

%p filter:= proc(p)

%p isprime(p) and ormap(t -> t[2]>=3, ifactors(p+2)[2]) and ormap(t -> t[2]>=3, ifactors(p-2)[2])

%p end proc:

%p select(filter, [seq(i,i=3..2*10^5,2)]); # _Robert Israel_, Jan 11 2019

%t filterQ[p_] := PrimeQ[p] && AnyTrue[FactorInteger[p-2], #[[2]] >= 3&] && AnyTrue[FactorInteger[p+2], #[[2]] >= 3&];

%t Select[Prime[Range[20000]], filterQ] (* _Jean-François Alcover_, Aug 26 2020 *)

%o (PARI) powerfreep4(n,p,k) = { c=0; pc=0; forprime(x=2,n, pc++; if(!ispowerfree(x-k,p) && !ispowerfree(x+k,p), c++; print1(x","); ) ); print(); print(c","pc","c/pc+.0) } ispowerfree(m,p1) = { flag=1; y=component(factor(m),2); for(i=1,length(y), if(y[i] >= p1,flag=0;break); ); return(flag) }

%K easy,nonn

%O 1,1

%A _Cino Hilliard_, Dec 08 2003

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 August 7 22:13 EDT 2022. Contains 355995 sequences. (Running on oeis4.)