# Metric for sequences proof

Suppose $$X = \{\{x_n\}_{n \in \mathbb{N}} : x_n \in \mathbb{R}$$ $$\forall n\geq 1\}$$. Prove that $$d: X \times X \rightarrow \mathbb{R}$$ such that $$d(\{x_n\}_{n \in \mathbb{N}}, \{y_n\}_{n \in \mathbb{N}}) = \sum_{n = 1}^{\infty} 2^{-n}\frac{|x_n - y_n|}{1 + |x_n - y_n|}$$ is a metric on $$X$$.

My attempt:

I was given the hint that I should check each of the following: (1) a function $$f(x) = \frac{x}{x+1}$$ is montone increasing, (2) the triangle inequality applies to $$\frac{|x_n - y_n|}{(1 + |x_n - y_n|)}$$ and (3) the metric itself satisfies the inequality.

(1) $$f$$ is monotone increasing:

If $$x \geq 0$$, $$f'(x) = \frac{1}{(1 + x)^2} > 0$$.

So $$f$$ is increasing.

(2) Triangle inequality applies:

We have $$|x_n-y_n|≤|x_n-z_n|+|z_n-y_n|$$ and so

$$\frac {|x_n-y_n|}{1+|x_n-y_n|}≤ \frac {|x_n-z_n|+|z_n-y_n|}{1+|x_n-z_n|+|z_n-y_n|}=\frac {|x_n-z_n|}{1+|x_n-z_n|+|z_n-y_n|} + \frac {|z_n-y_n|}{1+|x_n-z_n|+|z_n-y_n|}≤\frac{|x_n-z_n|}{1+|x_n-z_n|}+\frac {|z_n-y_n|}{1+|z_n-y_n|}$$

Therefore $$\frac{|x_n - z_n|}{1 + |x_n - z_n|}+\frac{|z_n-y_n|}{1 + |z_n-y_n|} \geq \frac{|x_n-y_n|}{1 + |x_n-y_n|}$$.

(3) Metric satisfies triangle inequality:

We know $$\frac{|x_n - z_n|}{1 + |x_n - z_n|}+\frac{|z_n-y_n|}{1 + |z_n-y_n|} \geq \frac{|x_n-y_n|}{1 + |x_n-y_n|}$$. So

$$2^{-n}(\frac{|x_n - z_n|}{1 + |x_n - z_n|}+\frac{|z_n-y_n|}{1 + |z_n-y_n|}) \geq 2^{-n}\frac{|x_n-y_n|}{1 + |x_n-y_n|}$$

and

$$\sum_{n = 1}^{\infty} 2^{-n}(\frac{|x_n - z_n|}{1 + |x_n - z_n|}+\frac{|z_n-y_n|}{1 + |z_n-y_n|}) \geq \sum_{n = 1}^{\infty} 2^{-n}\frac{|x_n-y_n|}{1 + |x_n-y_n|}$$

QED.

First of all, is this correct? If so, is that it? Is that sufficient to show that $$d$$ is a metric on $$X$$? Although I understood how to prove the hints, I still am not sure how these hints actually show that $$d$$ is a metric on $$X$$, presuming they are sufficient to show this. Any insight is much appreciated.

The definition of a metric $$d$$ has 3 requirements for all points $$x, y \in X$$.

1. $$d(x, y)=0 \iff x=y$$
2. $$d(x, y)=d(y, x)$$
3. triangle inequality.

You've proved the last requirement successfully, now all you need to do is prove the first two (this is quite straight forward).

• Actually nevermind that last comment. Thank you! Mar 12 at 2:58
• Sorry, don't you also need to show that $d(x, y) \geq 0$? How would one go about doing that in this case? @jMdA Mar 12 at 3:02
• No, that's a consequence of the triangle inequality and symmetry $2d(x,y) = d(x, y)+d(y,x)\geq d(x, x)=0$.
– jMdA
Mar 12 at 3:04
• One last thing. When showing the $\implies$ direction in the first one, is this correct: $d(\{x_n\}, \{y_n \}) = 0 \implies \sum_{n = 1}^{\infty} 2^{-n}\frac{|x_n - y_n|}{1 + |x_n - y_n|} = 0 \implies \lim_{n \rightarrow \infty} 2^{-n} \frac{|x_n - y_n|}{1 + |x_n - y_n|} = 0 \implies \frac{|x_n - y_n|}{1 + |x_n - y_n|} = 0 \implies x_n = y_n$ Mar 12 at 3:16
• Not exactly, you have to use that it is a sum of non-negative numbers that sums to zero, therefore each of the terms has to be zero. The limit isn't enough for each of the terms to be zero.
– jMdA
Mar 12 at 3:35