A127727 Primes of the form p^e - p^(e-1) + p^(e-2) - ... + (-1)^e, where p is prime.
2, 3, 5, 7, 11, 43, 61, 157, 521, 547, 683, 2731, 4423, 6163, 13421, 19183, 22651, 26407, 37057, 43691, 113233, 121453, 143263, 174763, 208393, 292141, 375157, 398581, 412807, 527803, 590593, 843643, 981091, 1041421, 1193557, 1246573
Offset: 1
Examples
From _David A. Corneth_, Oct 28 2017: (Start) For (p, e) = (3, 1) we have the prime 3^1 - 3^0 = 2. For (p, e) = (2, 3) we have the prime 2^3 - 2^2 + 2^1 - 2^0 = 5. The examples above are the cases mentioned in the comments not of the form (1+p^q)/(1+p). A prime of that form is below; For (p, e) = (2, 4) we have the prime 2^4 - 2^3 + 2^2 - 2^1 + 2^0 = 11 = (1+p^(e+1)) / (1+p) = 33/3. (End)
Links
- David A. Corneth, Table of n, a(n) for n = 1..33914 (terms < 10^14) (the first 4799 terms < 10^12 from T. D. Noe)
- H. Dubner and T. Granlund, Primes of the Form (b^n+1)/(b+1), J. Integer Sequences, 3 (2000), Article 00.2.7.
- Douglas E. Iannucci, On a variation of perfect numbers, INTEGERS: Electronic Journal of Combinatorial Number Theory, 6 (2006), #A41.
Programs
-
PARI
upto(n) = {my(res = List([2,5])); forprime(p = 2, sqrtnint(n, 2), forprime(q = 3, logint(n * (1+p), p), r = (1+p^q)/(1+p); if(isprime(r), listput(res, r)))); listsort(res, 1); res} \\ David A. Corneth, Oct 28 2017
Comments