# Criteria for Hausdorff

Let $$f:X\to Y$$, $$Y$$ is Hausdorff, and $$f$$ is continuous. How to prove that $$f$$ is injective if $$X$$ is Hausdorff?

It is easy enough to show that $$f$$ injective implies $$X$$ Hausdorff, and I have been able to find examples where, if $$f$$ is not injective, $$X$$ is not Hausdorff. However, is it possible to prove the above statement in general? I cannot seem to work it out from the definitions.

• You have substantially changed the question with your edits. In the original version you had the condition that $X$ has the initial topology. Was it only by mistake that you have omitted this condition? May 14, 2022 at 16:45
• hi rolodex. to add to @MartinSleziak's comment, the statement as you currently have it is false. for any topological spaces $X$ and $Y$, and any point $y\in Y$, the constant map $X\to Y$ given by $x\mapsto y$ for all $x\in X$ is always continuous. on the other hand if $X$ has at least two elements this map is not injective May 14, 2022 at 21:38

Since the question was changed, but I answered before and also with directions swapped: The original question was, if $$Y$$ had the induced topology, then $$f$$ is injective iff $$X$$ is Hausdorff. The backward direction does not use the induced topology on $$Y$$, which is already mentioned in the question.

$$\Leftarrow$$: Assume $$X$$ is a Hausdorff space. If $$x,x'\in X$$ with $$x\neq x'$$, then there are open subsets $$U,U'\subseteq X$$ with $$x\in U$$, $$x'\in U'$$ and $$U\cap U'=\emptyset$$. Because of the definition of the induced topology, there are open subsets $$V,V'\subseteq Y$$ with $$U=f^{-1}(V)$$ and $$U'=f^{-1}(V')$$. We have $$f(x)\in f(U)=V$$, $$f(x')\in f(U')=V'$$ and $$f^{-1}(V\cap V')=f^{-1}(V)\cap f^{-1}(V')=U\cap U'=\emptyset$$. If $$f(x)=f(x')$$, then it would be in $$V\cap V'$$, which gives a contradiction. Therefore $$f$$ is injective.

Notice that if $$f$$ is surjective, you could also conclude $$f^{-1}(V\cap V')=\emptyset\Rightarrow V\cap V'=\emptyset$$ and therefore $$f(x)\neq f(x')$$.

$$\Rightarrow$$: Assume $$f$$ is injective. Notice also that $$f\colon X\rightarrow Y$$ is open by definition of the induced topology. If $$x,x'\in X$$ with $$x\neq x'$$, then $$f(x)\neq f(x')$$ and there are open subsets $$V,V'\subset Y$$ with $$f(x)\in V$$, $$f(x')\in V'$$ and $$V\cap V'=\emptyset$$. Therefore $$x\in f^{-1}(V)$$ and $$x'\in f^{-1}(V')$$ (which are both open in $$X$$ due to the definition of the induced topology). Since $$f^{-1}(V)\cap f^{-1}(V')=f^{-1}(V\cap V')=f^{-1}(\emptyset)=\emptyset$$, $$X$$ is a Hausdorff space.

EDIT 1: An analogy of the theorem does not hold for the coinduced topology. Let $$f\colon(X,\mathcal{P}(X))\rightarrow Y$$ then $$\mathcal{O}_Y=\{V\subseteq Y|f^{-1}(V)\in\mathcal{O}_X=\mathcal{P}(X)\}=\mathcal{P}(Y)$$. Both $$X$$ and $$Y$$ are Hausdorff, but $$f$$ does not need to be injective nor surjective.

The analogy of the other direction holds: If $$X$$ is Hausdorff and $$f$$ is injective, then $$Y$$ is Hausdorff.

EDIT 2: To prove this, we first notice that $$f$$ injective implies $$f$$ open. If $$U\subseteq X$$ is open, then $$f^{-1}(f(U))=U\subseteq X$$ is open, so by definition $$f(U)\subseteq Y$$ is open.

Let $$y,y'\in Y$$ with $$y\neq y'$$. We can assume $$y,y'\in\operatorname{img}(f)$$ since $$Y\setminus\operatorname{img}(f)$$ is discrete. Let $$x,x'\in X$$ with $$x\neq x'$$ be the respective preimages, then there are open subsets $$U,U'\subseteq X$$ with $$x\in U$$, $$x'\in U'$$ and $$U\cap U'=\emptyset$$. Since $$f$$ is open, $$y\in f(U)$$ and $$y'\in f(U')$$ are open neighborhoods. Since $$f$$ is injective, $$f(U)\cap f(U')=f(U\cap U')=f(\emptyset)=\emptyset$$.

As it was already mentioned in the question, the forward direction is easy, but I just had an idea for a very elegant proof, which I wanted to share and which I think deserves its own answer:

Since $$f$$ is continuous, $$f\times f$$ is continuous and preimages of closed subsets are closed. Since $$f$$ is injective, we have $$\Delta_X=(f\times f)^{-1}(\Delta_Y)$$. Since $$Y$$ is Hausdorff, $$\Delta_Y$$ is closed, therefore $$\Delta_X$$ is closed and $$X$$ is Hausdorff.