Showing a set is closed in the product topology

continuitygeneral-topologyproduct-space

We have some topological space $X$ with continuous functions $f,g:X \rightarrow \mathbb{R}$ equipped with the usual topology I want to show that then set:
$$E = \{(x,y):f(x)=g(y)\} \subset X \times X $$ is closed in $X \times X$ with the product topology.

So I need to show that $(X \times X) \setminus E$ is open, but I’m not sure how.

Best Answer

Note that $h(x, y)=f(x)-g(y)$ is continuous because $f$ and $g$ are. Then $(X \times X) \setminus E = h^{-1}(\Bbb R \setminus \{0 \})$. Since $\Bbb R \setminus \{ 0 \}$ is open and $h$ is continuous, you have the result you need.

Related Question