OFFSET
1,3
LINKS
Amiram Eldar, Table of n, a(n) for n = 1..10000
FORMULA
a(p^n) = Product_{k=1..n} (p^k - 1), where p is prime, and n an integer.
a(2^n) = A005329(n).
a(3^n) = A027871(n).
a(5^n) = A027872(n).
a(7^n) = A027875(n).
a(11^n) = A027879(n).
From Amiram Eldar, Nov 02 2024: (Start)
a(n) = n-1 if and only if n is in A175787 (i.e., n = 4 or n is prime).
a(n) == 1 (mod 2) if and only if n is a power of 2 (A000079). (End)
EXAMPLE
a(12) = (2-1)*(3-1)*(4-1)*(6-1)*(12-1) = 1*2*3*5*11 = 330.
MAPLE
with(numtheory): seq(mul(d-1, d in divisors(n) minus {1}), n=1..80);
MATHEMATICA
a[n_] := Times @@ (Rest@ Divisors[n] - 1); Array[a, 60] (* Amiram Eldar, Nov 01 2024 *)
PROG
(PARI) a(n) = my(d=divisors(n)); prod(k=2, #d, d[k]-1); \\ Michel Marcus, Oct 30 2024
CROSSREFS
KEYWORD
nonn,easy
AUTHOR
Ridouane Oudra, Oct 29 2024
STATUS
approved