# Metric space question

1. Dec 4, 2011

### Maybe_Memorie

1. The problem statement, all variables and given/known data

Consider a metric space (X,d) with subsets A and B of X, where A and B have non-zero intersection. Show that diam(A$\bigcup$B) $\leq$ diam(A) + diam(B)

2. Relevant equations

3. The attempt at a solution

A hint would be very much appreciated.

Let x$\in$A, y$\in$B, z$\in$A$\bigcup$B

diam(A$\bigcup$B) = sup[d(x,y)] for every x,y.
So d(x,y) $\leq$ diam(A$\bigcup$B)

Either z$\in$A, or z$\in$B, or z in both.

Consider firstly z$\in$A.
d(x,z) $\leq$ diam(A)

If z$\in$B,
d(z,y) $\leq$ diam(B)

Therefore, d(x,z) + d(z,y) $\leq$ diam(A) + diam(B)

But d(x,y) $\leq$ d(x,z) + d(z,y), hence
d(x,y) $\leq$ diam(A) + diam(B)

As far as I've gotten...

2. Dec 4, 2011

### hunt_mat

Examine a point in $z\in A\cap B$ and then examine the distance from $x\in A$ and $b\in B$ and examine the distance from x to y.and apply the definition of diameter.

3. Dec 4, 2011

### Maybe_Memorie

Wait, I have these two results

d(x,y) ≤ diam(A⋃B)

d(x,y) ≤ diam(A) + diam(B)

The latter holds for all x,y, and the maximum value of d(x,y) is diam(A⋃B), which still has to be less than or equal to diam(A) + diam(B).

So, diam(A⋃B) ≤ diam(A) + diam(B)

Is my reasoning correct?

4. Dec 4, 2011

I think so.

5. Dec 4, 2011

### Dick

That doesn't sound right to me. Where did you get d(x,y)<=diam(A)+diam(B)? Isn't that what you are trying to prove? And where did you use that the intersection of A and B is nonempty? The result is false if that isn't true.

6. Dec 4, 2011

### Maybe_Memorie

I showed it in my first post, using the triangle inequality. And no, I'm trying to prove that
diam(A$\bigcup$B) $\leq$ diam(A) + diam(B)

As for using the fact that the intersection is non-empty, if it was empty then the inequality
d(x,y) $\leq$ diam(A) + diam(B) is not necessarily true, but it is non-empty, so it is correct.

7. Dec 4, 2011

### Dick

Ah, indeed you did. Sorry, I didn't read the initial post thoroughly enough.

8. Dec 4, 2011

### Maybe_Memorie

No problem, so is my proof correct?

9. Dec 4, 2011

### hunt_mat

Suppose $z\in A\cap B$, $x\in A$ and $y\in B$, the from the triangle inequality:
$$d(x,y)\leqslant d(x,z)+d(z,y)$$
we also know that $d(x,z)\leqslant\textrm{diam}(A)$ and $d(z,y)\leqslant\textrm{diam}(B)$, so we just put these together.

10. Dec 4, 2011

### Dick

I think you need to be a little more precise. diam(AUB) is the LEAST UPPER BOUND for d(x,y). diam(A)+diam(B) is another upper bound. Just saying they are both upper bounds won't do it. I think that's what you were trying to say with "the maximum value of d(x,y) is diam(A⋃B)" but that's not quite right. There may be no x and y with d(x,y)=diam(AUB).

11. Dec 4, 2011

### I like Serena

I'm afraid you did not apply the triangle property correctly in your opening post.

If you assume that z is in A, then
d(x,z) ≤ diam(A),
but you can not assume that d(z,y) ≤ diam(B).

So you cannot conclude that d(x,z)+d(z,y) ≤ diam(A)+diam(B)

To get your triangle inequality straight you need to use what Dick suggested.

12. Dec 4, 2011

### Dick

Ach, I'm starting mix up who wrote what. But hunt_mat gave the correct argument. I think maybe Maybe_Memory meant to as well but muddled up the cases a bit and didn't mention the triangle inequality.

Last edited: Dec 4, 2011
13. Dec 4, 2011

### Maybe_Memorie

I'm assuming z is in A, and getting d(x,z) ≤ diam(A)
Then considering the case where z is in B, and getting d(z,y) ≤ diam(B).

14. Dec 4, 2011

### hunt_mat

You're considering two different possibilities and you need both possibilities to be true at the same time, you can only do that if z is in the intersection of A and B.

15. Dec 4, 2011

### I like Serena

You cannot combine 2 choices for z in 1 equation.

16. Dec 4, 2011

### Maybe_Memorie

Aaah! Right, I see the problem! So as hunt_mat said

I understand this now.

As for the issue with combining my results to get the desired expression;

d(x,y) $\leq$ diam(A$\bigcup$B)

d(x,y) $\leq$ diam(A) + diam(B)

diam(A$\bigcup$B) is the least upper bound for d(x,y) and is contained in d(x,y) so d(x,y) can take the value diam(A$\bigcup$B)
so diam(A$\bigcup$B) $\leq$ diam(A) + diam(B)

17. Dec 4, 2011

### I like Serena

You have the right idea, but I'm afraid it's not a proper proof.

First off, you need to split the possibilities for x and y into 4 cases, which can be reduced to 2 cases: x and y in the same set, or x and y in different sets.

Furthermore, there is no guarantee that d(x,y) can take the value diam(A$\cup$B).
And then take the sup on both sides, yielding the diameters.

18. Dec 5, 2011

### Maybe_Memorie

Okay, if I take d(x,y) $\leq$ d(x,z) + d(z,y), take the sup on both sides,
sup [d(x,y)] $\leq$ sup [d(x,z) + d(z,y)]

Is it correct to say sup [d(x,z) + d(z,y)] $\leq$ sup [d(x,z)] + sup[d(z,y)]
hence sup [d(x,y)] $\leq$ sup [d(x,z)] + sup[d(z,y)] which is what i need?

19. Dec 5, 2011

### I like Serena

It's still slightly more subtle.
What you say is correct btw, but it is not sufficient.

First we have to assume that sup[d(x,y)]=diam(AuB) for x in A and y in B.
(You have to prove the other cases separately.)
Then you can say what you said with an arbitrary z in AnB.
Then you can conclude that sup[d(x,z)] ≤ diam(A) and sup[d(z,y)] ≤ diam(B).
And from this follows your inequality (for this case).