1. ## Topological Spaces

Let X and Y be a topological spaces.
Suppose X is the union of two closed subsets A and B of X .
Let f: A -> Y and g: B-> Y be continuous.
If f(x)=g(x) for every x in the intersection of A and B, then let h: X -> Y be a function defined by setting h(x)=f(x) for x in A, and h(x)=g(x) for x in B.

Then could we say that h is continuous ? Why?

2. Originally Posted by lttlbbygurl
Let X and Y be a topological spaces.
Suppose X is the union of two closed subsets A and B of X .
Let f: A -> Y and g: B-> Y be continuous.
If f(x)=g(x) for every x in the intersection of A and B, then let h: X -> Y be a function defined by setting h(x)=f(x) for x in A, and h(x)=g(x) for x in B.

Then could we say that h is continuous ? Why?
This is called the gluing lemma. It applies to finitely many closed sets and arbitrarily many open.

So, suppose that $X=A\cup B$ where $A,B$ are closed subspaces of $X$ and $f:A\to Y$ and $g:B\to Y$ are continuous functions such that $f\mid_{A\cap B}=g\mid_{A\cap B}$ then $f\sqcup g:X\to Y:x\mapsto\begin{cases}f(x)\quad\text{if}\quad x\in A\\g(x)\quad\text{if}\quad x\in B\end{cases}$ is well-defined since $f,g$ agree on the intersection of their domains. Also, it's continuous since if $E\subseteq Y$ is closed it is easy to see that $\left(f\sqcup g\right)^{-1}(E)=f^{-1}(E)\cup g^{-1}(E)$. But, since $f,g$ are continuous $f^{-1}(E),g^{-1}(E)$ are closed subspaces of $A,B$ respectively but since they themselves are closed subspaces of $X$ it follows that so are $f^{-1}(E),g^{-1}(E)$. Thus, $\left(f\sqcup g\right)^{-1}(E)$ is the finite union of closed sets and thus closed. The conclusion follows.

This can be generalized, as I said, to a finite partition of closed sets or an arbitary partition of open ones.