# Why is that any function from $X$ to the trivial topological space is continuous?

I think this is a super silly question, but I just can't figure out why is that given any function $f: X \to Y$, where $(X, \mathcal{T})$ is an arbitrary topological space, and $(Y, \mathcal{T}_{trivial})$ where $\mathcal{T}_{trivial} = \{\varnothing, Y\}$

Okay, so $f^{-1}(\varnothing) = \varnothing \in \mathcal{T}$, but how do we know that $f^{-1}(Y) \in \mathcal{T}?$ Since the preimage of the codomain is not necessarily the domain When is the preimage of codomain not equal to domain?

Why couldn't there be a case where $f^{-1}(Y) = U \subset X$, but $U \notin \mathcal{T}?$

Edit: So is it always the case that $f^{-1}(Y) = X$, given $f: X \to Y$?

• the preimage of the codomain is the domain; everything in $X$ gets maps to $Y$. – yoyo Jun 3 '16 at 21:55
• All the points of the domain are mapped to the codomain so the preimage of the codomain contains the domain. – Masacroso Jun 3 '16 at 22:06
• Buf of course $f^{-1}(Y) = X$, for every function $f\colon X\to Y$. For every $x\in X$, $f(x)\in Y$, so $x \in f^{-1}(Y)$. Your title is a little confusing. There are many "trivial" (indiscrete) spaces. I thought by "the" trivial space that perhaps you meant a/the one-point space. – BrianO Jun 4 '16 at 0:00
• @BrianO Sorry, calling it the indiscrete topology from now on – Carlos - the Mongoose - Danger Jun 4 '16 at 0:13

By definition, for $f\colon X\to Y$ and $B\subseteq Y$, $$f^{-1}(B)=\{x\in X:f(x)\in B\}$$ In particular, for $B=Y$, $$f^{-1}(Y)=\{x\in X:f(x)\in Y\}$$ and therefore $f^{-1}(Y)=X$.