If $Y$ is connected, why is $A\cup Y$ connected in this case?

If $(X,\mathcal{T})$ is a connected space, and $Y$ a connected subset, and $X\setminus Y=A\cup B$ for separated sets $A$ and $B$, then why is $A\cup Y$ connected as well?

Thank you kindly.

-
Suppose you have a separation $Z\cup W = A\cup Y$, $Z\cap W = \emptyset$. Can $A\cap Y$ or $B\cap Y$ be nontrivial? What does this imply about $A$, and then $X$? –  Neal Dec 12 '11 at 11:04

Suppose that $Y\cup A$ is not connected. Then there are open sets $U$ and $V$ in $X$ such that $Y\cup A\subseteq U\cup V$, and $U\cap(Y\cup A)$ and $V\cap(Y\cup A)$ are disjoint and non-empty. This implies that $U\cap V\cap Y=\varnothing$ with $Y\subseteq U\cup V$. Since $Y$ is connected, this is possible only if $Y$ is a subset of one of $U$ and $V$, say $Y\subseteq U$. Clearly we must then have $V\cap A\ne\varnothing$.

Now we use the fact that $A$ and $B$ are separated. This implies that $A\cap\operatorname{cl}B=\varnothing$. Thus, if we set $W=V\setminus\operatorname{cl}B$, we haven’t removed any points of $A$ from $V$, and therefore $W\cap A=V\cap A$. $U$ contains $Y$, and $W$ contains as much of $A$ as $V$ did, so $Y\cup A\subseteq U\cup W$, and $W\cap A\ne\varnothing$. Moreover, $$U\cap W\cap(Y\cup A)\subseteq U\cap V\cap(Y\cup A)=\varnothing\tag{1}$$ and $$W\cap B=\varnothing\tag{2}\;.$$

$(1)$ implies that $U\cap W\cap Y=\varnothing$ and $U\cap W\cap A=\varnothing$, and $(2)$ implies that $U\cap W\cap B=\varnothing$, so, putting the three pieces together, we have \begin{align*}U\cap W&=U\cap W\cap X\\ &=U\cap W\cap(Y\cup A\cup B)\\ &=(U\cap W\cap Y)\cup(U\cap W\cap A)\cup(U\cap W\cap B)\\ &=\varnothing\;. \end{align*}

Finally, let $G=U\cup B$; clearly $G\cap W=\varnothing$, $G\cup W=X$, and $G$ and $W$ are non-empty. But $W$ is open, and $X$ is connected, so we’ll have our contradiction if we can show that $G$ is open.

Suppose that $x\in G$. Then either $x\in U$, or $x\in B$. If $x\in U$, then $U$ is an open nbhd of $x$ contained in $G$. If $x\in B$, then $x\in B\subseteq X\setminus\operatorname{cl}A\subseteq X\setminus A=Y\cup B\subseteq U\cup B=G$, and $X\setminus\operatorname{cl}A$ is an open nbhd of $x$ contained in $G$. Thus, every point of $G$ is in the interior of $G$, and $G$ is indeed open. We have our contradiction, so in fact $Y\cup A$ must be connected.

-
Thank you for such a detailed answer. –  Yoshi Dec 12 '11 at 19:39

I like the following definition, which is convenient and is part of the aim of giving general topology more emphasis on the properties of continuous functions rather than on the internal structure of spaces, i.e. emphasis on the category of topological spaces and continuous maps.

Let $\mathbf 2= \{0,1\}$ with the discrete topology. Then a space $X$ is connected if and only if any continuous function $f: X \to \mathbf 2$ is constant. We also need the following, which is about gluing continuous functions.

Proposition: Let $X$ be a space with subspaces $Y,A,B$ such that $X \backslash Y= A \sqcup B$ (disjoint union). Let $g: X \to Z$ be a function such that $g$ is continous when restricted to each of $Y \cup A, Y \cup B$. Then $g$ is continuous.

Now for the case in point. Let $f: A \cup Y \to \mathbf 2$ be continuous. Since $Y$ is connected, $f$ is constant on $Y$ with value $0$, say. Extend $f$ to a function $g$ on $X$ by taking the value $0$ on $Y \cup B$. But $X \backslash Y= A \sqcup B$, by assumption, and so $g$ is continuous. Since $X$ is connected, it follows that $g$ is constant. Hence $f$ is constant.

(This is the hinted solution to Exercise 3 in Section 3.3 of my book "Topology and Groupoids".)

-

Here is a clean, simple argument:

Assume for a contradiction that we have nonempty mut. separated sets M,N composing $A\cup Y$. (That is, $A\cup Y$ is not connected). Then one of these sets must cover Y.

Here's why: If one is a proper subset of Y (Assume it is M), then M and Y\M would be a mutually separated partition of Y into two nonempty sets. (Because Y\M would be a subset of N (Y\M = $N\cap Y$ in fact) and M,N are separated). This cannot happen since Y is connected.

So assume M covers Y. Now look at the partition of X into nonempty sets $[M\cup B]$ and $N$. N is a subset of A since M covers Y. Thus B,N are separated (by hypothesis of A and B sep.). We already assumed M,N to be separated, so in total we have $[M\cup B]$ and $N$ are mutually separated. This contradicts that X is connected.

-
Why is N open or closed in X? –  Prateek Dec 13 '11 at 11:10
You do not need for anything to be open or closed in this proof. Here I am using a different, although equivalent, definition of connectedness than that of Brian above. Mutually separated means neither M nor N contains a pt. or lim pt. of the other. Then a set is connected if it is not the union of two nonempty mutually separated sets. All I really used was, given two mut. sep sets M,N (A,B likewise), subsets of one are still mutually separated from the other...which is pretty trivial. –  Lusinghiero Dec 13 '11 at 18:30
As I see it, $A$, $B$ and $Y$ are disjoint, and their union make up the connected space $X$. The question is then, is the complement of $B$ in $X$ connected? I am going to assume they are all non-empty.
Two given points in $Y$ are connected by definition of $Y$. It then remains to show that a point $a \in A$ and a point $y \in Y$ are connected, as two points in $A$ then can be connected via a point in $Y$.
As $X$ is connected, $A$, $B$ and $Y$ must have non-empty boundaries. As $A$ and $B$ are disconnected, no points on the boundary of $A$ can be on the boundary of $B$. This means that any boundary point of $A$ has an open neighborhood containing only points from $A$ and $Y$. As $a$ is connected to some boundary point of $A$, and thus some point of $Y$, it is connected to $y$ by the point above, as connectedness between points is transitive.
This concludes the proof that the complement of $B$ in $X$ is connected.
"As $A$ and $B$ are disconnected, no points on the boundary of $A$ can be on the boundary of $B$." As far as I understand, $A$ and $B$ are only a separation of $X \setminus Y$. The boundary of $A$ in $X$ and the boundary of $B$ in $X$ might intersect : eg, take $X$ to be a space which looks like the symbol $\theta$, and let $Y$ be the closed horizontal line in the centre. Then $A$ and $B$ are the open upper arc and open lower arc. Another thing: it's a bit strange to talk of points $a \in A$ and $y \in Y$ in the context of connectedness. What role do they play here? –  Prateek Dec 12 '11 at 12:06