Union of connected subsets is connected if intersection is nonempty

HINT: You’re actually about halfway there, though you omitted an important qualification of $A$ and $B$: if $\bigcup\mathscr{F}$ is not connected, then it can be partitioned into two disjoint, non-empty, relatively open subsets $A$ and $B$. Now fix $x\in\bigcap\mathscr{F}$, and without loss of generality assume that $x\in A$. $B\ne\varnothing$, so pick any $y\in B$. Then there is some $F\in\mathscr{F}$ such that $y\in F$, and of course $x\in F$. Thus, $x\in A\cap F$, and $y\in B\cap F$, so $A\cap F\ne\varnothing\ne B\cap F$. Why is this a contradiction?


Use that $X$ is connected if and only if the only continuous functions $f:X\to\{0,1\}$ are constant, where $\{0,1\}$ is endowed with the discrete topology.

Now, you know each $F$ in $\mathscr F$ is connected. Consider $f:\bigcup \mathscr F\to\{0,1\}$, $f$ continuous.

Take $\alpha \in\bigcap\mathscr F$. Look at $f(\alpha)$, and at $f\mid_{F}:\bigcup \mathscr F\to\{0,1\}$ for any $F\in\mathscr F$.


Since you mention metric spaces, I am not sure if you know about the first thing I mention, so let's prove it:

THM Let $(X,\mathscr T)$ be a metric (or more generally, a topological) space. Then $X$ is connected if and only if whenever $f:X\to\{0,1\}$ is continuous, it is constant. The space $\{0,1\}$ is endowed with the discrete metric (topology), that is, the open sets are $\varnothing,\{0\},\{1\},\{0,1\}$.

P First, suppose $X$ is disconnected, say by $A,B$, so $A\cup B=X$ and $A\cap B=\varnothing$, $A,B$ open. Define $f:X\to\{0,1\}$ by $$f(x)=\begin{cases}1& \; ; x\in A\\0&\; ; x\in B\end{cases}$$

Then $f$ is continuous because $f^{-1}(G)$ is open for any open $G$ in $\{0,1\}$ (this is simply a case by case verification), yet it is not constant. Now suppose $f:X\to\{0,1\}$ is continuous but not constant. Set $A=\{x:f(x)=1\}=f^{-1}(\{1\})$ and $B=\{x:f(x)=0\}=f^{-1}(\{0\})$. By hypothesis, $A,B\neq \varnothing$. Morover, both are open, since they are the preimage of open sets under a continuous map, and $A\cup B=X$ and $A\cap B=\varnothing$. Thus $X$ is disconnected. $\blacktriangle$


I like "clopen" sets... it is a set that is at the same time closed and open. A topological space $X$ is not connected if, and only if, for any point $a \in X$, you have a "non-trivial" clopen set $C$ containing $a$. That is, a clopen set such that $\emptyset \neq C \subsetneq X$.

Take $a \in \bigcap \mathscr{F}$. Then, take a clopen set $C \subset \bigcup \mathscr{F}$ containing $a$. In the relative topology, for any $X \in \mathscr{F}$, $C \cap X$ is a clopen set. Since $X$ is connected, $C \cap X = X$. That is, $X \subset C$ for every $X \in \mathscr{F}$. Therefore, $\bigcup \mathscr{F} \subset C$.

Therefore, $\bigcup \mathscr{F}$ has no "non-trivial" clopen set, and so, it is connected.


The proof admits some variants. For example, if you take any non-empty clopen set $C'$, it will intersect some $X \in \mathscr{F}$. From connectedness, we have that $X \subset C'$. In particular, $a \in C'$.