If $\displaystyle cos^2x=\frac{1}{2}$ What is the General solutions for it?
$\displaystyle \displaystyle \begin{align*} \cos^2{x} &= \frac{1}{2} \\ \cos{x} &= \pm \frac{1}{\sqrt{2}} \\ x &= \left\{ \frac{\pi}{4}, \pi - \frac{\pi}{4}, \pi + \frac{\pi}{4}, 2\pi - \frac{\pi}{4} \right\} + 2\pi n \textrm{ where } n \in \mathbf{Z} \\ x &= \left\{ \frac{\pi}{4}, \frac{3\pi}{4}, \frac{5\pi}{4}, \frac{7\pi}{4} \right\} + 2\pi n \\ x &= \frac{\pi}{4} + \frac{\pi}{2} m \textrm{ where } m \in \mathbf{Z} \\ x &= \frac{\pi + 2\pi m}{4} \\ x &= \frac{( 1 + 2m )\pi}{ 4 } \end{align*}$