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

continuityproof-verificationreal-analysis

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.

Best Answer

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.