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!)
A257788 Numbers n such that n^3+prime(n) and n^3-prime(n) are prime. 1
2, 66, 228, 696, 1416, 2172, 3000, 3384, 3732, 4314, 4524, 4554, 5070, 5220, 5412, 5826, 5844, 6636, 7422, 7662, 7932, 8148, 8832, 9528, 10092, 10242, 10746, 11670, 11682, 11820, 12918, 13266, 14430, 14580, 15216, 15300, 15534, 15864, 16542, 16782, 16932, 17670 (list; graph; refs; listen; history; text; internal format)
OFFSET
1,1
COMMENTS
All terms are even.
LINKS
FORMULA
Intersection of A141526 and A212881.
EXAMPLE
2 is in the sequence: 2^3 + prime(2) = 11; 2^3 - prime(2) = 5; both are prime.
66 is in the sequence: 66^3 + prime(66) = 287813; 66^3 - prime(66) = 287179; both are prime.
MATHEMATICA
Select[Range[30000], PrimeQ[#^3 + Prime[#]] && PrimeQ[#^3 - Prime[#]] &]
Select[Range[18000], AllTrue[#^3+{Prime[#], -Prime[#]}, PrimeQ]&] (* Harvey P. Dale, Aug 10 2023 *)
PROG
(PARI) for(n=1, 1e5, if(isprime(n^3 + prime(n)) && isprime(n^3 - prime(n)), print1(n, ", ")))
(Magma) [n: n in [1..20000] | IsPrime(n^3+NthPrime(n)) and IsPrime(n^3-NthPrime(n))];
CROSSREFS
Sequence in context: A098089 A304934 A075809 * A349108 A226409 A226338
KEYWORD
nonn
AUTHOR
K. D. Bajpai, May 12 2015
STATUS
approved

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 19 12:14 EDT 2024. Contains 371792 sequences. (Running on oeis4.)