Determine if the following function is uniformly continuous in the given domain.
$f(x)=x^2 , \quad \text{in}\quad [0,\infty], [0,1]$
My try:
For the domain $[0,\infty]$. Let $(x_n)=n, (y_n)= n +\frac{1}{2n}$
Then $|n-n-\frac{1}{2n}|=\frac{1}{2n} < \frac{1}{n}$
But, $|(n)^2-(n+\frac{1}{2})^2| = 1 + \frac{1}{(2n)^2} \geq 1 = \epsilon _0$
Then $f(x)=x²$ is not uniformly continuous in the domain $[0,\infty]$
For the domain $[0,1]$. Let $(x_n)=\frac{1+n}{n}, (y_n)= \frac{1+2n}{2n}$
Then $|\frac{1+n}{n}-\frac{1+2n}{2n}| = \frac{1}{2n} < \frac{1}{n}$
But, $|(\frac{1+n}{n})^2-(\frac{1+2n}{2n})^2|=\frac{1}{n} + \frac{3}{4n^2} \geq 1 = \epsilon _0$
Then $f(x)=x²$ is not uniformly continuous in the domain $[0,1]$
I'm not sure if my method is correct. Any suggestions would be great!
Another way to see that the function is uniformly continuous on $[0,1]$ whithout using Heine's theorem is to prove that the definition of uniform continuity is satisfied.
Indeed, let $\varepsilon > 0$. Let $\eta = \varepsilon/2$. For all $x,y \in [0,1]$ such that $|x-y|<\eta$, you have $$|x^2-y^2| = |(x-y)(x+y)| \leq 2\eta = \varepsilon$$
So the definition is satisfied.