Solving $(\cos\alpha-\lambda)^2+\sin^2\alpha=0$ for $\lambda$. I am trying to solve $$(\cos\alpha-\lambda)^2+\sin^2\alpha=0$$ for $\lambda$.
Expanding and using the identity $\sin^2x+\cos^2x=1$ yields
$$\lambda^2-2\lambda\cos\alpha+1 = 0$$
and using the quadratic formula gives me
$$\lambda=\cos\alpha\pm\sqrt{\cos^2\alpha-1}.$$
The solution to this problem is $$\lambda = \cos\alpha\pm i\sin\alpha$$
but I don't see how to obtain that result.

Note that $\sqrt{\cos^2 \alpha - 1} = \sqrt{-(1-\cos^2 \alpha)} = \sqrt{- \sin^2\alpha} = i\sqrt{\sin^2\alpha}$...
So $$\lambda=\cos\alpha\pm\sqrt{\cos^2\alpha-1} = \cos \alpha \pm i\sin\alpha$$
