I'm working on a proof of the following fact:
"Let $x,y$ be real numbers such that $x^2+y^2=1$.
Show that there is exactly one real number $\theta \in (-\pi,\pi]$ such that $x=\sin\theta$ and $y=\cos\theta$."
Now, according to the book from which I've taken this problem a way to prove this statement would be to divide the proof into cases depending on whether $x,y$ are positive, negative, or zero.
My question is: Is there a way to prove this in a more straightforward way? I haven't seen another way yet, so I'd appreciate any hint.
Since $x^2+y^2=1$, $x\in[-1,1]$ and therefore, by the intermediate value theorem, there is a $\theta\in\left[0,\pi\right]$ such that $\cos\theta=x$. Since$$\sin^2\theta=1-\cos^2\theta=1-x^2=y^2,$$$\sin\theta=\pm y$. If $\sin\theta=y$, we're done. Otherwise, just replace $\theta$ by $-\theta$.