The OEIS mourns the passing of Jim Simons and is grateful to the Simons Foundation for its support of research in many branches of science, including the OEIS.
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!)
A161864 Numbers n such that n^2 + n + 5 and n^2 + n - 5 are both prime. 2
3, 6, 11, 18, 21, 23, 27, 32, 42, 48, 51, 83, 86, 93, 116, 153, 158, 182, 188, 216, 282, 291, 317, 333, 396, 482, 681, 737, 786, 798, 818, 821, 872, 923, 956, 966, 977, 986, 1007, 1026, 1077, 1082, 1106, 1161, 1287, 1292, 1302, 1337, 1341, 1451, 1467, 1563 (list; graph; refs; listen; history; text; internal format)
OFFSET
1,1
LINKS
EXAMPLE
a(1)=3 as 12+-5 are primes. a(2)=6 as 42+-5 are primes.
MAPLE
select(n -> isprime(n^2+n+5) and isprime(n^2+n-5), [$1..2000]); # Robert Israel, Nov 26 2017
MATHEMATICA
q=5; lst5={}; Do[p=n^2+n; If[PrimeQ[p-q]&&PrimeQ[p+q], AppendTo[lst5, n]], {n, 0, 7!}]; lst5
CROSSREFS
Sequence in context: A013932 A302550 A310117 * A351066 A310118 A010335
KEYWORD
nonn,easy
AUTHOR
EXTENSIONS
Definition rephrased by R. J. Mathar, Jun 23 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 | Recents
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified June 3 05:44 EDT 2024. Contains 373054 sequences. (Running on oeis4.)