OFFSET
1,5
COMMENTS
Related to A327791, which concerns the number of ways, up to the order, of decomposing the multiplicative group of integers modulo n to the inner direct product of cyclic subgroups. See the formula for it there.
Note that the choice of (k_1, k_2, ..., k_r) does not affect the result. For example, (Z/35Z)* = C_2 X C_12 = C_4 X C_6 = C_2 X C_2 X C_12, and we have phi(2)*phi(12) = phi(4)*phi(6) = phi(2)*phi(2)*phi(12) = 4 = a(35).
LINKS
Jianing Song, Table of n, a(n) for n = 1..10000
Wikipedia, Multiplicative group of integers modulo n
EXAMPLE
Let (Z/nZ)* be the multiplicative group of integers modulo n.
(Z/63Z)* = C_6 X C_6, so a(63) = phi(6)*phi(6) = 4.
(Z/513Z)* = C_18 X C_18, so a(513) = phi(18)*phi(18) = 36.
(Z/840Z)* = C_2 X C_2 X C_2 X C_2 X C_12, so a(840) = phi(2)^4*phi(12) = 4.
PROG
(PARI) a(n) = prod(i=1, #znstar(n)[2], eulerphi(znstar(n)[2][i]))
CROSSREFS
KEYWORD
nonn
AUTHOR
Jianing Song, Sep 25 2019
STATUS
approved