Measurability of a pointwise limit of measurable functions Fellows. I'm trying to prove some measurability result and I figured out a solution using the following and now I wonder if this is actually true.
Let $X$ be a topological space and $Y$ be a Polish space and let $f_n:(X,\mathcal{B}_X)\to(Y,\mathcal{B}_Y)$ be a sequence of measurable functions.
Assume the pointwise limit $f(x):=\lim_{n\to\infty}f_n(x)$ exists for all $x\in X$. Then the function $f$ is again measurable. 
Is this true? I know this result holds for $Y=\mathbb{R}$, but is it also satisfied for more general spaces? My intuition says yes, since Polish spaces have a countable base and are completely metrizable, but I have no clue how to prove it. Just to be clear, I'm not asking for a proof of this result (unless super-easy), but a reference would be great. Thanks a lot!
 A: Since $Y$ is a Polish space, the Borel-$\sigma$-algebra $\mathcal{B}(Y)$ is generated by the open balls
$$\mathcal{G}_Y := \{B_Y(y,r); y \in Y, r>0\}.$$
Consequently, it suffices to show that $f^{-1}(G) \in \mathcal{B}(X)$ for any $G \in \mathcal{G}_Y$. For $G:=B_Y(y,r)$, we have
$$f(x) = \lim_{n \to \infty} f_n(x) \in B_Y(y,r)$$
if, and only if, $$\exists k=k(x) , N=N(x) \in \mathbb{N} \, \, \forall n \geq N: f_n(x) \in B_Y\left(y,r- \frac{1}{k} \right).$$
Hence,
$$\{x; f(x) \in B_Y(y,r)\}= \bigcup_{\substack{k \in \mathbb{N} \\ \frac{1}{k} < r}} \bigcup_{N \in \mathbb{N}} \bigcap_{n \geq N} \underbrace{\{f_n \in B_Y(y,r-1/k)\}}_{\in \mathcal{B}(X)}.$$
Since the right-hand side is a countable union of Borel sets, we conclude $$\{f \in G\} = \{f \in B_Y(y,r)\} \in \mathcal{B}(X).$$
A: Perhaps a little late to the party, but I just want to point out that the only thing needed for this result to hold is for the topology of $Y$ to have the following property: that for each open set $U$ there exists a sequence $(A_k)_{k\in\mathbb{N}}$ of open sets such that $U=\bigcup_{n\in\mathbb{N}}A_k$ and $\overline{A_k}\subseteq U$ for all $k\in\mathbb{N}$.
Indeed, let $\mathcal{T}$ be the set of open sets in $Y$, and let $U\in\mathcal{T}$. By our assumption, there exists a sequence $A\in\mathcal{T}^\mathbb{N}$ such that $\overline{A_k}\subseteq U$ for each $k\in\mathbb{N}$ and $U=\bigcup_{k\in\mathbb{N}}A_k$. We can now prove that:
$$f^{-1}(U) = \bigcup_{k\in\mathbb{N}}\;\bigcup_{n\in\mathbb{N}}\;\bigcap_{p\in\mathbb{N}}f^{-1}_{n+p}(A_k)
$$
In order to see this, first let $x\in f^{-1}(U)$; then $f(x)\in U$, whence there exists $k\in\mathbb{N}$ with $f(x)\in A_k$. Now, since $f_n(x)\rightarrow f(x)$, there exists $n\in\mathbb{N}$ such that for all $p\in\mathbb{N}$ we have $f_{n+p}(x)\in A_k$. Thus, $x$ is an element of the right-hand side. Now, let $x$ be an element of the right-hand side ; this implies that there exist $k,n\in\mathbb{N}$ such that, for all $p\in\mathbb{N}$, $f_{n+p}(x)\in A_k$. But this implies that a tail of the sequence $(f_n(x))_{n\in\mathbb{N}}$ is contained in $A_k$, whence $f(x)\in\overline{A_k}\subseteq U$. Thus, $x\in f^{-1}(U)$.
With this equality in hand, the $\mathcal{B}(X)/\mathcal{B}(Y)$-measurability of $f$ follows from the fact that $f^{-1}(U)\in\mathcal{B}(X)$ for all open sets $U$ (since $f^{-1}(U)$ is constructed as countable unions and intersections of elements of $\mathcal{B}(X)$, via the $\mathcal{B}(X)/\mathcal{B}(Y)$-measurability of the $f_n$ and our previous equality), and from the fact that $\mathcal{B}(Y)=\sigma(\mathcal{T})$.
Edited for typos.
