A285929
Numbers m such that 2^m + (-1)^m is prime.
Original entry on oeis.org
0, 2, 3, 4, 5, 7, 8, 13, 16, 17, 19, 31, 61, 89, 107, 127, 521, 607, 1279, 2203, 2281, 3217, 4253, 4423, 9689, 9941, 11213, 19937, 21701, 23209, 44497, 86243, 110503, 132049, 216091, 756839, 859433, 1257787, 1398269, 2976221, 3021377, 6972593, 13466917, 20996011, 24036583, 25964951, 30402457, 32582657, 37156667
Offset: 1
4 is in this sequence because 2^4 + (-1)^4 = 17 is prime.
5 is in this sequence because 2^5 + (-1)^5 = 31 is prime.
A174326
Exactly one of 3^n +- 2^n is prime.
Original entry on oeis.org
0, 1, 3, 4, 5, 17, 29, 31, 53, 59, 101, 277, 647, 1061, 2381, 2833, 3613, 3853, 3929, 5297, 7417, 90217, 122219, 173191, 256199, 336353, 485977, 591827, 1059503
Offset: 1
a(1)=0 because 3^0 - 2^0 = 0 = nonprime and 3^0 + 2^0 = 2 = prime;
a(2)=1 because 3^1 - 2^1 = 1 = nonprime and 3^1 + 2^1 = 5 = prime;
a(3)=3 because 3^3 - 2^3 = 19 = prime and 3^3 + 2^3 = 35 = nonprime.
-
epQ[n_]:=Module[{a=3^n,b=2^n},Sort[PrimeQ[{a+b,a-b}]]=={False,True}]; Select[Range[0,4000],epQ] (* Harvey P. Dale, Sep 16 2016 *)
-
is(n)=isprime(3^n+2^n)+isprime(3^n-2^n)==1 \\ Charles R Greathouse IV, Mar 19 2017
A286348
Numbers n such that 4^n + (-3)^n is prime.
Original entry on oeis.org
0, 3, 4, 7, 16, 17, 59, 283, 311, 383, 499, 521, 541, 599, 1193, 1993, 2671, 7547, 24019, 46301, 48121, 68597, 91283, 131497, 148663, 184463, 341233
Offset: 1
3 is in this sequence because 4^3 + (-3)^3 = 37 is prime.
4 is in this sequence because 4^4 + (-3)^4 = 337 is prime.
A287614
Primes of the form (1 + x)^y + (-x)^y for some positive x, y.
Original entry on oeis.org
5, 7, 13, 17, 19, 31, 37, 41, 61, 97, 113, 127, 181, 211, 257, 271, 313, 331, 337, 397, 421, 547, 613, 631, 761, 881, 919, 1013, 1201, 1301, 1657, 1741, 1801, 1861, 1951, 2113, 2269, 2381, 2437, 2521, 2791, 3121, 3169, 3571, 3613, 3697, 4219, 4447, 4513, 4651, 5101, 5167, 5419, 6211
Offset: 1
5 (x = 1, y = 2), 7 (1, 3), 13 (2, 2), 17 (1, 4), 19 (2, 3), 31 (1, 5), 37 (3, 3), 41 (4, 2), 61 (3, 4 or 2, 5), 97 (2, 4), 113 (7, 2), 127 (1, 7 or 3, 6), 181 (9, 2), 211 (2, 5), 257 (1, 8), 271 (9, 3).
-
mx = 10^4; f[x_, y_] := (1+x)^y + (-x)^y; x=0; Union@ Reap[ While[ f[++x, 2] < mx, y=1; While[(v = f[x, ++y]) < mx, If[PrimeQ@ v, Sow@v]]]][[2, 1]] (* Giovanni Resta, May 31 2017 *)
Showing 1-4 of 4 results.
Comments