Topology - function is continuous definition clarifications In Rudin - Real and complex Analysis we have written:
If $X$ and $Y$ are topological spaces and if $f$ is a mapping of $X$ into $Y$, then $f$ is said to be continuous provided that $f^{-1}(V)$ is an open set in $X$ for every open set $V$ in $Y$.
Can you help clarify what this means? I have thought on, and I don't get it. 

This is my attempt to understand, perhaps you can highlight my issues with this:
So $X$ and $Y$ both have a topology over them, firstly, I have no idea if this is the same or a different topology. I imagine it is only the same if $X=Y$, so here is different in all cases other than that.
We have $f:X\to Y$, and we (obviously) have $f^{-1}:Y\to X$. We say that $f$ is continuous if we can go back from $Y$ to $X$, and when we do so from any open set in $Y$, we obtain an open set of $X$.
I think that all of the elements of the topology $X$ are open sets in $X$, and hence we simply need $f^{-1}$ to map to some element in $X$, but that seems pointless, since then any topological space with a mapping would be continuous?
 A: $X$ and $Y$ can have different topologies.  Even if $X$ and $Y$ are the same set, they can have different topologies. For example $X=Y=\mathbb{R}$, $X$ has the standard topology on $\mathbb{R}$ and $Y$ has the Lower limit topology. In this example, sets like $[a,b)$ are open in $Y$ and sets like $(c,d)$ are open in $X$ (without getting into arbitrary unions of open sets at least). So if there is a continuous function $f:X \to Y$ then we would expect to see something like $f^{-1}\left([a,b)\right) = (c,d)$ or $f^{-1}\left([a,b)\right)$ being equal to some other open set in $X$. 
Was there a proof of the equivalence of topological continuity and $\varepsilon$-$\delta$ continuity in your text? If not, I highly recommend you prove that result. Getting a firm understanding of how the two definitions imply each other should go a long way in improving your understanding of topological continuity. The "inverse-image of open sets is open" definition is not very intuitive, but it is important for success in topology.
A: One source of confusion is loading $f^{-1}$ with two meanings.
Given a function $f: X \to Y$, you first see $f^{-1}$ defined only when $f$ is a bijection, in which case $f^{-1}: Y \to X$ is the inverse of $f$. Unfortunately, that's not the case here.
In this situation, $f^{-1}(B)$ denotes the preimage of a subset $B \subseteq Y$, so that $f^{-1}(B)=\{x \in Y : f(x) \in B\}$. 
To make things perfectly clear, I'd like to stop overloading $f^{-1}$, and instead use the notation $\bar{f}^{-1}$ to denote the preimage function of $f$ To highlight exactly what our preimage function maps between. As it takes as input subsets of our codomain, and returns subsets of our domain, it would be more precise to write 
$$ \bar{f} : P(X) \to P(Y) $$
for our image function of $f$, writing $\bar{f}(A) =\{f(x) : x \in A\}$ instead of the usual $f(A)$, and
$$ \bar{f}^{-1} : P(Y) \to P(X)$$
for our preimage function. This viewpoint makes it clear that $\bar{f}$ and $\bar{f}^{-1}$ are really functions between the $P(X)$ and $P(Y)$, the power sets of $X$ and $Y$.
Now, with topological spaces $X$ and $Y$, we're given special collections of subsets $\tau_X \subseteq P(X)$ and $\tau_Y \subseteq P(Y)$ declared to be open, satisfying certain properties. However, there's no reason that if we restrict our preimage function $\bar{f}^{-1}$ to the open subsets of $Y$, that we should only get open subsets of $X$, for every function $f$. This is exactly why continuity is defined; to single out such special functions! 
More precisely, the function $f : X \to Y$ is called continuous if the restriction of $\bar{f}^{-1}$ to $\tau_Y$ is a function to $\tau_X$; that is, we have
$$\bar{f}^{-1}: \tau_Y \to \tau_X.$$
I realize this is a (possibly even more) abstract way of thinking about continuity, but I got the impression that you may benefit from seeing it spelled out, very clearly, what all the moving pieces are, and where they're coming from.
