Mathematics Stack Exchange is a question and answer site for people studying math at any level and professionals in related fields. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

enter image description here


This was posted a year ago, I feel like presenting an alternative solution(s).


(i) Since $A \cap B = \phi$, we have $a \notin B$. Thus for each $b \in B$, we have $\| a -b\| > 0$. Consider the set $C = \{\|a-b\| : a \in A, b \in B\}$. Obvious $C$ is bounded below by $0$. Therefore by the glb property we have $0 <\inf C $

(ii) The one uses the fact that $B$ is closed and using the definition of $\inf$. Applying the Squeeze Theorem yields $a \in B$, but we have a contradiction.

share|cite|improve this question
For a.), think about a sequence of points $b_{n}$ in $B$ such that $d(a,b_{n})<\frac{1}{n}$. For b.), extrapolate a.) for all the points in $A$ and use a nice property of compact sets. For c.) think about the graphs of functions with assymptotes. – Shawn Henry Oct 31 '12 at 19:38
for c, think about the xy=1 and the axis; – John0417 Oct 31 '12 at 19:40
Warning! Even though this function is called $d$, it is not a metric (distance function). This may be the source of your confusion about part (c). – Brad Oct 31 '12 at 19:43
note if one of the set is compact, then notice function d is a continuous function – John0417 Oct 31 '12 at 19:43
up vote 3 down vote accepted

You’re getting off on the wrong foot right from the start: it is not true that $d(A,B)=0$ iff $A=B$. For example, let $A=\{0\}$ and $B=[0,1]$ in $\Bbb R$; then

$$\begin{align*} d(A,B)&=\inf\{|a-b|:a\in A\text{ and }b\in B\}\\ &=\inf\{|b|:b\in[0,1]\}\\ &=0\;, \end{align*}$$

but it’s certainly not true that $\{a\}=[0,1]$.

Similarly, for (a) you should have

$$d(\{a\},B)=\inf\{\|a-b\|:b\in B\}\;.$$ This is $0$ iff for each $\epsilon>0$ there is a $b_\epsilon\in B$ such that $\|a-b_\epsilon\|<\epsilon$. Thus, if $d(\{a\},B)=0$, there is a sequence in $B$ converging to $a$ (why?), and since $B$ is closed, this implies that $a\in B$. Since we were told that $\{a\}\cap B=\varnothing$, this is impossible, and $d(\{a\},B)\ne 0$. Since the distance function takes only non-negative values, this means that $d(\{a\},B)>0$.

You can use (a) to help you prove (b). You know from (a) that $d(\{a\},B)>0$ for each $a\in A$. Now suppose that $d(A,B)=0$. Show that for each $\epsilon>0$ there must be some $a_\epsilon\in A$ such that $d(\{a\},B)<\epsilon$. Conclude that there is a sequence $\sigma=\langle a_k:k\in\Bbb Z^+\rangle$ in $A$ such that $d(\{a_k\},B)<\frac1k$ for each $k\in\Bbb Z^+$. $A$ is compact, so $\sigma$ has a convergent subsequence. Show that the limit of this subsequence is in $A\cap B$, thereby getting a contradiction and showing that $d(A,B)$ must be positive.

From (b) you know that the two sets in (c) cannot be compact. They are closed, however, so they cannot be bounded. Look for two unbounded closed sets that get closer and closer together but never meet.

Added in response to edit of question: You write:

Assume $d(A,B)=0$, then $\forall\epsilon>0,\exists a_\epsilon\in A$ such that $|a−a_\epsilon|<\epsilon$.

This makes no sense, I’m afraid. First, $a$ comes out of nowhere. What is it? Where did it come from? What properties does it have? Secondly, you’ve asserted the existence of the points $a_\epsilon$, but you’ve given no justification for the assertion. Start over, this time paying a bit more attention to the suggestion.

Suppose that $d(A,B)=0$. By definition

$$\begin{align*} d(A,B)&=\inf\{|a-b|:a\in A\text{ and }b\in B\}\\ &\overset{*}=\inf_{a\in A}\inf\{|a-b|:b\in B\}\\ &=\inf_{a\in A}d(\{a\},B)\;. \end{align*}$$

This means that for each $\epsilon>0$ there is an $a_\epsilon\in A$ such that $d(\{a\},B)<\epsilon$. (Why, and why is the starred step above justified?) Now consider the sequence $\langle a_{1/k}:k\in\Bbb Z^+\rangle$; $A$ is compact, so this sequence has a convergent subsequence $\langle a_{1/n_k}:k\in\Bbb Z^+\rangle$. Let $a$ be the limit of this subsequence; then $a\in A$ (why?). On the other hand, for each $k\in\Bbb Z^+$ we know that $d(\{a_{1/n_k}\},B)<\frac1{n_k}$, so there is a point $b_k\in B$ such that $d(a_{1/n_k},b_k)<\frac1{n_k}$. Prove that the sequence $\langle b_k:k\in\Bbb Z^+\rangle$ converges to $a$, and use the fact that $B$ is closed to conclude that $a\in B$. This is a contradiction; what hypothesis does it contradict?

share|cite|improve this answer
@jak: Because the hypotheses force it to be there. Have you tried proving that it is? If so, where do you get stuck? – Brian M. Scott Nov 1 '12 at 1:49
@jak: No. At this point in the argument we’re trying to prove that if $d(A,B)=0$, then there is some point in $A\cap B$. – Brian M. Scott Nov 1 '12 at 2:34
@jak: No, I did not. In (a) we were given a point $a$ with certain properties; in (b) we are only given the compact set $A$, not any particular point in it. You ‘defined’ your points $a_\epsilon$ in terms of some mysterious point $a$ about which we know nothing. To turn around and say that we know what it is because it’s the limit of the $a_\epsilon$ is circular. (Moreover, the $a_\epsilon$ aren’t a sequence, since there’s one for every positive real number.) – Brian M. Scott Nov 1 '12 at 13:16
@sidht: It would be much better to leave the original post as it is and to post your solution as a new answer to your own question. Modifying a question in a way that hides the relevance of upvoted answers is frowned upon. // Your claim in the new solution that $0<\inf C$ is insufficiently justified: after all, the set of positive reals is bounded below by $0$, but its infimum is not greater than $0$. – Brian M. Scott Jun 27 '13 at 6:51
EDit, never mind I forget it was $\geq$, not $>$. Thank you (and I am sorry) – Hawk Jun 27 '13 at 6:57

Here are some hints:

a) Your statement that $d(A,B) = 0$ iff $A = B$ is false for sets $A$ and $B$; this is true for points. For instance, $A = \{1,3\}$ and $B = \{1,4\}$ also satisfy $d(A,B) = 0$ but the sets $A,B$ are not equal.

However, for $A = \{a\}$ and $B$ closed you know that $a\not\in B$ and hence there is an open ball around $a$ not intersecting $B$; you can use the triangle inequality here to show (a).

b) Since $A$ is compact, every point in $A$ has an open neighbourhood disjoint from $B$. How can you use the compactness property and part (a) now?

c) From (b) you know that neither set can be compact. Try playing with sequences...

share|cite|improve this answer

a. Suppose that $d(A,B)=0$. Then $\forall n \in \mathbb{N} $ exist $b_n \in B$ s.t. $d(a,b_n)<\frac{1}{n}$. The sequence $(b_n)$ has limit $a$. Since B is closed $a \in B$. Contradiction. So $d(A,B)>0$.

b . It is an easy exercise to show that $d(A,B)=\inf{\{d(a,B):a \in A\}}$. So suppose that $d(A,B)=0$. Then $\forall n \in \mathbb{N} $ exist $a_n \in A$ s.t. $d(a_n,B)<\frac{1}{n}$. Since A is compact the sequence $a_n$ has a convergence subsequence $a_{k_n}$. Then $a_{k_n} \to a$ for some $a \in A$. Then $d(a,B)=0$. Contradiction from part a.

c. Take $A=\{(x,0):x \in \mathbb{R}\}$ and $B$ the graph of the function $\frac{1}{x}$.

share|cite|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

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