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

A166241 Primes of the form a(n) = 3^n + 5^n + 7^n.

Original entry on oeis.org

3, 83, 292299923, 684331371443, 191640836307771341507, 9388970456309004899603, 30363584636685952989516426809065192841572196335875312999038527044324069339846978313376123672504677550327603
Offset: 1

Views

Author

Zak Seidov, Oct 09 2009

Keywords

Comments

The next term has 435 digits. - Harvey P. Dale, Apr 06 2015

Crossrefs

Cf. A160773 (corresponding values of n).

Programs

  • Magma
    [ a: n in [0..450]|IsPrime(a) where a is 3^n+5^n+7^n] // Vincenzo Librandi, Dec 08 2010
  • Mathematica
    Select[Table[3^n+5^n+7^n,{n,0,200}],PrimeQ] (* Harvey P. Dale, Apr 06 2015 *)

A176613 Smallest prime p of three consecutive primes such that the sum of their n-th powers is prime, or 0 if such a prime does not exist.

Original entry on oeis.org

2, 5, 3, 23, 0, 11, 0, 5, 0, 23, 3, 137, 0, 5, 3, 89, 0, 71, 0, 17, 0, 23, 0, 23, 3, 131, 3, 419, 0, 31, 0, 859, 0, 31, 0, 127, 0, 11, 0, 359, 0, 31, 0, 347, 0, 509, 0, 137, 0, 193, 0, 769, 0, 23, 0, 17
Offset: 0

Views

Author

Ulrich Krug (leuchtfeuer37(AT)gmx.de), Apr 21 2010

Keywords

Comments

Let p = prime(i), q = prime(i+1), r = prime(i+2).
(*) p^n + q^n + r^n has to be a prime.
When n is even and p > 3, then (*) is composite because primes greater than 3 are either of form 6k-1 or 6k+1 for some k. Hence, squares (or any even power) of such a prime has the form 6k+1. Adding three such even powers will produce a number of the form 6k+3, which is divisible by 3.
When n is even and p = 3, sequence A160773 gives the even n for which 3^n + 5^n + 7^n is prime.

Examples

			5 + 7 + 11 = 23 = prime(9); 3^2 + 5^2 + 7^2 = 83 = prime(23); 23^3 + 29^3 + 31^3 = 66347 = prime(6616).
		

Crossrefs

Programs

  • Maple
    f:= proc(n) local p,q,r;
      if n::even then
        if isprime(3^n+5^n+7^n) then return 3
        else return 0
        fi
      fi;
      p:= 2: q:= 3: r:= 5:
      while not isprime(p^n + q^n + r^n) do
        p:= q; q:= r; r:= nextprime(r)
      od;
      p
    end proc:
    f(0):= 2:
    map(f, [$0..100]);

Extensions

a(0) term added by T. D. Noe, Nov 23 2010

A352393 Numbers k such that 3^k + 5^k + 7^k + 11^k + 13^k is prime.

Original entry on oeis.org

0, 2, 4, 6, 12, 14, 28, 60, 68, 2070, 7910, 10740
Offset: 1

Views

Author

Hemjyoti Nath, Jun 07 2022

Keywords

Comments

Note that k must be even.
If it exists, a(13) > 31000. - Hugo Pfoertner, Jun 08 2022

Examples

			For k=2 we obtain f(2) = 3^2 + 5^2 + 7^2 + 11^2 + 13^2 = 373 which is a prime.
		

Crossrefs

Programs

  • Mathematica
    Select[Range[0, 1000], PrimeQ[3^# + 5^# + 7^# + 11^# +13^#] &]
  • Python
    from sympy import isprime
    from itertools import count, islice
    def agen(): yield from (k for k in count(0) if isprime(3**k + 5**k + 7**k + 11**k + 13**k))
    print(list(islice(agen(), 9))) # Michael S. Branicky, Jun 07 2022

Extensions

a(11)-a(12) from Hugo Pfoertner, Jun 07 2022
Showing 1-3 of 3 results.