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-9 of 9 results.

A154833 Numbers n such that n^5-2 is prime.

Original entry on oeis.org

3, 13, 31, 63, 93, 139, 181, 211, 229, 265, 271, 303, 325, 339, 343, 345, 411, 441, 519, 523, 531, 549, 555, 573, 619, 663, 675, 681, 693, 741, 751, 805, 819, 835, 853, 861, 945, 951, 969, 975, 993, 1063, 1071, 1095, 1119, 1143, 1275, 1281, 1305, 1329
Offset: 1

Views

Author

Keywords

Comments

3^5-2=241 prime, 13^5-2=371291 prime,...

Crossrefs

Programs

  • Magma
    [n: n in [1..500] | IsPrime(n^5-2)]; // Vincenzo Librandi, Nov 26 2010
    
  • Mathematica
    lst={};Do[p=n^5-2;If[PrimeQ[p],AppendTo[lst,n]],{n,0,7!}];lst
    Select[Range[2 10^3], PrimeQ[#^5 - 2] &] (* Vincenzo Librandi, Mar 20 2014 *)
  • PARI
    is(n)=isprime(n^5-2) \\ Charles R Greathouse IV, Feb 17 2017

A154834 Primes p such that p^5 - 2 is also prime.

Original entry on oeis.org

3, 13, 31, 139, 181, 211, 229, 271, 523, 619, 751, 853, 1063, 1483, 1699, 2791, 3361, 3463, 3541, 3769, 4051, 4201, 4801, 4861, 4903, 5521, 5689, 5701, 6163, 6211, 6763, 6823, 6949, 7621, 8059, 8269, 8389, 8419, 8563, 8689, 8713, 9001, 9103, 9319, 10303
Offset: 1

Views

Author

Keywords

Comments

Primes in A154833.

Examples

			3^5 - 2 = 241 is prime,
13^5 - 2 = 371291 is prime, ...
		

Crossrefs

Programs

  • Mathematica
    lst={};Do[p=n^5-2;If[PrimeQ[p],If[PrimeQ[n],AppendTo[lst,n]]],{n,0,7!}];lst
    Select[Prime[Range[1300]],PrimeQ[#^5-2]&] (* Harvey P. Dale, Feb 09 2019 *)

A154933 Numbers k such that k^6 - 2 is prime.

Original entry on oeis.org

3, 11, 17, 35, 37, 47, 49, 59, 67, 77, 99, 123, 127, 133, 139, 155, 161, 169, 173, 187, 195, 213, 225, 231, 237, 241, 245, 247, 253, 275, 279, 297, 319, 325, 367, 373, 381, 383, 385, 399, 411, 425, 431, 469, 507, 511, 523, 541, 545, 553, 569, 585, 589, 609
Offset: 1

Views

Author

Keywords

Crossrefs

Programs

  • Mathematica
    lst={};Do[p=n^6-2;If[PrimeQ[p],AppendTo[lst,n]],{n,1,7!}];lst
  • PARI
    isA154933(n) = isprime(n^6-2) \\ Michael B. Porter, Oct 06 2009

Extensions

a(1) = 0 removed by Amiram Eldar, Apr 04 2020

A154935 Numbers n such that n^7-2 is prime.

Original entry on oeis.org

7, 15, 25, 87, 91, 99, 199, 211, 265, 337, 357, 361, 367, 405, 501, 511, 537, 595, 627, 685, 697, 771, 805, 841, 847, 861, 889, 931, 939, 979, 1035, 1047, 1081, 1125, 1135, 1177, 1225, 1231, 1287, 1315, 1321, 1387, 1425, 1497, 1501, 1627, 1741, 1795, 1807
Offset: 1

Views

Author

Keywords

Crossrefs

Programs

  • Magma
    [n: n in [1..500]|IsPrime(n^7-2)]; // Vincenzo Librandi, Nov 26 2010
    
  • Mathematica
    lst={};Do[p=n^7-2;If[PrimeQ[p],AppendTo[lst,n]],{n,0,7!}];lst
    Select[Range[2*10^3], PrimeQ[#^7 - 2] &] (* Vincenzo Librandi, Mar 20 2014 *)
  • PARI
    is(n)=isprime(n^7-2) \\ Charles R Greathouse IV, Feb 17 2017

A154934 Primes in A154933.

Original entry on oeis.org

3, 11, 17, 37, 47, 59, 67, 127, 139, 173, 241, 367, 373, 383, 431, 523, 541, 569, 613, 631, 673, 683, 691, 829, 967, 977, 1019, 1063, 1163, 1213, 1249, 1291, 1301, 1303, 1327, 1367, 1439, 1483, 1487, 1601, 1607, 1609, 1733, 1747, 1789, 1801, 1823, 1907
Offset: 1

Views

Author

Keywords

Crossrefs

Programs

  • Mathematica
    lst={}; Do[p=n^6-2; If[PrimeQ[p], If[PrimeQ[n], AppendTo[lst,n]]], {n,0,3*7!}]; lst

A154936 Primes in A154935.

Original entry on oeis.org

7, 199, 211, 337, 367, 1231, 1321, 1627, 1741, 2161, 2251, 2551, 3259, 3769, 3877, 3931, 4099, 4591, 4759, 4789, 6829, 7297, 7867, 8221, 8887, 9049, 9181, 9337, 9349, 11959, 12697, 12919, 13411, 13591, 14827, 15187, 15217, 15817, 15877, 15889
Offset: 1

Views

Author

Keywords

Crossrefs

Programs

  • Mathematica
    lst={}; Do[p=n^7-2; If[PrimeQ[p], If[PrimeQ[n], AppendTo[lst,n]]], {n,0,8!}]; lst

A071351 Numbers n such that both n^4 + 2 and n^4 - 2 are prime.

Original entry on oeis.org

3, 21, 87, 99, 129, 141, 279, 627, 657, 777, 783, 795, 1653, 1725, 1833, 1959, 2001, 2043, 3039, 3399, 3609, 3861, 3975, 4257, 4371, 4491, 5403, 5541, 5709, 5985, 7371, 7539, 7869, 7917, 8397, 8445, 8547, 8793, 9051, 9057, 9915, 9933, 11067, 12153
Offset: 1

Views

Author

Labos Elemer, May 21 2002

Keywords

Examples

			n=3: n^4 = 81; {79,83} are primes.
		

Crossrefs

Programs

  • Mathematica
    lst={}; Do[p1=n^4-2; p2=n^4+2; If[PrimeQ[p1]&&PrimeQ[p2],AppendTo[lst,n]],{n,0,8!}]; lst (* Vladimir Joseph Stephan Orlovsky, Jan 17 2009 *)
    Select[Range[730000], AllTrue[#^4 + {2, -2}, PrimeQ] &] (* The program uses the AllTrue function from Mathematica version 10 *) (* Harvey P. Dale, Jan 02 2018 *)

A154938 Numbers k such that k^6 - 2 and k^6 + 2 are both primes.

Original entry on oeis.org

195, 213, 231, 657, 1563, 1749, 2967, 3597, 3627, 4263, 4887, 6867, 6993, 7257, 7725, 9045, 9201, 9717, 11595, 12579, 13029, 14145, 14259, 14367, 15837, 16131, 16581, 17259, 19905, 19917, 21081, 21711, 23127, 24435, 24921, 28299, 28707
Offset: 1

Views

Author

Keywords

Crossrefs

Programs

  • Magma
    [n: n in [1..500] | IsPrime(n^6-2) and IsPrime(n^6+2)]; // Vincenzo Librandi, Nov 26 2010
  • Mathematica
    lst={};Do[p1=n^6-2;p2=n^6+2;If[PrimeQ[p1]&&PrimeQ[p2],AppendTo[lst,n]],{n,0,9!}];lst
    Select[Range[30000],AllTrue[#^6+{2,-2},PrimeQ]&] (* Harvey P. Dale, Jun 21 2025 *)

A258572 Primes p such that p - 2, p^2 - 2, p^3 - 2, p^4 - 2 and p^5 - 2 are all prime.

Original entry on oeis.org

15331, 3049201, 9260131, 10239529, 10955449, 24303469, 33491569, 42699721, 56341711, 66241561, 87068479, 114254629, 129783571, 143927419, 152065549, 221977909, 235529419, 252769399, 280028449, 284535481, 299116021, 312896359, 349665889, 361039519, 407462929
Offset: 1

Views

Author

Juri-Stepan Gerasimov, Jun 03 2015

Keywords

Comments

Intersection of A006512, A062326, A178251, A154832 and A154834.
Subsequence of primes of A216945. - Michel Marcus, Jul 07 2015

Crossrefs

Programs

  • Magma
    [p: p in PrimesUpTo(40000000) | IsPrime(p^1-2) and IsPrime(p^2-2) and IsPrime(p^3-2) and IsPrime(p^4-2) and IsPrime(p^5-2)];
    
  • Mathematica
    Select[Prime[Range[10^8]], And@@PrimeQ[{#, # - 2, #^2 - 2, #^3 - 2, #^4 - 2, #^5 - 2}] &] (* Vincenzo Librandi, Jul 06 2015 *)
    Select[Prime[Range[2172*10^4]],AllTrue[#^Range[5]-2,PrimeQ]&] (* The program uses the AllTrue function from Mathematica version 10 *) (* Harvey P. Dale, Dec 02 2018 *)
  • PARI
    first(m)=my(v=vector(m),i,p,t=1);for(i=1,m,while(1,p=prime(t);if(isprime(p-2)&&isprime(p^2 - 2)&&isprime(p^3 - 2)&&isprime(p^4 - 2)&&isprime(p^5 - 2),v[i]=p;break,t++));t++);v; /* Anders Hellström, Jul 17 2015 */

Extensions

a(10) corrected and a(14)-a(25) added by Giovanni Resta, Jun 05 2015
Showing 1-9 of 9 results.