Prove $f: X \rightarrow Y$ is continuous if $A_a$ is closed and $f|A_a$ is continuous for any $a$ and $\text{{$A_a$}}$ is locally finite collection Let $f:\bigcup_{\alpha}A_{\alpha} \rightarrow Y$ be a function between the topological spaces Y and $X=\bigcup_{\alpha}A_{\alpha}$. Suppose that $f|A_{\alpha}$ is a continuous function for every $\alpha$ and that $\text{{$A_{\alpha}$}}$ is locally finite collection. Suppose that $A_{\alpha}$ is closed for every $\alpha$.
Show that: $f$ is continuous.
Any hints? 
 A: We denote  $f_{\alpha}:=f/A_{\alpha}$. Let $F$ be a closed subset of $Y$, we have 
$f^{-1}(F)=\cup_{\alpha}f_{\alpha}^{-1}(F)$, now for each $\alpha$, $f_{\alpha}^{-1}(F)$ is a closed subset  $A_{\alpha}$ hence it is a closed subset (in $X$). To finish we want to show that $f^{-1}(F)$ is closed. Let $x\in \overline{f^{-1}(F)}$, and fix a neighborhood $V$ of $x$ which intersect only a finitely many of the sets  $A_{\alpha_1},\ldots,A_{\alpha_d}$, it is clear that each neighborhood $W$ of $x$ intersect $\cup_{i=1}^df_{\alpha_i}^{-1}(F)$, hence $x\in \overline{\cup_{i=1}^df_{\alpha_i}^{-1}(F)}=\cup_{i=1}^df_{\alpha_i}^{-1}(F)\subset f^{-1}(F)$.      
A: Recall that a function $f:X \to Y$ between topological spaces is continuous iff $f^{-1}(A)$ is closed for every closed set $A$ of $Y$.
What are the closed sets of $X = \bigcup_\alpha A_\alpha$? Why is it necessary for $\{A_\alpha\}$ to be locally finite collection? 
A: Lemma: Let $W\subset X$ be such that for all $\alpha\;W\cap A_\alpha$ is open in $A_\alpha$. Then $W$ is an open subset of $X$.
Proof: Let $p\in W$. Since $\{A_\alpha\}$ is locally finite, there is an open neighborhood $p\in O$, such that $O$ intersects only finitely many $A$'s, say $A_1,\ldots,A_n$. Of all those $A_1,\ldots,A_n$, say $p$ lies in $A_1,\ldots,A_m$ where $m\leq n$. Since $A_{m+1}\cup\ldots\cup A_n$ is closed in $X$ and does not contain $p$, there is an open $O'\subset O$ that contains $p$ and does not intersect $A_{m+1},\ldots,A_n$.
For $i=1,\ldots,m$, $W\cap A_i$ is open in $A_i$ and contains $p$, thus there is an open $V_i\subset X$ containing $p$, such that $V_i\cap A_i\subset W\cap A_i$. We claim that $$\left(\bigcap_{i=1}^mV_i\right)\cap O'\subset W.$$To see this, let $q$ be some point in LHS. Since $q\in O'$, we have $q\in A_i$ for some $i=1,\ldots,m$, thus $q\in A_i\cap V_i\subset W$.
This should be enough.
A: Let $C\subset Y$ be any closed set. To prove continuity of $f$, it is to be shown that $f^{-1}(C)$ is a closed set.
Note that $f^{-1}(C)=\cup_\alpha (f^{-1}(C)\cap A_\alpha)=\cup_\alpha f|A_\alpha^{-1},$ where each of the sets in union is a closed set in $X$ as $A_\alpha$'s are given to be closed.
Take any $t\in \rm cl$$(f^{-1}(C)).$  By locally finiteness property, there exists a neighbourhood $U_t$ of $t$ and finitely many indices $\alpha_i, i=1,2,...,n$ such that $U_t\cap A_\alpha=\emptyset$ for all $\alpha \notin \{\alpha_i: 1\le i\le n\}$. Note that $U_t=\cup_{k=1}^n (U_t\cap A_{\alpha_k})$.
For any neighbourhood $V_t$ of $t$, $V_t\cap U_t$ is also a neighbourhood of $t$. Also, $U_t\cap V_t\cap f^{-1}(C)=\cup_{k=1}^n (U_t\cap V_t\cap f|_{A_{\alpha_k}}^{-1}(C))=V_t\cap (\cup_k(U_t\cap f|_{A_{\alpha_k}}^{-1}(C)))\subset V_t\cap  (\cup_k f|_{A_{\alpha_k}}^{-1}(C))$.
Since $U_t\cap V_t\cap f^{-1}(C)$ is non empty (as $t$ is in closure of $f^{-1}(C)$), it follows that $V_t\cap(\cup_k f|_{A_{\alpha_k}}^{-1}(C)) $ is non empty. Since $V_t$ is arbitrary neighbourhood of $t$, it follows that $t\in \rm cl$$(\cup_k f|_{A_{\alpha_k}}^{-1}(C))$, which is a closed set by remark in the second paragraph. It follows that $\rm cl$$(\cup_k f|_{A_{\alpha_k}}^{-1}(C))= \cup_k f|_{A_{\alpha_k}}^{-1}(C)$. So $t\in \cup_k f|_{A_{\alpha_k}}^{-1}(C)\subset f^{-1}(C)\implies t\in f^{-1}(C).$ Since $t\in \rm cl$$(f^{-1}(C))$  was chosen arbitrarily, it follows that
$\rm cl$$(f^{-1}(C))=f^{-1}(C)\implies f^{-1}(C)$ is closed.
