Let \(d=\gcd(n,k)\) and let \(k=dr\text{.}\) Since \(a^k = (\mathbf{a^d})^r\) we have by closure that \(\mathbf{\subgroup{a^k}}\subseteq \subgroup{ a^d}\text{.}\) By Bezout’s lemma, there are integers \(s\) and \(t\) such that \(d=ns+kt\text{.}\) So
\begin{equation*}
a^d= \mathbf{a^{ns+kt}} = \mathbf{a^{ns}a^{kt}} = e(a^k)^t = (a^k)^t \in \mathbf{\subgroup{a^d}}.
\end{equation*}
This proves \(\mathbf{\subgroup{a^d}\subseteq \subgroup{a^k}}\text{.}\) So we have verified that \(\subgroup{ a^k} =\subgroup{ a^{\gcd(n,k)}}\text{.}\)
To prove the second statement, we will show that \(|a^{d'}|=n/d'\) for any divisor \(d'\) of \(n\text{.}\) Certainly
\begin{equation*}
(a^{d'})^{\mathbf{n/d'}}=a^n=e\text{,}
\end{equation*}
so \(|a^{d'}|\leq \mathbf{n/d'}\text{.}\) On the other hand, if \(i\) is a positive integer with \(i\lt n/d'\) then \(\mathbf{a^i\neq e}\) because \(d'i\lt n\) and the definition of \(|a|\text{.}\) Therefore we have \(|a^{d'}| \geq \mathbf{n/d'}\) and thus \(\mathbf{|a^{d'}|=n/d'}\text{.}\)
We now apply this fact with \(d'=\mathbf{\gcd(n,k)}\) to obtain
\begin{equation*}
|a^k|=|\subgroup{ a^k}|=|\subgroup{ a^{\mathbf{\gcd(n,k)}}}|=|a^{\mathbf{\gcd(n,k)}}|=\mathbf{n/\gcd(n,k)}\text{.}
\end{equation*}