Metric Space Continuity by Inverse of Mapping between Neighborhoods

Theorem
Let $M_1 = \left({A_1, d_1}\right)$ and $M_2 = \left({A_2, d_2}\right)$ be metric spaces.

Let $f: A_1 \to A_2$ be a mapping from $A_1$ to $A_2$.

Let $a \in A_1$ be a point in $A_1$.

$f$ is continuous at $a$ with respect to the metrics $d_1$ and $d_2$ iff:
 * for each neighborhood $N'$ of $f \left({a}\right)$ in $M_2$, $f^{-1} \left[{N'}\right]$ is a neighborhood of $a$.

Proof
By definition, $f$ is continuous at $a$ with respect to the metrics $d_1$ and $d_2$ iff:
 * for each neighborhood $N'$ of $f \left({a}\right)$ in $M_2$ there exists a corresponding neighborhood $N$ of $a$ in $M_1$ such that $f \left[{N}\right] \subseteq N'$.

For a mapping $f: X \to Y$ we have:


 * $f \left[{U}\right] \subseteq V \iff U \subseteq f^{-1} \left[{V}\right]$

where $U \subseteq X$ and $V \subseteq Y$.

Hence the result.