Sign up ×
Mathematics Stack Exchange is a question and answer site for people studying math at any level and professionals in related fields. It's 100% free, no registration required.

So I know that $\mathbb{R}$ is both open and closed. But given a set, $X\subset \mathbb{R}$, $X\ne \emptyset $ that is both open and closed, how does one show that $X=\mathbb{R}$?

Here is my attempt: Using the definitions I was given, $X$ open implies that for every $x\in X$ there is a $\delta \gt 0$, $(x-\delta,~ x+\delta)\subset X$. Also, since $X$ is closed , $B=\mathbb{R}$\ $X$ is open.

However, I don't know how to proceed.
NB: This is not a homework problem.

share|cite|improve this question

marked as duplicate by Najib Idrissi, John Ma, Christopher A. Wong, kjetil b halvorsen, Jonas Meyer real-analysis Apr 26 at 2:28

This question has been asked before and already has an answer. If those answers do not fully address your question, please ask a new question.

$X$ can be $\emptyset$ as well. – F M Oct 6 '11 at 18:45
Sorry I forgot to mention that $X$ is non-empty. – Kuku Oct 6 '11 at 18:49
Try to prove that $(0,1)$ is connected, then, since it is homeomorphic to $\mathbb{R}$, you have your conclusion. – Andy Oct 6 '11 at 18:57
The definition of open that you stated above is not correct. That should be: $X$ open if for every $x \in X$, there is a $\delta > 0$ such that $(x - \delta, x + \delta) \subset X$. – Shaun Ault Oct 6 '11 at 19:00
Path-connected implies connected because $[0,1]$ is connected. I doubt proving $[0,1]$ is connected is much easier than just directly proving that $\mathbb{R}$ is connected. – Chris Eagle Jan 10 '12 at 17:46

4 Answers 4

up vote 15 down vote accepted

Suppose that $X$ and $\mathbb{R}\setminus X$ are both open. Pick a point $a\in X$ and a point $b\in \mathbb{R}\setminus X$. There’s no harm in assuming that $a<b$. Let $A = \{x\in [a,b]:[a,x]\subseteq X\}$. $A$ is bounded, so it has a least upper bound $u$. Clearly $u\le b$.

Now let $\epsilon > 0$, and consider the interval $J=(u-\epsilon, u+\epsilon)$. Since $u$ is the least upper bound of $A$, $A \cap (u-\epsilon,u]\ne\varnothing$, and therefore certainly $J\cap A\ne \varnothing$. This shows that $u$ can’t be in $\mathbb{R}\setminus X$, since no open nbhd of $u$ is a subset of $\mathbb{R}\setminus X$, Thus, $u\in A$, and therefore $u<b$ (since $b\notin A$). Let $v=\min\{u+\epsilon,b\}$. Clearly $v \notin A$, so there is some $x\in [a,v)\setminus X$. since $[a,u]\subseteq X$, we must have $x\in [u,v)\subseteq [u,u+\epsilon)$. Thus, $J\setminus X\ne \varnothing$, and $J\nsubseteq X$. Thus, $u$ can’t be in $X$, either. Since $u$ has to be somewhere, this is a contradiction, showing that $X$ and $\mathbb{R}\setminus X$ can’t both be open.

share|cite|improve this answer

Theorem. A compact interval $[a,b]$ is connected.

Suppose $[a,b]$ were disconnected. Then there would exist a continuous surjective function $f$ from $[a,b]$ onto the discrete space $\{0,1\}$. Said discrete space can also be considered as a subset of $\mathbb R$ with the subspace topology, so $f$ would be continuous as a function from $[a,b]$ to $\mathbb R$ as well. But by the intermediate value theorem, it would attain every value in the interval $[0,1]$ contradicting that it's a function onto $\{0,1\}$. Hence such a function cannot exist, and $[a,b]$ must be connected. $\square$

Theorem. If a space $X$ contains at least two points and any pair of distinct points of $X$ are contained in a connected subset, then $X$ is connected.

Proof. Suppose we have disjoint nonempty open sets $A,B \subset X$ with $A \cup B = X$, i.e. a disconnection of $X$. By the assumption there are $a \in A$ and $b \in B$ contained in a connected $S \subseteq X$. $S$ has the subspace topology, so $A \cap S$ and $B \cap S$ would then be disjoint nonempty open subsets of $S$ with $(A \cap S) \cup (B \cap S) = (A \cup B) \cap S = X \cap S = S$, yielding a disconnection of $S$, which is our desired contradiction. $\square$

Corollary. $\mathbb{R}$ is connected.

share|cite|improve this answer

Hint: $X$ is clopen iff $\partial X = \partial X^c = \emptyset$

share|cite|improve this answer
Im not familiar with what $\partial X$ means... – Kuku Oct 6 '11 at 18:52
@Kuku: it's the boundary of $X$, $\partial X = \bar{X} \setminus X^{\circ}$ – Andy Oct 6 '11 at 18:55

You can prove, as a previous exercise, that $x\in \partial(X)$ (boundary of $X$) if and only if there exist sequences $(x_n)$ in $X$ and $(y_n)$ in $\mathbb{R}\setminus X$ such that $x_n\to x$ and $y_n\to x$. After demonstrating this you can argue as follows:

Suppose that $X$ and $\mathbb{R}\setminus X$ are both closed. Take $x\in\partial(X)$. There exist $(x_n)$ in $X$ with $x_n\to x$. Since $X$ is closed, $x\in X$. In the same way you can prove that $x\in \mathbb{R}\setminus X$, and this is a contradiction. Therefore the boundary of $X$ is empty.

Now, since $X$ is open there exist a countable collection of open disjoint intervals $I_k=(a_k,b_k)$ such that $$X=\bigcup_{k\in\mathbb{N}} I_k.$$ Since $X\neq \emptyset$, at least an interval $I_r=(a_r,b_r)$ is not empty and is contained in $X$. Note that if $a_r=-\infty$ and $b_r=\infty$, then $\mathbb{R}\subseteq X$ and there is nothing to prove. Therefore we can assume that either $a_r$ or $b_r$ is finite, is a number. W. l. o. g. assume that $a_r$ is a number We have $a_r\not\in X$. Then since $\mathbb{R}\setminus X$ is also open, exist $\delta>0$ such that $(a_r-\delta,a_r+\delta)\subset \mathbb{R}\setminus X$. But since $a_r$ is in the boundary of $I_r$, $(a_r-\delta,a_r+\delta)\cap I_r\neq \emptyset$ and therefore $(a_r-\delta,a_r+\delta)\cap X\neq\emptyset$. Note that from here is possible to show that $a_r\in\partial(X)$, and this is an absurd.

Therefore such $X$ cannot be.

share|cite|improve this answer
Thanks......... – Kuku Oct 11 '11 at 11:12
you are welcome @Kuku :) – leo Oct 11 '11 at 21:21

Not the answer you're looking for? Browse other questions tagged or ask your own question.