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

A239416 Numbers n such that n^8-8 is prime.

Original entry on oeis.org

3, 7, 19, 39, 73, 75, 101, 107, 145, 147, 171, 213, 235, 247, 263, 285, 319, 353, 359, 369, 399, 443, 445, 521, 523, 557, 613, 675, 693, 707, 733, 781, 791, 805, 815, 829, 837, 879, 927, 943, 961, 999, 1033, 1097, 1103, 1109, 1129, 1137, 1141, 1155, 1157
Offset: 1

Views

Author

Derek Orr, Mar 17 2014

Keywords

Comments

Note that all the numbers in this sequence are odd.

Examples

			3^8-8 = 6553 is prime. Thus, 3 is a member of this sequence.
		

Crossrefs

Programs

  • Mathematica
    Select[Range[3,1200,2],PrimeQ[#^8-8]&] (* Harvey P. Dale, Jun 27 2014 *)
  • PARI
    is(n)=isprime(n^8-8) \\ Charles R Greathouse IV, Feb 20 2017
  • Python
    import sympy
    from sympy import isprime
    {print(n) for n in range(10**4) if isprime(n**8-8)}
    

A239503 Numbers n such that n^8+8 and n^8-8 are prime.

Original entry on oeis.org

3, 1515, 1689, 3327, 4461, 4641, 4965, 5043, 5583, 5709, 6183, 7089, 9291, 9369, 9699, 10125, 11109, 14175, 15081, 18393, 20295, 26955, 27009, 27219, 29067, 30513, 30807, 35355, 35889, 36003, 37935, 40107, 43461, 48045, 49005, 51783, 53289, 55527, 58833, 61203
Offset: 1

Views

Author

Derek Orr, Mar 20 2014

Keywords

Comments

All numbers are congruent to 3 mod 6.
Intersection of A239345 and A239416.

Examples

			3^8+8 = 6569 is prime and 3^8-8 = 6553 is prime. Thus, 3 is a member of this sequence.
		

Crossrefs

Programs

  • Mathematica
    Select[Range[3,62000,6],AllTrue[#^8+{8,-8},PrimeQ]&](* The program uses the AllTrue function from Mathematica version 10 *) (* Harvey P. Dale, Mar 07 2020 *)
  • Python
    import sympy
    from sympy import isprime
    def TwoBoth(x):
      for k in range(10**6):
        if isprime(k**x+x) and isprime(k**x-x):
          print(k)
    TwoBoth(8)
Showing 1-2 of 2 results.