Diameter of union is at most the sum of diameters, when the sets intersect Prove that $d (A \cup B) \leq d(A)+ d(B)$, given that   $ A \cap B \neq \varnothing$.  


Here $d$ stands for the diameter of the set. Please note that my knowledge is limited to metric spaces only, with no knowledge of topology at all.

My attempt:

I'm trying to use the relation that $A \subset B \Rightarrow d(A) \leq d(B)$

I prove this result in the following way: 

If $a,b \in A$, then  $a,b \in B$, so 
 { $d(a,b) : a,b \in A$ }$ \subset$ {$d(a,b) : a,b \in B$} 

So, sup { $d(a,b) : a,b \in A$ }$ \subset$ sup {$d(a,b) : a,b \in B$} 

Is this part correct?

Now, using this result:

$ A \subset A \cup B$ and $ B \subset A \cup B$ 

So $d(A) \leq d(A \cup B)$ and $d(B) \leq d(A \cup B)$ 

Adding, $d(A)+ d(B) \leq 2d(A \cup B)$

This is where I'm stuck.
Consider two points $x,y$ in $A\cup B$. If they are both in $A$, then $d(x,y)\leq d(A)$. If they are both in $B$, then $d(x,y)\leq d(B)$. Otherwise, suppose $x\in A$ and $y\in B$. Let $z$ be a point in $A\cap B$. Then by the triangle inequality we have
$$d(x,y)\leq d(x,z)+d(z,y)\leq d(A)+d(B)$$
Taking sups we obtain that $d(A\cup B)\leq d(A)+d(B)$.
You need $A\cap B\ne \varnothing$. What happens if $A$ and $B$ are just two different points? 

The more general inequality (any $A$ and $B$) should have $d(A,B)$ in it. See here for detail. In this case, $A\cap B\ne \varnothing$ implies $d(A,B)=0$.