Automorphisms of finite groups $Z_n $ , $D_n $ and $S_n $. Is there any method to compute all the automorphisms of a finite group say $Z_6$, $D_8$ or $S_3$ ?
 A: An automorphism of $\mathbf Z/n\mathbf Z$ must map a generator, say $\bar 1$ to another generator of  $\mathbf Z/n\mathbf Z$. As these are the classes of the numbers in $\;\{1,\dots,n-1\}$ which are coprime to $n$ (i.e. the units in the ring  $\mathbf Z/n\mathbf Z$), we have that
$$\operatorname{Aut}(\mathbf Z/n\mathbf Z)\simeq(\mathbf Z/n\mathbf Z)^\times.$$
 In the precise case of $\mathbf Z/6\mathbf Z$, this means $\operatorname{Aut}(\mathbf Z/6\mathbf Z)$ is the cyclic group of order $2$.
As to $D_8$, it can be shown that the automorphism group of $D_{2n}$ is isomorphic to a semi-direct product 
$$\mathbf Z/n\mathbf Z\rtimes\operatorname{Aut}(\mathbf Z/n\mathbf Z)\simeq \mathbf Z/n\mathbf Z\rtimes(\mathbf Z/n\mathbf Z)^\times$$
(see Wikipedia: Dihedral Groups)
For the automorphisms of $S_n3$, the situation is more complex, see the dedicated page of Wikipedia.  The case of $S_3$ is this:
$$S_3\simeq\operatorname{Aut}(S_3).$$
Indeed an automorphism of $S_n$ is defined by the images of a set of generators of $S_n$. $S_3$ is is generated by a transposition $\tau$ and a $3$-cycle.  The transposition has  for image a transposition, which makes three choices, and the $3$-cycle has for image itself of the other  $3$-cycle (its inverse). In all, this makes three possibilities, so $\bigl|\operatorname{Aut}(S_3)\bigr|=6$.
Now the inner automorphisms are also six in number since they're isomorphic to $S_3$. So the automorphisms of $S_3$ are simply their inner automorphisms, whence  the isomorphism.
