Consider $X=\{(x,\sin(1/x)):0<x<1\}$. Then clearly $X$ is connected , as it is a continuous image of the connected set $(0,1)$.

So, $\overline X$ is also connected , as closure of connected set is connected.

Now if we notice about the set $\overline X$ then

$$\overline X=X\cup B$$

where , $B=\{(0,y):-1\le y\le 1\}$
Now , $X$ and $B$ both are connected , and $X\cap B=\emptyset$ . So, $\overline X$ is disconnected.

Where my mistake ??

• The closure doesn't contain $C$. – copper.hat May 22 '15 at 7:20
• Being not connected is more than disjoint, otherwise all sets with at least two elements would be not connected. Any open set containing $B$ must contain an open set around $(0,0)$ and hence intersect $X$. – copper.hat May 22 '15 at 7:21
• Why such a complicated example?. Here's a simpler one. $[0,2]=[0,1)\cup[1,2].$ Now, $[0,1)$ and $[1,2]$ are both connected, and $[0,1)\cap[1,2]=\emptyset.$ Now I guess you think it follows that $[0,2]$ is disconnected. Why do you think that follows? What definition or theorem are you using? – bof May 22 '15 at 9:04
• Actually my confusion arise from this problem... – Empty May 22 '15 at 16:13

In a comment you mentioned the following correct theorem:

Theorem: If $A$ and $B$ are connected and $A \cap B \neq \varnothing$ then $A \cup B$ is connected.

You might have confused this with the below converse, which is false:

False: If $A$ and $B$ are connected and $A \cap B = \varnothing$ then $A \cup B$ is not connected.

Counterexamples have been given in other answers, such as $A = (0;1]$ and $B=\{0\}$.

In order to make this statement true, you need $A$ and $B$ to be not only disjoint, but separated by disjoint open sets, i.e., that there exist open disjoint sets $X \supset A$ and $Y \supset B$.

You can also separate them by closed sets, which leads to the following correct theorem:

Theorem: If $A$ and $B$ are connected and non-empty, and $\overline{A} \cap \overline{B} = \varnothing$ then $A \cup B$ is not connected.

• When you say "contrapositive" (which would be an equivalent reformulation, which it is not) you mean "converse" (I'm not sure it really is a converse, but the term converse has no precise definition anyway). – Marc van Leeuwen May 22 '15 at 14:42
• @MarcvanLeeuwen Thanks, fixed. It can be viewed as a converse if you fix the "$A$ and $B$ are connected" part. I hope the use of the expression "the below converse" as opposed to "its converse" is good enough. – filipos May 22 '15 at 15:02
• I think your last statement can be strengthened to: "if $A$ and $B$ are connected and either $\bar{A} \cap \bar{B} = \varnothing$ or $\bar{A} \cap \bar{B} \not\subseteq A \cup B$, then $A \cup B$ is not connected." – A.P. May 23 '15 at 11:14
• @A.P. Not really. Consider $B = A \neq \overline{A}$. – filipos May 23 '15 at 13:32
• @A.P. Maybe you wanted "If $\overline{A} \cap \overline{B} \cap (A \cup B) = \varnothing$, then $A \cup B$ is not connected", but then you only need $A$ and $B$ to be nonempty, and you can replace $A \cup B$ by an arbitrary set $X$ intersecting both $\overline{A}$ and $\overline{B}$. This gives you the most general statement that can be made about connected sets =). – filipos May 23 '15 at 13:35

The set $B$ is NOT open, so this is not a partition of $\overline X$ in open sets.

• $A$ and $B$ both are connected..What is necessary condition to $A\cup B$ be connected? – Empty May 22 '15 at 8:11
• @S.Panja-1729: It is certainly necessary that not both $A$ and $B$ are open in $A\cup B$. If both are open, then $A\cup B$ is disconnected. But this is independent of $A$ or $B$ being connected. – Stefan Hamcke May 22 '15 at 13:15
• @ Stefan Hamcke ): If $A$ and $B$ are two non-empty connected open sets (OR closed sets ) then $A\cup B$ is open if and only if $A\cap B \not =\emptyset$. Is it??? I think it is true... – Empty May 22 '15 at 16:19
• @S.Panja-1729 I think you mean "$A \cup B$ is connected"... the union of two open sets is always open. – A.P. May 23 '15 at 11:03
• @S.Panja-1729 Anyway, if both $A$ and $B$ are either open or closed, then it is true that $A \cup B$ is connected iff $A \cap B \neq \varnothing$. This can fail, though, if for example $A$ is open and $B$ is closed, which is the case for $A = (0,1)$, $B = [1,2]$. – A.P. May 23 '15 at 11:11

I think that in your reasoning there is two incorrectness:

1. We have $\overline{X}=X\cup B\cup\{(1,\sin(1))\}$.
2. The implication :

$X$ and $B$ are connected and $X\cap B=\emptyset$ $\Rightarrow$ $X\cup B$ is not connected

is false. For a counterexample one can see that $\{0\}$ and $(0,1]$ are connected and disjoint, and $\{0\}\cup(0,1]=[0,1]$ is also connected.

• So, in the theorem " If $A$ and $B$ are connected and $A\cap B\not =\emptyset$ then $A\cup B$ is connected " is the condition of non-empty sufficient ? – Empty May 22 '15 at 7:57
• Can you be more clear? – Driss Alami May 22 '15 at 7:59
• Theorem: " If $A$ and $B$ are connected and $A\cap B\not =\emptyset$ then $A\cup B$ is connected – Empty May 22 '15 at 8:02
• In the above theorem is the condition $A\cap B\not =\emptyset$ sufficient ?? – Empty May 22 '15 at 8:03
• The Theorem is ok, I don't understand what do you mean by: ''is the condition of non-empty sufficient ?'' – Driss Alami May 22 '15 at 8:05

I think that there is an error for $\overline{X}$. You have $\overline{X} = X \cup B$. "The curve is not oscillating on the right side"