Understanding properties of preimages through an example problem I am reading a proof I found on the site and trying to figure out a fact about the preimages of projections. The setup for the problem was the following.

Let $X$ be the union of the coordinate axes in the product set $\mathbb{R}^{\mathbb{N}}$. For each $i \in \mathbb{N}$ we define a map $f_i: \mathbb{R} \to X$ as follows: $f_i(x)_j=x$ when $i=j$ and $f_i(x)_j=0$, when $i \ne j$.

Then what they had was they considered a subbase element $\pi_n^{-1}(V)$ where $V$ is open in $\Bbb R$ and claimed that the two following results hold if $i=n$ $$f^{-1}_n(\pi_n^{-1}(V) \cap X) = V $$ and if $ i \ne n$ and $0 \ne V$, then $$f^{-1}_i(\pi_n^{-1}(V) \cap X) = \emptyset $$ and if $0 \in V$, then $$f^{-1}_i(\pi_n^{-1}(V) \cap X) = \Bbb R$$
how are these results true? I think I have issues with understanding the preimages.
 A: Remark: $X$ is just the set $\bigcup_{i \in \Bbb N} f_i[\Bbb R]$ if you think  about it. So $f_n: \Bbb R \to X$ is well-defined.
Just check by inclusions and pointwise reasoning:
If $i=n$ we want $f_n^{-1}[\pi_n^{-1}[V] \cap X]] = V$. Let $x \in V$. Then $f_n(x)$ has $n$-th coordinate equal to $x$ by definition of the $f_i$, which means $\pi_n(f_n(x))=x$ so $f_n(x) \in \pi_n^{-1}[V]$ by definition. Also $f_n(x) \in X$, so indeed $x \in f_n^{-1}[\pi_n^{-1}[V] \cap X]]$.
OTOH if $x \in f_n^{-1}[\pi_n^{-1}[V] \cap X]]$ we know that $f_n(x)$ must be in $X \cap \pi_n^{-1}[V]$ so $f_n(x) \in X$ (no surprise) and $\pi_n(f_n(x)) \in V$. But by definition $ \pi_n(f_n(x)) = x$. So $x \in V$. This shows two inclusions, hence equality.
If $i \neq n$ consider $x \in f_i^{-1}[\pi_n^{-1}[V] \cap X]]$. So  as before $\pi_n(f_i(x)) \in V$. But by definition, whatever $x$ is, $\pi_n(f_i(x))= 0$. So either this holds for all $x$, when $0 \in V$ or it holds for none at all in the case $0 \notin V$. So the set $f_i^{-1}[\pi_n^{-1}[V] \cap X]]$ equals $\Bbb R$ or $\emptyset$ depending on that, which is what the last two statements say.
