# Continuous functions from one topological space to another topological space.

Question: Let $X=\lbrace 1,2,3,4,5 \rbrace$ with topology $\lbrace \emptyset,X,\lbrace 1 \rbrace,\lbrace 3,4 \rbrace,\lbrace 1,3,4 \rbrace\rbrace,$ and let $Y=\lbrace A,B\rbrace$ with topology $\lbrace \emptyset,Y,\lbrace A\rbrace\rbrace.$ Find all continuous functions from $X\to Y$.

I know that given any open subset U in Y, f^{-1}(U) must be open in X. Now, how do I list and find these functions for the above spaces?

You need $f^{-1} V \in \tau_X$ for all $V \in \tau_Y$. The only member of $\tau_Y$ that is relevant is $\{A\}$. To be continuous, we must have $f^{-1}\{A\} \in \tau_X$. There are only $5$ possibilities, and $f$ must take the value $B$ on the complement.
The functions are straightforward to list. For example, if $f^{-1}\{A\} = \emptyset$, then $f(x) = B$ for all $x$. Another, if $f^{-1}\{A\} = \{1\}$, then $f(1) = A$ and $f(x) = B$ for all $x \neq 1$.
• @JuliusJackson: Yes, if you set $f^{-1} \{A\} = X$, then $f(x) = A$ for all $x$. – copper.hat Oct 25 '13 at 3:25
• To be continuous, you must have $f^{-1}V$ be open for all open $V$. Since there are only 3 possibilities for $V$ it is easy to check. $f^{-1} \emptyset$ is always $\emptyset$, so there is nothing you can do about that and $f^{-1} Y$ is always $Y$, so the only open set that really matters is $\{A\}$. Then $f^{-1} \{A\}$ must be one of the 5 sets in the $X$ topology, and once you select one of the 5, you have completely defined $f$ (since the only other value it can take is $B$). Hence there are exactly five continuous functions. – copper.hat Oct 25 '13 at 4:49