Let $k$, $m$ be natural numbers, and $C_m:=\mathbb{Z}/ m \mathbb{Z}$ be the cyclic group of order $m$.
Let $N_{k, \, m}$ be the cardinality of the following set: $$\{(a_1, \ldots, a_k) \in (C_m)^k \; | \; \text{the subset } \{a_1, \ldots, a_k\} \text{ generates } C_m \}.$$
Question. Is a closed formula for $N_{k,\, m}$ known? If so, what is a reference?
Clearly $$N_{k, \, m} \geq m^k - (m- \phi(m))^k,$$ with equality when $m=p$ is a prime number, in which case $$N_{k, \, p} = p^k -1.$$ But what about the general situation? This looks to me as a natural problem, so I suspect that the answer is well-known to the people working in the field. However, I am not an expert in Combinatorics, so I may be missing some elementary solution.
Any answer and/or reference to the relevant literature will be appreciated.
\operatorname
is really only meant for operators, and the spacing is unlikely to align well with normal inter-word spacing. Instead of\operatorname{the subset} \; \{a_1, \ldots, a_k\} \, \operatorname{generate} \, C_m
it is probably better to use\text{the subset } \{a_1, \ldots, a_k\} \text{ generates } C_m
. I edited accordingly. (Actually you can use math mode in text in math mode:\text{the subset $\{a_1, \dotsc, a_k\}$ generates $C_m$}
. But this seems to be uncommon.) $\endgroup$