Show that function $f(\mathbf{x})= (|x_1-x_2|,|x_2-x_3|,...,|x_n-x_1|)$is continuous How to show that the function $\space f: \Bbb{R^n} $ $\rightarrow$ $\Bbb{R^n}$ such that it takes a vector $\mathbf{x} = (x_1,...,x_n)$ and returns a vector consisting of absolute values of the differences: $f(\mathbf{x})= (|x_1-x_2|,|x_2-x_3|,...,|x_n-x_1|)$ is continuous? If I can show that function that takes $1 \rightarrow 2, 2 \rightarrow 3, etc.$ is a bijection will that be enough? 
Thank you. 
 A: Here I use the notations $$x = (x^1,\dots,x^n), \quad x_0 = (x^1_0,\dots,x^n_0)$$
and assume you work with the standard topology on $\mathbb{R}^n$. By definition $f$ is continuous at $x_0 \in \mathbb{R}^n$ if 
$$\forall \varepsilon > 0 \mbox{ }  \exists \delta > 0 \text{ such that } ||f(x)-f(x_0)|| < \varepsilon \text{ whenever } ||x-x_0|| < \delta$$
and $|| \cdot ||$ is induced by the standard inner product on $\mathbb{R}^n$. Observe that
$$f(x)-f(x_0) = (|x^1-x^2|-|x_0^1-x_0^2|,\dots,|x^n-x^1|-|x_0^n-x_0^1|).$$
Thus fix $\varepsilon > 0$ and look for $\delta$. On $\mathbb{R}$ the following (triangle) inequalities hold for every pair $a,b$:
\begin{equation}
||a|-|b|| \leq |a-b|, \quad |a+b| \leq |a|+|b|.
\end{equation}
Then, applying both, you can see that
\begin{align}
||x^1-x^2|-|x_0^1-x_0^2|| & \leq |x^1-x^2-x_0^1+x_0^2| \\
& = |(x^1-x_0^1)+(x_0^2-x^2)| \\
& \leq |x^1-x_0^1|+|x_0^2-x^2|\\
& \leq |x^1-x_0^1|+|x^2-x_0^2| \\
& \leq \sqrt{\sum_{i=1}^n (x^i-x_0^i)^2} = ||x-x_0|| \leq \delta
\end{align}
and you can easily generalize this procedure to all the components of $f(x)-f(x_0)$, getting the same inequality. Hence
\begin{align}
||f(x)-f(x_0)|| & = \sqrt{(|x^1-x^2|-|x_0^1-x_0^2|)^2+\dots+(|x^n-x^1|-|x_0^n-x_0^1|)^2} \\
& \leq \sqrt{n\delta^2} \leq \sqrt{n}\delta .
\end{align}
 So if you take $\delta = \frac{\varepsilon}{\sqrt{n}}$ the continuity at $x_0$ follows. As $x_0$ is arbitrary, $f$ is continuous on all of $\mathbb{R}^n$.
