Mathematics Stack Exchange is a question and answer site for people studying math at any level and professionals in related fields. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

$ f:X \rightarrow Y$ be a continuous map and $c \in Y$. Is $\{x \in X | f(x)=c\}$ necessarily a closed subset of $X$?


I was thinking about a contradiction. Can this be a counterexample? $f(x) = \frac{1}{x^2+1}$ is continuous on the whole real line and and the image of the set $[0,\infty)$ is the set $(0,1]$. So we have found a closed set, whose image under a continuos function is not closed(and nor open).

share|cite|improve this question
The question isn’t about the images of subsets of $X$: it’s about the inverse images of singleton subsets of $Y$. – Brian M. Scott Dec 18 '12 at 12:22
I believe it is not necessarily a closed subset. so what can be a decent counterexample? – John Lennon Dec 18 '12 at 12:25
up vote 2 down vote accepted

If $Y$ is a $T_1$-space, so that singleton sets are closed, then $\{x\in X:f(x)=c\}$ is just the inverse image under $f$ of the closed set $\{c\}$ in $Y$, so by continuity of $f$ it is closed in $X$.

If there is a $c\in Y$ such that $\{c\}$ is not closed in $Y$, then $\{x\in X:f(x)=c\}$ need not be closed in $X$. For example, let $Y=\{0,1\}$, and let the open set of $Y$ be $\varnothing, \{1\}$, and $\{0,1\}$. ($Y$ is the Sierpiński space.) Note that $\{0\}$ is not open in $Y$, so $\{1\}$ is not closed. Define $f:\Bbb R\to Y$ by

$$f(x)=\begin{cases}0,&\text{if }x\le 0\\1,&\text{if }x>0\end{cases}\;;$$

it’s easy to check that $f$ is continuous, but $\{x\in\Bbb R:f(x)=1\}$ is not closed in $\Bbb R$.

share|cite|improve this answer

You will not find a counterexample where $Y$ is the real line. This is because points are closed in the real line, and if $f$ is continuous then the inverse images of closed sets are closed. (Note that $\{ x \in X : f(x) = c \} = f^{-1} [ \{ c \} ]$.)

Instead, you should consider topological spaces where points are not closed.

A good example would be $Y = \{ 0 , 1 \}$ with the indiscrete (trivial) topology. Now let $X$ be any space which has a non-closed subset $A$, and consider the mapping $f : X \to Y$ defined by $$f(x) = \begin{cases} 0, &\text{if }x \notin A \\ 1, &\text{if }x \in A.\end{cases}$$ That $Y$ is given the trivial topology means that any function $X \to Y$ is continuous, and taking $c = 1$ we have that $\{ x \in X : f(x) = c \} = A$ is not closed by choice.

share|cite|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.