Limit question unknown function

If $$\lim_{x \rightarrow 0} f(x)+f(2x)=0$$, prove or disprove with example, that $$\lim_{x \rightarrow 0} f(x)=0$$ for any function $$f(x)$$.

f(x) can be a piecewise functions as well.

I tried too disprove it considering several functions but I wasn't able to do so. So I guess that there statement is true but how do we prove it?

• Hint: find a non-zero function that satisfies $f(2x)=-f(x)$. A good place to start might be with $\sin x$ since at least $\sin (x+\pi)=-\sin x$.
– lulu
Sep 29, 2019 at 12:32
• We would also require $f(x) \neq 0$ as $x \to 0$ for disproving the statement isn't? I tried all several functions such as (-1)^x *gif(greatest integer function, Signum function, and creating some piecewise function, but for all either the limit doesn't exist or the statement comes out to be true Sep 29, 2019 at 13:02
• Consider $f(x)=\sin\left(\pi\log_2(x)\right)$
– robjohn
Sep 29, 2019 at 13:04
• @thewitness: define $f(0)=0$.
– robjohn
Sep 29, 2019 at 13:07
• @robjohn I mean $x \to 0^{-}$ for f(x) isn't defined. Sep 29, 2019 at 13:08

$$f(x) = (-1)^n \hspace{14 pt} 2^n \leq |x| < 2^{n+1}$$
for $$n\in\mathbb{Z}$$. Clearly $$f(x) + f(2x)=0$$ on $$\mathbb{R}-\{0\}$$ but $$\lim_{x\to 0} f(x)$$ does not exist since the function oscillates infinitely fast as you get closer to $$0$$.
• The sum of the limits has been assumed to exist in the premise. Does, $\lim_{x \to 0} (f(x) +f(2x))$ exist here? Sep 29, 2019 at 13:17
• @DevashishKaushik It does, as I said $f(x)+f(2x)=0$ everywhere except $0$. Sep 29, 2019 at 13:19