Roughly, a continuous map is a mapping that is open preserving, i.e., a function \(f: X\rightarrow Y\) where \(X, Y\) are top spaces, such that the preimage of any open in \(Y\) is open in \(X\). In other words: \(\forall O\in\mathcal{O}(Y): f^{-1}(O) \in \mathcal{O}(X). \) The identity map \(\operatorname{id}_X\) is continuous for any top space \(X\).
In order for \(f\) to be continuous, it is enough that the preimages of sets comprising some prebase of \(Y\) be open.
Let \(f: X\to Y\) be continous. For any \(A \subset X\) and \(B\subset Y\), if \(f(A) \subset B\), then the compression \(\operatorname{ab} f: A\to B\) is continuous. In particular, the restriction \(f\vert_A\) is continuous. Similarly, \(\operatorname{ab} f: X \to B\) is continous if and only if \(f: X\to Y\) is continuous. In particular, \(f: X\to Y\) is continuous if and only if \(f: X\to f(X)\) is continuous.