# Prove that a function from a metric space X into the metric space Y is continuous.

$\def\bdy{\operatorname{bdy}}\def\interior{\operatorname{int}}$(1) Prove that a function from a metric space X into the metric space Y is continuous if and only if for each $$A \subset X , f(\bar A) \subset \overline {f(A)} .$$

(2) Prove that if $f$ is a one to one mapping from the metric space X into the metric space Y, show that $f$ is a homeomorphism if and only if, for each $$A \subset X, f(\bar A)=\overline {f(A)}.$$

Attempt at one. $\bar A=\interior(A) \cup \bdy A$. So x $\in A$ then $f(x) \in f(\bar A)$ also $f(x) \in \overline {f(A)}$. If $x \in \bdy A$ then $f(x) \in f(\bar A)$ like wise $f(x) \in \overline {f(A)}$. But $$f(\bar A)=f(A) \cup f(\bdy A)$$ $f(\bar A)$maybe a open set where $\overline {f(A)}$ is a closed set containing the $$\bdy f(A) \cup f(A).$$ Now $\bdy f(\bar A) \not= \bdy\overline {f(A)}$ because $f(\bar A)$may be an open set in Y. Where as $\overline {f(A)}$ is closed so it contains all boundary points. Do not really have a clue how to do the converse.

Attempt at 2: Since $f$ is one to one and a homeomorphism we know that for every $f(a) \in f( A)$ are distinct so we need only to show that $$\bdy f(A)=f(\bdy A).$$ Not quite sure how do prove that and also not sure how to prove converse.

-
That $\bdy$ notation makes me feel weird. I'm used to $\partial A$ for the boundary of $A$. –  Patrick Da Silva Nov 26 '12 at 8:34

(1) I can't quite follow what you're trying to do here. I would suggest instead looking at the sequential characterization of continuity for metric spaces. That is a function $f: X \rightarrow Y$ is continuous if and only if for every sequence $x_n \rightarrow x$ we have $f(x_n) \rightarrow f(x)$.

(2) This question needs a bit of tweaking. Either the assumptions should include that $f$ is onto or the problem should be to show that $f$ is an embedding. Regardless the idea here is to use apply (1) to $f$ and $f^{-1}$ to get your desired result.

-
1. If $f$ is continuous then $f(\bar A)\subset\overline{f(A)}$ for all $A\subset X$: Remember that if $B$ is any set then $x\in\bar B$ if and only if for every open nbhd $U$ of $x$, $U\cap B\ne\emptyset$. So, let $y\in f(\bar A)$. To show that $y\in\overline{f(A)}$, let $V$ be an open nbhd of $y$. Now there exists some $x\in\bar A$ such that $y=f(x)$ and, since $f$ is continuous, $f^{-1}(V)$ is an open nbhd of $x$. Can you finish from here?
2. If $f(\bar A)\subset\overline{f(A)}$ for every $A\subset X$ then $f$ is continuous: To show that $f$ is continuous, we only need to show that the preimage of every closed set is closed. So, let $F\subset Y$ be closed. Now it's enough to show that $\overline{f^{-1}(F)}\subset f^{-1}(F)$. From the given property of $f$ we get that $$f\left(\overline{f^{-1}(F)}\right)\subset\overline{f(f^{-1}(F))}\subset\overline F=F.$$ Therefore, since $B\subset f^{-1}(f(B))$ for all $B$, we have $$\overline{f^{-1}(F)}\subset f^{-1}\left(f\left(\overline{f^{-1}(F)}\right)\right)\subset f^{-1}(F).$$
3. If $f$ is one to one and onto, and $f(\bar A)=\overline{f(A)}$ for every $A\subset X$, then $f$ is a homeomorphism: Now $f(\bar A)\subset\overline{f(A)}$ for every $A\subset X$ so, by (2), $f$ is continuous. On the other hand if $B\subset Y$ then using the fact that $f$ is one to one and onto, $$\bar B=\overline{f(f^{-1}(B))}=f\left(\overline{f^{-1}(B)}\right)$$ and hence $$f^{-1}(\bar B)=\overline{f^{-1}(B)}.$$ By (2) the function $f^{-1}$ is also continuous.
4. If $f$ is a homeomorphism then $f(\bar A)=\overline{f(A)}$ for every $A\subset X$: The idea here is similar to (3) but this time use (1) instead of (2).

As a side note, this works for all topological spaces, not just metric ones.

-
(1) I do not really understand the difference between $f(\bar A)$ and $\overline {f(A)}.$ I know it has something to do with the boundaries though. But to complete (1) I would say that $f^{-1}(V) \subset A$ and $f(f^{-1}(V)) \subset f(A) \subset \overline {f(A)}$ –  drew Nov 26 '12 at 21:51
How did you get that $B \subset f^{-1}(f(B)).$ Is it because $B \subset B.$ Also how did you arrive at $$f^{-1}(f(\overline {f^{-1}(F)})) \subset f^{-1}(F)$$ –  drew Nov 26 '12 at 22:16
Thanks for the help by the way (4) Since f is a homeomorphism then f is continuous. Since f is continuous we get from (1) $f(\bar A) \subset \overline {f(A)}$. So we need only show that $\overline {f(A)} \subset f(\bar A)$. We know $\overline {f(A)}$ is closed in Y. So $f^{-1}(\overline {f(A)})$ is closed in X. Also $f^{-1}( \overline {f(A)}) \subset \bar A$. Thus $$f(f^{-1}(\overline {f(A)})) \subset f(\bar A).$$ Thus $f(\bar A)=\overline {f(A)}$. –  drew Nov 26 '12 at 22:58
@drew: Here's a difference between $f(\bar A)$ and $\overline{f(A)}$: Take $f:\Bbb R\to\Bbb R$, $f(x)=e^x$. Then $$f(\bar{\Bbb R})=f(\Bbb R)=(0,\infty)$$ but $$\overline{f(\Bbb R)}=\overline{(0,\infty)}=[0,\infty).$$ –  nonpop Nov 27 '12 at 6:25
To complete (1) you would need to show that $V\cap f(A)\ne\emptyset$. Use the fact that $x\in\bar A$ and $f^{-1}(V)$ is an open nbhd of $x$. –  nonpop Nov 27 '12 at 6:27