A114871 Numbers of the form (p-1)p^k (where p is a prime and k>=0) in ascending order.
1, 2, 4, 6, 8, 10, 12, 16, 18, 20, 22, 28, 30, 32, 36, 40, 42, 46, 52, 54, 58, 60, 64, 66, 70, 72, 78, 82, 88, 96, 100, 102, 106, 108, 110, 112, 126, 128, 130, 136, 138, 148, 150, 156, 162, 166, 172, 178, 180, 190, 192, 196, 198, 210, 222, 226, 228, 232, 238, 240, 250
Offset: 1
Keywords
Examples
18 is an element of the sequence because 18=(3-1)3^2 and 3 is a prime.
Links
- Robert Israel, Table of n, a(n) for n = 1..10000
- S. Contini, E. Croot, I. E. Shparlinski, Complexity of Inverting the Euler Function, arXiv:math/0404116 [math.NT], 2004.
Programs
-
Maple
N:= 1000: # for terms <= N S:= {}: R:= NULL: p:= 1: while p <= N do p:= nextprime(p); S:= S union {seq((p-1)*p^k, k = 0..ilog[p](N/(p-1)))}; R:= R, seq((p-1)*p^k, k = 0..ilog[p](N/(p-1))) od: sort(convert(S,list)); # Robert Israel, Feb 10 2021
-
Mathematica
Take[Union@ Flatten@ Table[(Prime[n] - 1)Prime[n]^k, {n, 60}, {k, 0, 7}], 61] (* Robert G. Wilson v, Jan 05 2006 *)
Extensions
More terms from Robert G. Wilson v, Jan 05 2006
Comments