Uniform continuity implies existence of increasing continuous function In the book that I’m reading, the author makes the following assertion, which I was not able to prove:
If $c:\mathbb R \times \mathbb R\to \mathbb R$ is a continuous function on a compact set (i.e $c$ restricted to a compact set) and hence uniformly continuous, then there exists an increasing continuous function $w:\mathbb R_+ \to \mathbb R_+$, with $w(0)=0$ and such that
$$
\mid c(x,y) - c(x’,y’) \mid \leq w(d(x,x’) + d(y,y’))
$$
Can anyone prove that this is in fact true?
P.s: Note that $d$ is a metric.
A friend of  mine showed me the solution, so here it is:
I'll sove this for $\mathbb R$ instead of $\mathbb R^2$ for sake of simplicity, because the proof is the same. So, I'll change $c:\mathbb R \times \mathbb R \to \mathbb R$ for $f:\mathbb R\to \mathbb R$, also continuous.
Let $K$ be the compact and
$$ w(z) := \sup_{x,y:d(x,y)\leq z} |f(x) - f(y)|$$
Hence, $|f(x) - f(y)|\leq w(d(x,y))$. Also, it's clear that $w$ is an increasing function. We have to prove that $w$ is continuous, and $w(0)=0$.
It's clear that $w(0) = 0$, since $d(x,y) =0 \iff x=y$.
The only thing left to prove is the continuity, which we'll prove for $w$ at 0, and a similar proof can be done to other points.
Note that since $f$ is continuous on a compact set, it is then uniformly continuous. Therefore,
$$\forall \epsilon&gt;0, \exists  \delta&gt;0, \quad \text{s.t} \quad  d(x,y) \leq \delta \implies |f(x) - f(y)| \leq \epsilon$$
Taking the $\sup$ , we obtain that:
$$
\sup_{x,y:d(x,y)\leq \delta}|f(x) - f(y)| = w(\delta) \leq \epsilon
$$
This means that $d(x,y)\leq \delta \implies w(\delta) \leq \epsilon$, hence,
$\lim_{\delta \to 0}w(\delta) = 0$.
Which proves that $w(0) =0$m and that $w$ is continuous on $0$. The only thing left to do is to prove the continuity for the rest of the points, which I could not do actually.
This is not true in general. Consider $c(x,y) = x^2$ and the points $(x, y), (x', y')$ such that $d(x, x') = d(y, y') =a$ in which case the RHS is 0. But $x^2 - x'^2$ is not always 0.