# Alternative Answer for Baby Rudin $4.1$: Does $\lim_{h\rightarrow 0}[f(x+h)-f(x-h)]=0$ imply continuity?

Can anyone point out the mistake I am making for the following question?

The problem is written in Baby Rudin Chapter $$4$$.

Suppose $$f$$ is a real function defined on $$E$$, which satisfies,

$$\lim_{h\rightarrow 0}[f(x+h)-f(x-h)]=0$$

for every $$x\in R^1$$. Does this imply that $$f$$ is continuous?

My solution for this problem is of following.

From condition given in the question,

$$\lim_{h\rightarrow 0}[f(x+h)-f(x)]=\lim_{h\rightarrow 0}[f(x-h)-f(x)]$$

As a way of contradiction, suppose that $$f$$ is not continuous.

Therefore, There exists a $$x\in R$$ such that

$$\exists \epsilon>0 ,s.t.$$ $$d(f(x^\prime),f(x))>\epsilon$$ for all $$x^\prime \in B_\delta(x), \forall \delta>0$$

Generate a decreasing sequence $$\{\delta_n\}_{n=1}^\infty$$ such that $$\delta_k>\delta_{k-1}, \forall k$$.

By taking out a $$x_{n}^{\prime}$$ from each open ball defined around $$x$$ with radius $$\delta_{n}$$, we can create a partial sequence $$\{x_{n_k}\}$$ that converges to $$x$$ but the mapping $$f(x^\prime)$$ does not.

This contradicts the assumption, since it requires that each of the limits of functions on both sides to converge.

$$\lim_{h\rightarrow 0}[f(x+h)-f(x)]=\lim_{h\rightarrow 0}[f(x-h)-f(x)]$$

There is a solution manual (https://minds.wisconsin.edu/bitstream/handle/1793/67009/rudin%20ch%204.pdf?sequence=8&isAllowed=y) which gives an explanation of a counterexample, but I cant figure out which part in my proof is wrong.

• "From the condition given in the question..." The equation following this does not hold. In fact, neither the LHS nor the RHS need exist. For a simple counterexample, take $f(x) = \sin(1/|x|)$ for $x \neq 0$, and define $f(0)$ to be anything you want. This function satisfies the condition in the problem statement but it is not continuous at $x=0$. – Bungo Jul 26 '19 at 2:18

There are several mistakes in your work. Two of them are not serious; they can be side-stepped in this particular proof but they are important things to list as they concern correct use of definitions and correct proof-technique:

### Small Errors:

$$\underline{\textit{You did not negate continuity correctly:}}$$

$$\exists \epsilon>0 ,s.t.$$ $$d(f(x^\prime),f(x))>\epsilon$$ for all $$x^\prime \in B_\delta(x), \forall \delta>0$$

That is not exactly the negation of continuity at $$x$$. This is:

$$\exists \epsilon>0,\ s.t. \forall \delta > 0 \underline{\textbf{ there exists }} x' \in B_\delta(x)\ s.t. d(f(x'), f(x)) > \epsilon$$

$$\underline{\textit{You probably want the sequence of \delta_n to approach 0:}}$$

By taking out a $$x_{n}^{\prime}$$ from each open ball defined around $$x$$ with radius $$\delta_{n}$$, we can create a partial sequence $$\{x_{n_k}\}$$ that converges to $$x$$ but the mapping $$f(x^\prime)$$ does not.

You can have a sequence of decreasing $$\delta_n$$ that does not approach $$0$$. In that case, the sequence elements $$x_n'$$ you picked out from each $$B_{\delta_n}(x)$$ may not even converge to $$x$$ as you wanted them to.

Okay, now let us look at the serious errors that break your proof:

### Serious Errors:

$$\underline{\textit{Your very first step is wrong:}}$$

From condition given in the question,

$$\lim_{h\rightarrow 0}[f(x+h)-f(x)]=\lim_{h\rightarrow 0}[f(x-h)-f(x)]$$

No, you can have functions that satisfy $$\lim_{h\rightarrow 0}[f(x+h)-f(x-h)] = 0$$ but neither $$RL\ (\text{Right Limit}) = \lim_{h\rightarrow 0}[f(x+h)-f(x)]$$ nor $$LL \ (\text{Left Limit}) = \lim_{h\rightarrow 0}[f(x-h)-f(x)]$$ exist, let alone equal one another.

E.g. pick your favorite even function with an asymptote at $$0$$ like $$f(x) = \frac{1}{x^2}$$ or $$f(x) = \frac{1}{x^4}$$, etc and define $$f(0)$$ to be whatever real you like. You can check that neither the $$RL$$ nor $$LL$$ exist at $$x = 0$$ due to the asymptote. But because the function is even, $$f(0+h) - f(0-h) = 0$$ so that $$\lim_{h\rightarrow 0}[f(0+h)-f(0-h)] = 0$$.

$$\underline{\textit{And even if your first step was correct:}}$$

In your defense, I will admit that the example given in your link: $$f(x) = \begin{cases}1 &\text{ x an integer} \\ 0 &\text{ otherwise }\end{cases}$$ does satisfy both $$\lim_{h\rightarrow 0}[f(x+h)-f(x-h)]=0$$ and $$\lim_{h\rightarrow 0}[f(x+h)-f(x)]=\lim_{h\rightarrow 0}[f(x-h)-f(x)]$$ But even then:

This contradicts the assumption, since it requires that each of the limits of functions on both sides to converge.

$$\lim_{h\rightarrow 0}[f(x+h)-f(x)]=\lim_{h\rightarrow 0}[f(x-h)-f(x)]$$

No it doesn't contradict that assumption. $$\lim_{h\rightarrow 0}[f(x+h)-f(x)]$$ being equal to $$\lim_{h\rightarrow 0}[f(x-h)-f(x)]$$ does not mean that either of those limits should converge to $$0$$.

Indeed, for the example given in the question, you can check that at integer points $$x$$,

$$\lim_{h\rightarrow 0}[f(x+h)-f(x)] = \lim_{h\rightarrow 0}(0 - 1) = -1$$ and

$$\lim_{h\rightarrow 0}[f(x-h)-f(x)] = \lim_{h\rightarrow 0}(0 - 1) = -1$$.

Hence, the two limits are equal to each other but neither of them are $$0$$. So, the fact that your picked out sequence $$x_n'$$ converges to $$x$$ while the $$f(x_n')$$'s do not converge to $$f(x)$$ is not a contradiction.

• Thank you! I would like to choose this as my best answer, due to clear explanation and abundant details. – Keitaro Ninomiya Jul 29 '19 at 2:51
• @KeitaroNinomiya Glad to be of help. – 0XLR Jul 29 '19 at 2:51

Bungo beat me to this in the comments. I am just expanding upon their answer.

The first claim you make in your proof is incorrect. To convince yourself, consider $$f(x)=\begin{cases} 1/|x| & \text{if }x \neq 0 \\ 0 & \text{if }x = 0. \end{cases}$$ In general, $$\lim_{n}(a_{n}-b_{n})=0$$ does not imply $$\lim_{n}a_{n}=\lim_{n}b_{n}$$. The converse, however, is true from the sum law of limits.

• Ah, even simpler without the $\sin$ :-) +1 – Bungo Jul 26 '19 at 2:24
• The sin example is nice too as it is not of bounded variation. – parsiad Jul 26 '19 at 2:26
• Yours is also not of bounded variation (bounded variation implies bounded). After the fact an even simpler counterexample occurs to me: $$f(x) = \begin{cases}1 & \text{ if }x \neq 0 \\ 0 & \text{ if }x = 0\end{cases}$$which is of bounded variation. In this example, the two limits in the first sentence of the OP's attempted solution exist and are equal, but they're nonzero. So this shows that even if the equality in the first sentence holds, it still doesn't imply continuity of $f$. – Bungo Jul 26 '19 at 22:01
• Thank you for the very useful comments! The link for summation of limits seems to be very useful! – Keitaro Ninomiya Jul 29 '19 at 2:56

Apart from the problem pointed out by Bungo, even if the limits do exist, they are non necessarily zero. Thus, there is no contradiction between the conditions that $$\ \lim_\limits{k\rightarrow\infty} x_{n_k}=x\$$, $$\ \lim_\limits{k\rightarrow\infty} f\left(x_{n_k}\right) \ne f\left(x\right)\$$, and $$\lim_{h\rightarrow 0}[f(x+h)-f(x)]=\lim_{h\rightarrow 0}[f(x-h)-f(x)]\$$. We could have $$\lim_{h\rightarrow 0}[f(x+h)-f(x)]=\lim_{h\rightarrow 0}[f(x-h)-f(x)]= C\ne0\ \ \mbox{and}\\ \lim_\limits{k\rightarrow\infty} f\left(x_{n_k}\right) = f\left(x\right) + C\ ,$$ for instance.

• Thank you for replying! In the proof, I was trying to imply that for the assumption that "RHS and LHS should equal" is violated. This is because for an equation to hold, the RHS or LHS should converge to a number (not necessarily 0). (Although I am convinced that the equality between RHS and LHS is not guaranteed in the first place) – Keitaro Ninomiya Jul 29 '19 at 3:00

Thank you for all the comments and answers! I guess I have not quite yet been used to properties of summation of limits.

Example : $$\lim_{x\rightarrow0}(f(x)+g(x))$$ is not necessary $$\lim f(x)+\lim g(x)$$ .