TITLE: What is the intuition for the point-set topology definition of continuity?
QUESTION [44 upvotes]: Let $X$ and $Y$ be topological spaces. A function $f: X \rightarrow Y$ is defined as continuous if for each open set $U \subset Y$, $f^{-1}(U)$ is open in $X$. This definition makes sense to me when $X$ and $Y$ are metric spaces- it is equivalent to the usual $\epsilon-\delta$ definition. But why is this a good definition when $X$ and $Y$ are not metric spaces? 
How should we think about this definition intuitively?

REPLY [4 votes]: Intuitively:

Continuous maps are exactly those maps that preserve (in the forward direction) the notion of "closeness": A map $f : X \to Y$ is continuous iff points "close" to each other in $X$ are always sent to points that are (once again) "close" to each other in $Y.$

I now explain what this means exactly and why the most intuitive way of thinking of continuity is actually through its characterization in terms of closed sets${}^{1}$. In short, it allows you define continuous maps as being exactly those maps that preserve a certain property in the forward direction.${}^{2}$ Let me introduce some non-standard (i.e. my own made up, but sensible) definitions:

Say that a point $y$ is close to a set $S$ if $y \in \overline{S}.$
Say that a set $R$ is close to a set $S$ if $R \subseteq \overline{S}$ (i.e. if $R$ is contained in the closure of $S$).

With these definitions, a subset is closed if and only if it contains every point/subset that is close to it (so the terminology "being close" intuitively describes "being closed"). Recall how the closure operator characterizes continuity:
Theorem (non-intuitive statement): A map $f : X \to Y$ is continuous if and only if for all subsets $A \subseteq X$, $f\left( \overline{A} \right) \subseteq \overline{f(A)}$.
This can be restated as:
Theorem (intuitive statement): A map $f : X \to Y$ is continuous if and only if for all subsets $A \subseteq X$, $f$ maps points that are close to $A$ to points that are close to $f(A)$.
You can replace the word "points" above with the word "sets" and the resulting statement will still be true. Thus continuous maps are exactly those that preserve (in the forward direction) the notion of "closeness" in $X$.
If this interpretation is valid then you might expect for the following characterization to also be valid.
Continuity at a given point $x \in X$: $f$ is continuous at $x$ if and only if whenever $x$ is close to a subset $A \subseteq X,$ then $f(x)$ is close to $f(A).$
You can check that this is characterization of continuity at a point does actually hold. It also follows immediately from the above two characterizations that $f$ is continuous if and only if it is continuous at every point of its domain.

You can actually (essentially) define the category of topological spaces using only the closure operator: see Kuratowski closure axioms (technically, this category is equivalent to the category of topological spaces). This justifies thinking of topological spaces in terms of "closeness" rather than open subsets.

This is in contrast to the open set definition of continuity, which defines continuous maps as being those that preserve a certain property (i.e. openness of subsets) in the backwards direction.