cp's OEIS Frontend

This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.

A240838 Primes p such that prime(p) + 2*p^2 is prime.

Original entry on oeis.org

2, 3, 5, 13, 41, 43, 139, 173, 227, 239, 359, 463, 541, 691, 743, 761, 821, 823, 827, 887, 1021, 1117, 1289, 1427, 1489, 1637, 1723, 1933, 1999, 2081, 2287, 2309, 2719, 2791, 2833, 2843, 2953, 3329, 3541, 3803, 3823, 3929, 4003, 4007, 4079, 4139, 4297, 4451, 4561, 4597, 4691, 4703, 4817, 4931, 4943
Offset: 1

Views

Author

Keywords

Comments

The associated primes are: 11, 23, 41, 379, 3541, ...

Examples

			2 is in this sequence because 2 and prime(2) + 2*2^2 = 3 + 8 = 11 are both prime.
		

Crossrefs

Programs

  • Magma
    [n: n in {1..5000} | IsPrime(n) and IsPrime(s) where s is (2*n^2 + NthPrime(n))];
    
  • Mathematica
    Select[Prime[Range[700]],PrimeQ[Prime[#]+2#^2]&] (* Harvey P. Dale, Mar 19 2018 *)
  • PARI
    isok(p) = isprime(p) && isprime(prime(p) + 2*p^2); \\ Michel Marcus, Apr 13 2014