Showing $f(z) = f(w)$ implies $z \sim w$ Let $Z=D^2=\{re^{i\theta} : r \leq 1\}$, $W=S^2$, $B=S=\{re^{i\theta} : r = 1\}$. Define the map $f$: $$f: Z \rightarrow W, f(re^{i\theta})= \big(\sin{(\pi r)} \cos{(\theta)}, \ \sin{(\pi r)} \sin{(\theta)}, \ \cos {(\pi r)}\big).$$
I want to prove that $f(z) = f(w)$ implies $z \thicksim w$, where $$z \thicksim w \iff z, w \in B \ \text{or} \ z=w$$
I have proceeded directly, letting $z = re^{i\theta}, w=se^{i\alpha}$ and setting $f(z) = f(w)$. But when I equate the coordinates and solve the resulting equations the most I get is $$ s \equiv r \ \pmod 2, \ \theta = \alpha + n\pi$$ $$\implies s=r, \ \theta = \alpha + n\pi, $$ for $n \in \mathbb Z$.
Obviously this isn't what I want as I would want $s=r=1$, so I'm wondering if I've went wrong somewhere or this is just not possible.
CONTEXT: I am trying to prove that $Z/B \cong W$, i.e. $D^2/S^1 \cong S^2$. I have proved that $f$ is a quotient map so it suffices to just prove this property.
 A: If I understand your setup, you want to define $z\sim w$ to be $z,w\in B$ or $z=w$ (so $\sim$ identifies all points in $B$ and is equality everywhere else).
Now, when doing your computations from the assumption $f(z)=f(w)$, you get $r=s$ by considering the third coordinate of $f$ (and since $0\leq r,s\leq 1$). If $r=1$ then $z,w\in B$ and $z\sim w$. On the other hand, if $0<r<1$ then $\sin(\pi r)\neq 0$ so you can divide in the first two coordinates to get $\sin(\theta)=\sin(\alpha)$ and $\cos(\theta)=\cos(\alpha)$. Since $0\leq \theta,\alpha<2\pi$, you get $\theta=\alpha$. So you get $z=w$ and $z\sim w$.
A: What you have to do first is to show that $f$ is well-defined, i.e. if $re^{i\theta} =  se^{i\phi}$, then $\big(\sin{(\pi r)} \cos{(\theta)}, \ \sin{(\pi r)} \sin{(\theta)}, \ \cos {(\pi r)}\big) = \big(\sin{(\pi s)} \cos{(\phi)}, \ \sin{(\pi s)} \sin{(\phi)}, \ \cos {(\pi s)}\big)$. If you have done this, you have to show that $f$ is continuous. What you do in your question is only the last step.
I suggest to do it as follows. Writing $D^2$ as you do shows that you identify $\mathbb R^2$ with $\mathbb C$. This also gives us $S^2 \subset \mathbb C \times \mathbb  R$. With this identification we have
$$f(re^{i\theta})  = \big(\sin{(\pi r)} \cos{(\theta)} + i \ \sin{(\pi r)} \sin{(\theta)}, \ \cos {(\pi r)}\big) = \big(\sin(\pi r)e^{i\theta}, \cos(\pi r)\big) $$
which is the same as
$$f(z) = \begin{cases} \big(\sin(\pi \lvert z \rvert)\frac{z}{\lvert z \rvert}, \cos(\pi \lvert z \rvert)\big) & z \ne 0 \\ \big(0,\cos(\pi \lvert z \rvert)\big) = (0,-1) & z = 0 \end{cases}$$
This shows that $f$ is well-defined and continuous ($z = 0$ is the only point where this not completely obvious, but note that $\big\lvert \sin(\pi \lvert z \rvert)\frac{z}{\lvert z \rvert} \big\rvert = \lvert \sin(\pi \lvert z \rvert) \rvert \to 0$ as $z \to 0$).
Since $\cos$ maps $[0,\pi]$ bijectively onto $[-1,1]$, we see $\lvert z \rvert \in [0,1]$ is uniquely determined by $\cos(\pi \lvert z \rvert)$, i.e. by $f(z)$.
Clearly, if $z \in B = S^1$, then $f(z) = (0,1)$, and if $z \ne S^1$, then $f(z) \ne (0,1)$.
Now consider $w, z \in D^2$ such that $f(w) = f(z) = p$. This implies $\lvert w \rvert =  \lvert z \rvert = r$. Moreover

*

*If $p = (0,1)$, then $w,z \in S^1$.


*If $p = (0,-1)$, then $w = z = 0$.


*If $p \ne (0,1), (0,-1)$, then $w, z \notin S^1$ and $w,z \ne 0$. We conclude $0 < r < 1$ and $\sin(\pi r)\frac{w}{r} = \sin(\pi r)\frac{z}{r}$. But $\sin(\pi r) \ne 0$, thus $w = z$.
