Show that the closure of a connected set is also connected

connectednessgeneral-topologyproof-verificationreal-analysis

I'm doing exercise II.4.5 in textbook Analysis I by Amann.

Could you please verify if my attempt contains logical mistakes/gaps! Thank you so much!

enter image description here

My attempt:

Lemma: $f:X \to Y$ is continuous iff $f[\overline{A}] \subseteq \overline{f[A]}$ for all $A \subseteq X$.

Assume that $f : \overline{A} \rightarrow\{0,1\}$ is continuous, then the restriction $f \restriction A : A \rightarrow\{0,1\}$ is continuous because $A \subseteq \overline{A}$. Because $A$ is connected, then $f \restriction A$ is not surjective. WLOG, we assume $f[A] = \{0\}$. Since $\{0\}$ is both closed and open in $\{0,1\}$, $\overline{f[A]} = \overline{\{0\}} = \{0\}$. By Lemma, $f[\overline{A}] \subseteq \overline{f[A]}= \{0\}$, so $f$ is not surjective. Hence $\overline{A}$ is connected.

Best Answer

Why not do it from scratch? Towards a contradiction, suppose $\overline A=C\cup D$ for some non-empty sets $C,D$ open in $\overline A$. Since $A$ is connected, we may assume without loss of generality, that $A\subseteq C$. Then, $\overline A\subseteq \overline C.$ But $\overline C\cap D=\emptyset$ (why?) and so $\overline A\cap D=\emptyset$. Thus, we have shown that $D$ is empty, which is a contradiction.