The following question is motivated by Thomas's answer here which can be used to prove that $\mathbf RP^n$ is same as the space obtained by identifying the antipodal points on the boundary circle of the closed $n$-disc.
Notation: Let $H^n_+$ denotes the open upper half-sphere of $S^n$, $\bar H^n_+$ denote the closed upper half-sphere, and $H^n_-$ denote the open lower half-sphere of $S^n$. The equator is the intersection of $S^n$ with the set $\mathbf R^{n-1}\times\{ 0\}$.
Let $\bar H^n_+/\sim$ be the space formed by identifying the antipodal points on the equator. Let $f:S^n\to \bar H^n_+/\sim$ be the map defined as $$ f(x)= \left\{ \begin{array}{ll} x & \text{if} \ x\in H^n_+\\ \{x, -x\} & \text{if } x \text{ is on the equator circle}\\ -x & \text{if }\ x\in H^n_- \end{array} \right. $$ Then $f$ is a continuous map.
I am having a hard time showing this.
I can see that if $U$ is open in $\bar H^n_+/\sim$, and $\pi:\bar H^n_+\to \bar H^n_+/\sim$ denotes the natural projection map, then $f^{-1}(U)$ is same as $\pi^{-1}(U)\cup a(\pi^{-1}(U))$, where $a:S^n\to S^n$ is the antipodal map.
Since $\pi$ is a quotient map, we have $\pi^{-1}(U)$ is open in $\bar H^n_+$. The antipodal map $a$ is a homemorphism. Thus $a(\pi^{-1}(U))$ is open in $\bar H^n_-$.
But it is not clear that $\pi^{-1}(U)\cup a(\pi^{-1}(U))$ is open in $S^n$.
I can see is pictorially in the case when $n=2$. But do not have a proper argument.
Is there a neat way to do this?