I'm thinking about Hausdorff spaces, and how mappings to Hausdorff spaces behave. Suppose I have an arbitrary (continuous) function $f:X \longrightarrow Y$, where $Y$ is a Hausdorff space (I think it is irrelevant for my question whether $X$ is Hausdorff or not, so I just consider it to be a topological space - if this is incorrect, please correct me!).

Can we say that the graph $$G_f=\{(x,f(x)) \in X \times Y\ : x \in X \}$$ is a closed subset of $X \times Y$? It seems quite obvious that it is the case, but I cannot see how to prove it. If anyone can offer a proof I'd be very interested. Regards.


In response to Hennning Makholm:

I wasn't really aware of any variation in 'definition'; I guess I'm considering closed sets to be those with an open complement (though naturally this definition gives rise to other definitions, such as the subset equalling its closure etc.). For continuity of such a map, I would normally consider continuity to mean that $f^{-1}(V)$ is closed in $X$ whenever $V$ is closed in $Y$, though again definitions involving convergence of sequences and the notion that $f$ is continuous iff $f(\overline{A}) \subset \overline{f(A)}$ for every $A \subset X$ are also known to me.

  • $\begingroup$ Yes, this is true (but only if $f$ is continuous). The details of proving it are sensitive to the exact definition of "closed" and "continuous" you're using. Please amend your question to contain the relevant definitions. $\endgroup$ Feb 13, 2012 at 0:47
  • 1
    $\begingroup$ @HenningMakholm: I have attempted to clarify, though I thought such ideas were reasonably standardised. $\endgroup$
    – Mathmo
    Feb 13, 2012 at 1:03
  • $\begingroup$ Yes, this is true for arbitrary continuous functions, and for linear functions between Banach spaces, the converse (closed graph implies continuous) is also true: en.wikipedia.org/wiki/Closed_graph_theorem $\endgroup$ Feb 13, 2012 at 1:07

2 Answers 2


Suppose that $\langle x,y\rangle\in (X\times Y)\setminus G_f$. Then $y\ne f(x)$, and $Y$ is Hausdorff, so there are disjoint open $U,V$ in $Y$ such that $y\in U$ and $f(x)\in V$. Since $f$ is continuous, there is an open nbhd $W$ of $x$ such that $f[W]\subseteq V$; clearly $W\times U$ is an open nbhd of $\langle x,y\rangle$ disjoint from $G_f$.

It is necessary to require that $Y$ be Hausdorff. For a simple example, let $X=\{0,1\}$ have the discrete topology, and let $Y=\{0,1\}$ with the Sierpiński topology, whose open sets are $\varnothing,\{0\}$, and $Y$ itself. Let $f:X\to Y$ be the identity function; $f$ is certainly continuous, since $X$ is discrete, but $\langle 0,1\rangle$ is in the closure of $G_f$, since every nbhd of $\langle 0,1\rangle$ contains $\langle 0,0\rangle$.

Added: The space $Y$ in that example is $T_0$ but not $T_1$; here’s an example in which $Y$ is $T_1$. Let $X=\mathbb{N}\cup\{p\}$, where $p\notin\mathbb{N}$, and let $Y=\mathbb{N}\cup\{p,q\}$, where $q\notin\mathbb{N}$ and $p\ne q$. In both $X$ and $Y$ the points of $\mathbb{N}$ are isolated, and in both $X$ and $Y$ a local base at $p$ consists of all sets of the form $\{p\}\cup(\mathbb{N}\setminus F)$ such that $F$ is a finite subset of $\mathbb{N}$. Finally, a local base at $q$ in $Y$ consists of all sets of the form $\{q\}\cup(\mathbb{N}\setminus F)$ such that $F$ is a finite subset of $\mathbb{N}$. The points $p$ and $q$ in $Y$ do not have disjoint open nbhds; they are the only pair of points in $Y$ that cannot be separated by disjoint open sets.

Let $f:X\to Y:x\mapsto x$ be the identity function; it’s easy to see that $f$ is not just continuous, but an embedding. The point $\langle p,q\rangle\in X\times Y$ is not in $G_f$, but you can check that if $U$ is an open nbhd of $\langle p,q\rangle$ in $X\times Y$, then there is an $m\in\mathbb{N}$ such that $\langle n,n\rangle\in U$ whenever $n\ge m$, so $U\cap G_f\ne\varnothing$. Thus, $\langle p,q\rangle$ is in the closure of $G_f$.

  • $\begingroup$ I have a counterexample showing that $G_f$ is not closed in $X\times Y$ : suppose $y=x^3$ and $x\in [1,3]$ and suppose $U_a$ be any open set in standard topology on $\mathbb{R}^2$ such that $U_a \cap G_f=$∅. Because union of all $U_a$'s is open and equals $\mathbb{R}^2-G_f$, then $G_f$ is closed in $X\times Y=\mathbb{R}^2$. Am I right? $\endgroup$
    – user200918
    Jan 3, 2015 at 9:25
  • 3
    $\begingroup$ @Ali.E.: I can’t make any sense of this. First you say that $G_f$ is not closed, then you say that it is. Also, you write $X\setminus G_f$, as if $G_f$ were a subset of $X$, but then you say that $G_f$ is a subset of $X\times Y$. Finally, you seem to limit $x$ to the set $[1,3]$, in which case $\Bbb R^2$ is irrelevant: you should be asking whether $G_f$ is closed in $[1,3]\times\Bbb R$. $\endgroup$ Jan 3, 2015 at 9:29
  • $\begingroup$ Yes, sorry! My counterexample is not correct; in fact, I have given an example that $G_f$ is closed, as it must be. I edited $X\setminus G_f$ to $\mathbb{R}^2-G_f$. $\endgroup$
    – user200918
    Jan 3, 2015 at 9:40
  • $\begingroup$ @Ali.E.: The edited version is correct. However, it does take some work to show that the union of those sets $U_a$ actually is all of $\Bbb R^2\setminus G_f$. $\endgroup$ Jan 3, 2015 at 9:44
  • $\begingroup$ What if we consider an open interval $x\in (1,3)$. Then $f(x)$ would be a curve not including $f(1)$ and $f(3)$, which is homomorphic to an open interval on real line, say $U=(a,b)$, by just defining a bijective function between $G_f$ and $U$. Is is right that $G_f$ is open? $\endgroup$
    – user200918
    Jan 3, 2015 at 10:17

Suppose $(x,y)\in \overline {G_f}$, then there is a net $(x_\alpha,f(x_\alpha))\ (\alpha\in \Lambda)$ so that $(x_\alpha,f(x_\alpha))\to (x,y)$ by the definition of the product topology $x_\alpha$ converges to $x$ and $f(x_\alpha)$ converges to $y$ since $f$ is continuous $f(x_\alpha)$ converges to $f(x)$. Since $Y$ is Hausdorff limits are unique hence $y=f(x)$. Thus, $(x,y)\in G_f$ so $G_f$ is closed.


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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