Prove that $Y$ is Hausdorff iff $X$ is Hausdorff and $A$ is a closed subset of $X$ Let $X$ be a topological space and $A$ a subset of $X$. On $X\times\{0,1\}$ define the partition composed of the pairs $\{(a,0),(a,1)\}$ for $a\in A$, and of the singletons $\{(x,i)\}$ if $x\in X\setminus A$ and $i \in \{0,1\}$.
Let $R$ be the equivalence relation defined by this partition, let $Y$ be the quotient space $[X \times \{0,1\}]/R$ and let $p:X \times \{0,1\} \to Y$ be the quotient map. 
(a) Prove that there exists a continuous map $f:Y \to X$ such that $f \circ p(x,i)=x$ for every $x\in X$ and $i \in \{0,1\}$.
(b) Prove that Y is Hausdorff if and only if X is Hausdorff and A a closed subset of X. 
So far I have done part (a), but am struggling with part (b). I am thinking I will have to use the fact that if a quotient space $Z/R$ is Hausdorff then the graph of the equivalence relation in $Z \times Z$ is closed. However, I am not positive. If anyone could even just help me get started somewhere on this question I would be grateful, thank you.
 A: Hints: It actually shouldn't be too difficult to just go through the proof by hand without relying on other theorems.


*

*($\Rightarrow$)  If $X$ is not Hausdorff, then there are distinct points $x , y \in X$ which cannot be separated.  Show that $p ( x , 0 ) , p ( y , 0 )$ cannot be separated in $Y$.  If $A \subseteq X$ is not closed, let $x \in \overline{A} \setminus A$.  Show that the points $p ( x , 0 ) , p ( x , 1 )$ (which are distinct) cannot be separated in $Y$.

*($\Leftarrow$) This should just be working through the cases.  First note that if $x , y \in X$ are distinct, then they can be separated by open sets in $X$, and it is not too hard to separate $p ( x , i ) , p ( y , j )$ for any $i,j \in \{ 0 , 1 \}$.  So the real difficulty will be in separating $p ( x , 0 ) , p ( x , 1 )$ for $x \in X$.  But note that we only have to worry about this when $p ( x , 0 ) \neq p ( x , 1 )$.  When does this happen?  (Obvious choices for open sets should jump out at you.)

A: The approach that you suggest is indeed reasonable. Let $Z=X\times\{0,1\}$, where $\{0,1\}$ has the discrete topology. Let $E$ be the equivalence relation, considered as a subset of $Z\times Z$. Now consider a point $p=\big\langle\langle x,i\rangle,\langle y,j\rangle\big\rangle\in E$; what does $p$ actually look like? Clearly we must have $x=y$. If $x=y\in A$, $i$ and $j$ can both be either $0$ or $1$, but if $x=y\in X\setminus A$, then we must have $i=j$. Thus, 
$$p\in E\quad\text{ iff }\quad x=y\,\text{ and }\,(x\in A\text{ or }i=j)\;.$$
More usefully, 
$$p\in(Z\times Z)\setminus E\quad\text{ iff }\quad x\ne y\,\text{ or }\,(x\in X\setminus A\text{ and }i\ne j)\;:$$
you can use this and the definition of the product topology on $Z\times Z$ to show that $(Z\times Z)\setminus E$ is open (and hence $E$ is closed) iff $X$ is Hausdorff and $A$ is closed.
A: Hint: Show that $p$ is a perfect map, that is a closed continuous surjection such that $p^{-1}(y)$ is compact for each $y\in Y$. These maps preserve many properties of $X$ among which is also Hausdorff'ness.
Here is a proof that perfect maps preserve $T_2$: If $y$ and $z$ are distinct points in $Y$, then $f^{-1}(y)$ and $f^{-1}(z)$ are disjoint compact sets which by $T_2$ can be seperated by disjoint open neighborhoods. $U,V$. The disjoint open neighborhoods around $y$ and $z$ can be obtained by taking the complements of $p(X\backslash U)$ and $p(X\backslash V)$ in $Y$.
I'll leave it to you to show that $p$ is perfect, which should be very easy.
Edit: The closedness of the graph $R$ is not sufficient, it is only necessary condition for $Y$ to be Hausdorff. If the quotient map $p$ is open, then closedness $R$ is enough. Another approach would be to show the compactness of $R$, because this makes $p$ a perfect map, see also Product of quotient map a quotient map when domain is compact Hausdorff?
