[Math] Prove that the product space is a metric space.

inequalitymetric-spacesproof-verificationreal-analysis

I have the following problem:

Let $(S,d)$ and $(T,e)$ be two metric spaces. Their product space has underlying set
$$S\times T=\{(s,t)|s\in S,t\in T\}$$
and metric
$$m\big((s_1,t_1),(s_2,t_2)\big)=\sqrt{(s_1-s_2)^2+(t_1-t_2)^2}.$$
Verify that $(S\times T,m)$ is a metric space.

As for proving the triangle inequality, I made the following attempt:

\begin{align*}
m\big((s_1,t_1),(s_3,t_3)\big)&=\sqrt{(s_1-s_3)^2+(t_1-t_3)^2}\\
&=\sqrt{(s_1-s_2+s_2-s_3)^2+(t_1-t_2+t_2-t_3)^2}\\
&\leq\sqrt{(s_1-s_2+s_2-s_3)^2}+\sqrt{(t_1-t_2+t_2-t_3)^2}\\
&\leq\sqrt{(s_1-s_2)^2+(t_1-t_2)^2}+\sqrt{(s_2-s_3)^2+(t_2-t_3)^2}\\
&=m\big((s_1,t_1),(s_2,t_2)\big)+m\big((s_2,t_2),(s_3,t_3)\big)
\end{align*}

My friend has told me that I am making too large of logical jumps in the "less than or equal to" steps. Can anyone point out my error?

I know I need to use the established metrics, but I don't know how.

Best Answer

First, as mentioned in the comments, your definition of $m$ assumes that you can add, subtract, and square $s_i$ and $t_i$. These operations are not defined for a general metric space. A suitable definition would be $$m((s_1,t_1), (s_2,t_2)) = \sqrt{d(s_1,s_2)^2 + e(t_1,t_2)^2}$$ The rest of this answer assumes this definition.

Note that for any positive numbers $a$ and $b$, the inequalities $a < b$ and $a^2 < b^2$ are equivalent. Therefore, proving the triangle inequality $$m((s_1,t_1), (s_3,t_3)) \leq m((s_1,t_1), (s_2,t_2)) + m((s_2,t_2), (s_3,t_3))$$ is equivalent to proving $$m((s_1,t_1), (s_3,t_3))^2 \leq [m((s_1,t_1), (s_2,t_2)) + m((s_2,t_2), (s_3,t_3))]^2$$ or equivalently, $$d(s_1,s_3)^2 + e(t_1,t_3)^2 \leq d(s_1,s_2)^2 + e(t_1,t_2)^2 + 2\sqrt{d(s_1,s_2)^2 + e(t_1,t_2)^2}\sqrt{d(s_2,s_3)^2 + e(t_2,t_3)^2} + d(s_2,s_3)^2 + e(t_2,t_3)^2$$ Let us call this inequality 1.

Now, since $d$ and $e$ are metrics, we know that $$d(s_1,s_3)^2 \leq [d(s_1,s_2) + d(s_2,s_3)]^2 = d(s_1,s_2)^2 + 2 d(s_1,s_2)d(s_2,s_3) + d(s_2,s_3)^2$$ and $$e(t_1,t_3)^2 \leq [e(t_1,t_2) + e(t_2,t_3)]^2 = e(t_1,t_2)^2 + 2 e(t_1,t_2)e(t_2,t_3) + e(t_2,t_3)^2$$ Adding these two inequalities gives us $$d(s_1,s_3)^2 + e(t_1,t_3)^2 \leq d(s_1,s_2)^2 + 2 d(s_1,s_2)d(s_2,s_3) + d(s_2,s_3)^2 + e(t_1,t_2)^2 + 2 e(t_1,t_2)e(t_2,t_3) + e(t_2,t_3)^2$$ Comparing this with inequality 1, we see that it will suffice to prove that $$d(s_1,s_2)d(s_2,s_3) + e(t_1,t_2)e(t_2,t_3) \leq \sqrt{d(s_1,s_2)^2 + e(t_1,t_2)^2}\sqrt{d(s_2,s_3)^2 + e(t_2,t_3)^2}$$ Let us call this inequality 2.

The left hand side is the dot product between the 2-dimensional real vectors $v = (d(s_1,s_2), e(t_1,t_2))$ and $w = (d(s_2,s_3), e(t_2,t_3))$. Let's call this dot product $v \cdot w$ for short.

The right-hand side is the product of the lengths of these vectors: $$\|v\|\|w\| = \sqrt{d(s_1,s_2)^2 + e(t_1,t_2)^2}\sqrt{d(s_2,s_3)^2 + e(t_2,t_3)^2}$$

The Cauchy Schwarz inequality is precisely the tool we need: it tells us that $$|v \cdot w| \leq \|v\|\|w\|$$ This along with the fact that $v \cdot w \leq |v \cdot w|$ (a real number is no larger than its absolute value) tells us that $$v \cdot w \leq \|v\|\|w\|$$ Substituting the definitions of $v$ and $w$ gives us exactly inequality 2, which as argued above, suffices to prove inequality 1, which in turn is equivalent to the triangle inequality.

Related Question