Calculating Galois group of $\mathbb Q(\cos \frac \pi 8)/\mathbb{Q}$ What's a quick elegant way to compute the galois group of $\mathbb Q(\cos \frac \pi 8)/\mathbb Q$? I found the minimal polynomial to be $x^4-x^2-\frac 18$ but computing things directly is just horrible. I ended up getting $D_4$ and I'm not even sure it's correct...
Help!
 A: Here is an answer that uses no tinkering: we have that $ \textrm{Gal}(\mathbf Q(\zeta_{16})/\mathbf Q) \cong (\mathbf Z / 16\mathbf Z)^{\times} \cong C_4 \times C_2 $, and we note that any element of the Galois group can be written as $ \sigma^i \tau^j $, where $ \sigma : \zeta_{16} \to \zeta_{16}^3 $ and $ \tau : \zeta_{16} \to \zeta_{16}^{-1} $. We observe that the subfield $ \mathbf Q(\cos(\pi/8)) = \mathbf Q(\zeta_{16} + \zeta_{16}^{-1}) $ is stabilized by $ \{ 1, \tau \} $, therefore its Galois group over $ \mathbf Q $ is given by $ \langle \sigma \rangle $, which is cyclic of order 4.
Note that if $ L/K $ is a Galois extension of fields with Galois group $ G $ and a normal subgroup $ H $ has fixed field $ F $, then $ \textrm{Gal}(F/K) \cong G/H $. This follows directly from the isomorphism extension theorem. Therefore, the above Galois group is just $ \langle \sigma, \tau \rangle / \langle \tau \rangle \cong \langle \sigma \rangle $. (It is important for this conclusion that $ \sigma $ and $ \tau $ commute.)
A: It does seem that computing the Galois group of this extension is pretty terrible. However, $\cos(\pi/8) = \sqrt{2+\sqrt{2}}/2$, so $\mathbb{Q}(\cos(\pi/8)) = \mathbb{Q}(\sqrt{2+\sqrt{2}})$, which is a much nicer extension (note that $\sqrt{2+\sqrt{2}}$ has minimal polynomial $x^{4}-4x^{2}+2$, which is irreducible by Eisenstein at $2$). As outlined in the comments, one can show that this extension is cyclic with Galois group $\mathbb{Z}/4\mathbb{Z}$. More details can be found here as well.
