A289629
Smallest positive k such that (k+1)^n + (-k)^n is divisible by a square greater than 1.
Original entry on oeis.org
3, 7, 113, 14, 3, 23, 19, 7, 1, 2, 113, 75, 3, 7, 765, 36, 3, 2476, 87, 1, 3, 165, 19, 14, 2, 7, 28, 149, 1, 2972, 151, 2, 3, 14, 113, 977, 3, 5, 19, 34, 3, 135, 113, 7, 3, 136, 335, 23, 1, 7, 113, 11, 3, 2, 19, 2, 3
Offset: 2
a(2) = 3 because (1+1)^2 + (-1)^2 = 5 is squarefree, (2+1)^2 + (-2)^2 = 13 is squarefree, and (3+1)^2 + (-3)^2 = 25 is divisible by 5^2.
- Kevin P. Thompson, Table of n, a(n) for n = 2..150 with unconfirmed terms (term 31 confirmed by _Hugo Pfoertner_ and term 48 confirmed by _Jon E. Schoenfield_ and _Hugo Pfoertner_)
-
Table[k=1;While[SquareFreeQ[(k+1)^n+(-k)^n],k++];k,{n,2,15}] (* Giorgos Kalogeropoulos, Dec 03 2021 *)
-
a(n) = my(k=1); while (issquarefree((k+1)^n + (-k)^n), k++); k; \\ Michel Marcus, Dec 04 2021
Offset corrected; a(16), a(32), a(36), a(44), and a(48) corrected; and a(50)-a(58) added by
Kevin P. Thompson, Dec 05 2021.
A289985
Smallest positive k such that (n+1)^k + (-n)^k is divisible by a square greater than 1.
Original entry on oeis.org
10, 11, 2, 55, 21, 10, 3, 10, 33, 26, 10, 21, 10, 5, 21, 10, 55, 10, 8, 2, 2, 3, 7, 78, 55, 3, 34, 2, 21, 78, 10, 68, 10, 41, 57, 10, 55, 10, 55, 21, 10
Offset: 1
a(1) = 10 because (1+1)^10 + (-1)^10 = 1025 is divisible by 5^2.
-
A289985 := proc(n)
local k;
for k from 1 do
if not issqrfree((n+1)^k+(-n)^k) then
return k;
end if;
end do:
end proc:
for n from 1 do
printf("%d,\n",A289985(n)) ;
end do: # R. J. Mathar, Sep 04 2017
-
Table[SelectFirst[Range[10^2], ! SquareFreeQ[(n + 1)^# + (-n)^#] &], {n, 23}] (* Michael De Vlieger, Sep 03 2017 *)
A174269
Numbers k such that exactly one of 2^k - 1 and 2^k + 1 is a prime.
Original entry on oeis.org
0, 1, 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
Offset: 1
0 is in the sequence because 2^0 - 1 = 0 is nonprime and 2^0 + 1 = 2 is prime; 2 is not in the sequence because 2^2 - 1 = 3 and 2^2 + 1 = 5 are both prime.
-
Select[Range[0, 5000], Xor[PrimeQ[2^# - 1], PrimeQ[2^# + 1]] &] (* Michael De Vlieger, Jan 03 2016 *)
-
isok(k) = my(p = 2^k-1, q = p+2); bitxor(isprime(p), isprime(q)); \\ Michel Marcus, Jan 03 2016
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.
A286678
Smallest prime of the form (1 + k)^(2^n) + k.
Original entry on oeis.org
5, 17, 257, 65537, 795866110996400884391941, 3402823669209384634633746074317682114560000000000000000000000000000000000000000000000000000000000000039
Offset: 1
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-6 of 6 results.
Comments