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.

A181628 Numbers k such that (2^k + 3^k)/13 is prime.

This page as a plain text file.
%I A181628 #29 Aug 17 2024 23:01:54
%S A181628 6,10,14,22,34,38,82,106,218,334,4414,7246,10118,10942,15898,42422,
%T A181628 65986
%N A181628 Numbers k such that (2^k + 3^k)/13 is prime.
%C A181628 All terms are of the form 2p, p prime.
%C A181628 The prime (2^4414 + 3^4414)/13 = 79300327387 ...611266 985181 has 2105 decimal digits.
%C A181628 a(18) > 10^5. - _Michael S. Branicky_, Aug 17 2024
%e A181628 10 is in the sequence because (2^10+ 3^10)/13 = 60073/13 = 4621 is prime.
%p A181628 with(numtheory):for n from 1 to 4500 do: x:= (2^n + 3^n)/13:if floor(x)=x and
%p A181628   type(x,prime)=true then printf(`%d, `, n):else fi:od:
%p A181628 # alternative
%p A181628 Res:= NULL:
%p A181628 p:= 2:
%p A181628 while p < 6000 do
%p A181628 p:= nextprime(p);
%p A181628 if isprime((2^(2*p)+3^(2*p))/13) then Res:= Res, 2*p fi;
%p A181628 od:
%p A181628 Res; # _Robert Israel_, Apr 26 2017
%o A181628 (PARI) is(n)=n%2==0 && isprime(n/2) && ispseudoprime((2^n+3^n)/13) \\ _Charles R Greathouse IV_, Jun 06 2017
%o A181628 (Python)
%o A181628 from sympy import isprime
%o A181628 def afind(limit, startk=1):
%o A181628     k = startk
%o A181628     pow2 = 2**k
%o A181628     pow3 = 3**k
%o A181628     for k in range(startk, limit+1):
%o A181628         q, r = divmod(pow2+pow3, 13)
%o A181628         if r == 0 and isprime(q):
%o A181628             print(k, end=", ")
%o A181628         pow2 *= 2
%o A181628         pow3 *= 3
%o A181628 afind(1000) # _Michael S. Branicky_, Dec 28 2021
%Y A181628 Cf. A057469.
%K A181628 nonn,more
%O A181628 1,1
%A A181628 _Michel Lagneau_, Nov 18 2010
%E A181628 a(12) from _D. S. McNeil_, Nov 18 2010
%E A181628 a(13) and a(14) from _Robert Israel_, Apr 26 2017
%E A181628 a(15) from _Michael S. Branicky_, Dec 28 2021
%E A181628 a(16) from _Michael S. Branicky_, Apr 26 2023
%E A181628 a(17) from _Michael S. Branicky_, Aug 17 2024