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.

Showing 1-6 of 6 results.

A216977 Primes of the form n^5+2.

Original entry on oeis.org

2, 3, 59051, 161053, 759377, 14348909, 90224201, 345025253, 601692059, 12762815627, 73439775751, 183765996901, 296709280759, 503756397101, 576650390627, 657748550153, 1572763671877, 1751989905403, 1880287678127, 2389769101501, 3101364196877, 3201078401359
Offset: 1

Views

Author

Michel Lagneau, Sep 21 2012

Keywords

Comments

Subsequence of A053788. [Bruno Berselli, Sep 21 2012]

Crossrefs

Programs

  • Magma
    [a: n in [0..400] | IsPrime(a) where a is n^5+2]; // Vincenzo Librandi, Mar 15 2013
  • Mathematica
    lst={}; Do[p=n^5+2; If[PrimeQ[p], AppendTo[lst, p]], {n, 6!}]; lst
    Select[Table[n^5 + 2, {n, 0, 400}], PrimeQ] (* Vincenzo Librandi, Mar 15 2013 *)
  • PARI
    v=select(n->isprime(n^5+2),vector(2000,n,n-1)); /* A216976 */
    vector(#v, n, v[n]^5+2)
    /* Joerg Arndt, Sep 21 2012 */
    

A216978 Numbers n such that n^6+2 is prime.

Original entry on oeis.org

0, 1, 39, 51, 81, 195, 213, 219, 231, 333, 351, 393, 417, 501, 531, 567, 657, 729, 747, 807, 945, 1005, 1059, 1161, 1173, 1185, 1191, 1203, 1281, 1335, 1371, 1467, 1479, 1563, 1587, 1647, 1653, 1749, 1761, 1821, 1845, 1875, 1929, 2373, 2379, 2421, 2529, 2595
Offset: 1

Views

Author

Michel Lagneau, Sep 21 2012

Keywords

Comments

Except for the first term, all terms must be odd numbers. - Harvey P. Dale, Sep 23 2012

Crossrefs

Programs

  • Mathematica
    lst={}; Do[If[PrimeQ[n^6+2], AppendTo[lst, n]], {n, 0, 3000}]; lst
    Join[{0},Select[Range[1,3001,2],PrimeQ[#^6+2]&]] (* Harvey P. Dale, Sep 23 2012 *)
  • PARI
    select(n->isprime(n^6+2),vector(2000,n,n-1)) /* Joerg Arndt, Sep 21 2012 */

A216980 Numbers n such that n^7+2 is prime.

Original entry on oeis.org

0, 1, 9, 21, 53, 63, 99, 123, 141, 155, 185, 213, 315, 363, 375, 449, 513, 521, 543, 555, 653, 669, 699, 731, 735, 759, 801, 843, 881, 975, 983, 995, 1031, 1095, 1115, 1131, 1149, 1161, 1221, 1253, 1395, 1413, 1451, 1473, 1491, 1571, 1599, 1625, 1659, 1733
Offset: 1

Views

Author

Michel Lagneau, Sep 21 2012

Keywords

Crossrefs

Programs

  • Mathematica
    lst={}; Do[If[PrimeQ[n^7+2], AppendTo[lst, n]], {n, 0, 10^3}]; lst
    Select[Range[0,2000],PrimeQ[#^7+2]&] (* Harvey P. Dale, Mar 29 2016 *)
  • PARI
    select(n->isprime(n^7+2),vector(2000,n,n-1)) /* Joerg Arndt, Sep 21 2012 */

A261536 Primes p such that p^5 + 2 is also prime.

Original entry on oeis.org

11, 149, 179, 197, 281, 317, 389, 401, 419, 491, 509, 587, 977, 1019, 1217, 1289, 1367, 1499, 1607, 1637, 2039, 2111, 2339, 2459, 2609, 2801, 2897, 3119, 3221, 3359, 3701, 3767, 3917, 4451, 4517, 4871, 5237, 5531, 5717, 5879, 5927, 6197, 6311, 6959, 7151
Offset: 1

Views

Author

Vincenzo Librandi, Aug 24 2015

Keywords

Comments

Subsequence of primes of A216976. - Michel Marcus, Aug 24 2015
All terms == 5 (mod 6). - Robert Israel, Sep 22 2019

Examples

			11^5 + 2 = 161053 is a prime.
		

Crossrefs

Cf. primes p such that p^k+2 is also prime: A001359 (k=1), A048637 (k=3), this sequence (k=5), A261537 (k=7), A261538 (k=9).
Cf. A000040.

Programs

  • Magma
    [p: p in PrimesUpTo(12000) | IsPrime(p^5+2)];
  • Maple
    filter:= proc(p) isprime(p) and isprime(p^5+2) end proc:
    select(filter, [seq(i,i=5..10000,6)]); # Robert Israel, Sep 22 2019
  • Mathematica
    Select[Prime[Range[1000]], PrimeQ[#^5 + 2] &]

A242326 Primes p for which p + 2, p^3 + 2 and p^5 + 2 are prime.

Original entry on oeis.org

419, 2339, 14081, 45821, 46349, 51419, 56039, 68489, 70379, 108191, 112601, 115319, 131891, 132749, 256391, 267611, 278879, 314159, 328511, 342449, 361001, 385139, 424841, 433259, 470651, 489689, 519371, 573761, 664691, 691181, 694271
Offset: 1

Views

Author

Abhiram R Devesh, May 10 2014

Keywords

Comments

Subsequence of A001359 and A048637.
All the terms in the sequence are congruent to 2 mod 3. This sequence is a subsequence of A240110.
Also, congruent to (11, 29) mod 30. - Zak Seidov, May 18 2014
Also, subsequence of A216976. - Michel Marcus, May 18 2014

Examples

			419 is in the sequence because
p = 419 (prime),
p + 2 = 421 (prime),
p^3 + 2 = 73560061 (prime), and
p^5 + 2 = 12914277518101 (prime).
		

Crossrefs

Programs

  • Magma
    [p: p in PrimesUpTo(10^6)| IsPrime(p+2) and IsPrime(p^3+2)and IsPrime(p^5+2)]; // Vincenzo Librandi, May 11 2014
  • Mathematica
    Select[Prime[Range[10^5]], PrimeQ[# + 2]&& PrimeQ[#^3 + 2]&& PrimeQ[#^5 + 2] &] (* Vincenzo Librandi, May 11 2014 *)

A216930 Numbers k such that k + 2, k^2 + 2, k^3 + 2, k^4 + 2 and k^5 + 2 are all prime.

Original entry on oeis.org

1, 909, 11925, 358875, 959595, 1047585, 3673089, 3925635, 3973971, 4995825, 5519241, 6516015, 6832245, 7217805, 7422381, 9145809, 10929765, 11038071, 11477235, 11721291, 12015555, 12262791, 12280935, 13454349, 13508475, 14625849, 15320829, 15321489, 15332745
Offset: 1

Views

Author

Michel Lagneau, Sep 20 2012

Keywords

Comments

k^6 + 2 is also prime for k = 4995825, 11038071, ...
a(2) = 909 = A245510(6); a(10) = 4996825, the first k such that k^6 + 2 is also prime, is A245510(7). - Jon E. Schoenfield, Dec 24 2022

Crossrefs

Cf. A245510.
Intersection of A040976, A067201, A067200, A216974, and A216976.

Programs

  • Mathematica
    Select[Range[16000000], And@@PrimeQ/@(Table[n^i+2, {i, 1, 5}]/.n->#)&]
    Select[Range[16*10^6], AllTrue[2 + #^Range[5], PrimeQ] &] (* The program uses the AllTrue function from Mathematica version 10 *) (* Harvey P. Dale, Jun 24 2015 *)
  • Python
    from sympy import isprime
    def ok(n): return all(isprime(n**i+2) for i in range(1, 6))
    print([k for k in range(1, 2*10**7, 2) if ok(k)]) # Michael S. Branicky, Dec 24 2022

Formula

a(n) == 3 (mod 6) for n>1. - Alexandru Petrescu, Dec 24 2022
Showing 1-6 of 6 results.