§ Pasting lemma
Let f:X→Y be a function.
Let A,B are closed subets of X such that X=A∪V. Then f is continuous iff
f∣A and f∣B are continous.
§ Forward: f continuous implies restriction continuous
This is clear from how restrictions work. Pick i:A→X to be the
function that embeds A with the subspace topology into X. This is continuous by
the definition of the subspace topology. Now define f∣A:A→Y≡f∘i.
which is continous since it is the composition of continuous functions.
§ Backward: restrictions continuous implies f continuous.
Let V⊆Y be closed. Then fA−1(V) is closed in A by the continuity of fA
Now see that fA−1(V) is closed in the subspace topology of A means that
there is some closed P⊆X such that f∣A−1(V)=A∩P.
Since both A and P are closed in X, this means that f−1(V) is closed
in X (see that we have filted "closed in A" to "closed in X).
Similarly, we will have that f∣B−1(V)=B∩Q for some closed B and Q.
Then we can write:
f−1(V)=f∣A−1(V)∪f∣B−1(B)=(A∩P)∪(B∩Q)=finite union of closed sets=closed