# Proof that a function is continuous in R

I have some trouble with this problem, I'll write what I did

Problem:

$f(x) = x^2-2x$

Prove f continuous in $\Bbb R$.

My solution:

I need to prove that: $$\lim_{x \to x_0} f(x) = f(x_0)$$

Or more specifically,

To all $\epsilon>0$ exist $\delta>0$ so to $x\in\mathbb{R}$ (function is a polynomial), $$|x-x_0|<\delta\mbox{ then }|f(x)-f(x_0)|<\epsilon$$

So

$|f(x)-f(x_0)|$ =

$|x^2-2x-x_0^2+2x_0|$ =

$|-2(x-x_0)+(x-x_0)(x+x_0)|<\epsilon$

Now I got stuck. Any ideas?

Thanks

• Hint: $|-2(x-x_0)+(x-x_0)(x+x_0)| = |x-x_0||-2+x+x_0| < \delta |-2+x+x_0|$. You need to bound $|-2+x+x_0|$. – phaiakia Jul 20 '14 at 18:27
• One idea is to use $=$ instead of $\leftrightarrow$ in places where it is $=$ that you mean. – Andrés E. Caicedo Jul 20 '14 at 18:27
• you may also want to check out math.stackexchange.com/questions/494767/… – Anurag A Jul 20 '14 at 19:03

The idea is to bound $|x^2 -2x - x_0^2 + 2x_0|$ with stuff, so that in the end we get this to be less than $\epsilon$. We know that $|x - x_0| < \delta$. There is a very nice inequality, which we'll use: $$|a| - |b| \leq |a - b|$$ This gives us that $|x| \leq \delta + |x_0|$. There's no harm in suppose that $\delta < 1$ (why?)

So we have $|x| < 1 + |x_0|$. Now, we also use the triangle inequality. It follows: \begin{align} |x^2 - 2x - x_0^2 + 2x_0| &= |(x + x_0)(x -x_0) + 2(x - x_0)| \\ &= |(x + x_0 + 2)(x - x_0)| \\ &\leq (|x| + |x_0| + 2)|x - x_0| \\ &\leq (1 + |x_0| + |x_0| + 2)|x - x_0| \\ &< (3 + 2|x_0|)~\delta\end{align}

So, given $\epsilon > 0$, choosing $\delta = \min \left\{ 1, \frac{\epsilon}{3 + 2|x_0|}\right\}$ will solve the problem.

Once I answered a question on which I gave the general strategy for dealing with $\epsilon - \delta$ proof for polynomials like this one. Maybe you'll find it helpful.

• I just want to make sure I understood correctly. There's is no harm in suppose that $\delta<1$ Because there is no domain meaning that the function is defined for all $x$, so we can choose whatever $\delta$ since for any $\delta>0$ $f(x)\in(x_0-\delta,x_0+\delta)$ is defined. – JaVaPG Jul 21 '14 at 16:53
• I want to ask a question about the the method to find "suitable" $\delta$, I understand the method for finding $\delta$ but I don't understand the point of increasing the expression $|x^2-2x-x_0^2+2x_0|\leq ... < (3+2|x_0|)\delta$. I do understand that the limit definition still appiles even if we increase the expression however if we decrease the expression the limit definition is still taking place, can you explain why do you increase the expression? – JaVaPG Jul 21 '14 at 16:54
• We can suppose that $\delta < 1$, because once given $\epsilon > 0$ and found the appropriate $\delta$, any $\delta'$ less than our "original" $\delta$ will work for the same $\epsilon$. If our "original" $\delta$ happens to be greater than $1$, then $\delta \leq 1$ will work for the same $\epsilon$. The point of increasing the expression is the following: it is hard to bound with $\epsilon$ the very first expression we get, meaning $|x^2 - 2x - x_0^2 + 2x_0|$. We'll do whatever it takes to simplify this. If $$|x^2 - 2x - x_0^2 + 2x_0| \leq (3+2|x_0|)\delta < \epsilon, then surely (cont'd) – Ivo Terek Jul 21 '14 at 17:01 • (cont'd) our initial expression |x^2 - 2x - x_0^2 + 2x_0| is less than \epsilon, as we wanted. We want to bound the initial expression with delta, but nothing stops us from bounding more stuff between. And in fact, doing this makes our lives easier. Ok? – Ivo Terek Jul 21 '14 at 17:02 • All clear, Thank you! – JaVaPG Jul 21 '14 at 17:58 Instead of x_0 I will use a as the point of continuity.Let \epsilon>0 be given then we want to find a \delta>0 such that$$\forall \, x \, |x-a|< \delta \implies |f(x)-f(a)| < \epsilonConsider \begin{align*} |f(x)-f(a)| & = |(x^2-a^2)-2(x-a)|\\ & =|x-a||x+a-2|\\ & =|x-a||(x-a)+2a-2|\\ & \leq |x-a|\left(|x-a|+|2a-2|\right) & \text{using the triangle inequality} \end{align*} We want |f(x)-f(a)| < \epsilon when |x-a|<\delta, so we will work backwards. Fromthe last expression we have we want\delta(\delta+|2a-2|) < \epsilon \qquad \qquad (\star)$$Now consider two cases: when \epsilon \geq 1+|2a-2| : Then we can take \delta=1 and have the inequality hold true. when \epsilon < 1+|2a-2| : then for the last inequality (\star) to hold we can have \delta=\frac{\epsilon}{1+|2a-2|}. Thus$$ \delta= \begin{cases} 1 & \text{ if } \epsilon \geq 1+|2a-2|\\ \frac{\epsilon}{1+|2a-2|} & \text{ if } \epsilon < 1+|2a-2| \end{cases} 

• I don't understand why I should bound it ,Is it possible to choose $0<\delta<=\frac{1}{x+a-2}$? – JaVaPG Jul 20 '14 at 18:44
• Note that $x$ is a variable so the right hand side is varying and you will not have a particular delta to work with thereby the statement that for all $x$ there exists a $\delta$ won't be satisfied. – Anurag A Jul 20 '14 at 18:59
• Thank you for the resource and your answer, all clear! – JaVaPG Jul 20 '14 at 19:32