2

Consider $f: \mathbb{R} \to \mathbb{R}$. Suppose that for all $x \in \mathbb{R}$ the following condition holds: $$f\Big(\frac{x}n\Big) \to 0, \quad n \to \infty.$$ Does it follow that $\lim_{x \to 0} f(x) = 0?$ If I'm right then there's a counterexample.

Question. Is there a simple counterexample? Is there an explicit form of such a function $f$?

My counterexample. It looks like we may create it this way. Find positive numbers $a_1, a_2, \ldots $ which are linearly independent over $\mathbb{Q}$ and which are s.t. $a_n \downarrow 0$. Put $f_1 (x) = \frac{1}k$ if $x = \frac{a_1}k$ for some $k \in \mathbb{N}$ and $f_1(x) = 0$ otherwise. Put $f(x) = \inf_n f_n(x)$. Notice that $f_m(a_n)=0$ if $m \ne n$ and $f_n(a_n)=1$. We have $f(a_n)=1$ and $a_n \to 0$ hence $f$ is a counterexample.

Addition. As @Martin R said below there's a simplification of this example: we may put $f(x) = 1$ if $x = a_n$ for some $n$, and $f(x)=0$ otherwise.

Martin R
  • 113,040
  • 2
    Compare https://math.stackexchange.com/q/1891438/42969 for the same problem with limits at $\infty$. It looks similar, so that is probably the right way to go. – Martin R Feb 01 '23 at 12:29
  • 1
    You might also be interested in https://math.stackexchange.com/q/63870/42969: The statement is true for continuous functions, but the proof requires the Baire category theorem. Which again demonstrates that this stuff is not “simple.” – Martin R Feb 01 '23 at 12:34
  • @MartinR Very interesting! I didn't expect Baire categories here and supposed that I'm just overcomplicating in an attempt to construct a counterexample. Because the statement of the problem looks suspiciously simple:) – Sergei Nikolaev Feb 01 '23 at 12:37
  • 1
    Looking at the thread mentioned in my first comment, you can probably simplify the construction to $f(x) = 1$ if $x=a_k$ for some $k$, and $f(x) = 0$ otherwise. – I suggest to close this as a duplicate of https://math.stackexchange.com/q/1891438/42969 – Martin R Feb 01 '23 at 12:38
  • 1
    Btw, I found those related threads with Approach0 – Martin R Feb 01 '23 at 12:40
  • 2

2 Answers2

2

Yes. Without continuity, counter-example exists.

Claim 1: There exists a countable subset $A\subseteq[0,\infty)$ whose elements are $\mathbb{Q}$-linearly independent, in the sense that: For any pairwisely distinct $a_{1},a_{1},\ldots,a_{n}\in A$ and $r_{1},r_{2},\ldots,r_{n}\in\mathbb{Q}$, if $\sum_{k=1}^{n}r_{k}a_{k}=0$, then $r_{1}=\ldots=r_{n}=0$.

Proof of Claim 1: We construct $A$ by recursion. Pick any $a_{1}\in\mathbb{R}\setminus \{0\}$. Suppose that $a_{1},a_{2},\ldots,a_{n}$ have been chosen such that they are $\mathbb{Q}$-linearly independent. Note that $\{\sum_{k=1}^{n}r_{k}a_{k}\mid r_{k}\in\mathbb{Q}\}$ is a countable set while $\mathbb{R}$ is uncountable, so we may choose $a_{n+1}\in\mathbb{R}\setminus\{\sum_{k=1}^{n}r_{k}a_{k}\mid r_{k}\in\mathbb{Q}\}$. We go to verify that for any $r_{k}\in\mathbb{Q}$ if $\sum_{k=1}^{n+1}r_{k}a_{k}=0$, then $r_{1}=\ldots=r_{n+1}=0$. If $r_{n+1}\neq0$, then $a_{n+1}=-\frac{r_{1}}{r_{n+1}}a_{1}-\ldots-\frac{r_{n}}{r_{n+1}}a_{n}$, contradicting to how $a_{n+1}$ is chosen. Now $r_{n+1}=0$, and the expression reduces to $\sum_{k=1}^{n}r_{k}a_{k}=0\Rightarrow r_{1}=r_{2}=\ldots=0$ by induction hypothesis.

Define $A=\{a_{1},a_{2},\ldots\}$. It is clear that $A$ is $\mathbb{Q}$-linearly independent.


Enumerate $A=\{a_{1},a_{2},\ldots\}$. For each $i$, choose $r_{i}\in\mathbb{Q}$ suitably such that $r_{1}a_{1}>r_{2}a_{2}>r_{3}a_{3}>\ldots>0$ and $r_{n}a_{n}\rightarrow0$. Clearly, such a choice exists. For, choose $r_{1}\in\mathbb{Q}$ such that $r_{1}a_{1}\in(0,1)$. Suppose that $r_{1},r_{2},\ldots,r_{n}$ have been chosen. Choose $r_{n+1}\in\mathbb{Q}$ such that $r_{n+1}a_{n+1}\in(0,\frac{1}{n+1}\wedge r_{n}a_{n})$. (Here $x\wedge y:=\min(x,y)$. Denote $b_{n}=r_{n}a_{n}$. Let $B=\{b_{1},b_{2},\ldots\}$. Observe that $B$ is still $\mathbb{Q}$-linearly independent.

Define $f:\mathbb{R}\rightarrow\mathbb{R}$ by $f(x)=1_{B}(x)$. Clearly it is false that $\lim_{x\rightarrow0}f(x)=0$ because $f(b_{n})=1$ but $b_{n}\rightarrow0$. Next, we verify that $f(\frac{x}{n})\rightarrow0$ for each $x\in\mathbb{R}$. Observe that for each $x\in\mathbb{R}$, there exists at most one $n$ such that $\frac{x}{n}\in B$. For, if there exist $n_{1}<n_{2}$ such that $\frac{x}{n_{1}},\frac{x}{n_{2}}\in B$, then $n_{1}\left(\frac{x}{n_{1}}\right)+(-n_{2})\left(\frac{x}{n_{2}}\right)=0$, contradicting that $B$ is $\mathbb{Q}$-linearly independent. Now, it is obvious that $f(\frac{x}{n})\rightarrow0$.

1

Yes, the counterexample provided is correct. The function $f(x) = 1$ if $x =a_n$ for some $n$ and $f(x) = 0$ otherwise is an example of a function that satisfies the condition $f(x_n) \to 0$ as $n\to\infty$, but does not have a limit at $x = 0$. This is because the sequence of points ${a_n}$ approaches $0$ but the function values at these points do not approach $0$.

TShiong
  • 1,257
iGeni
  • 19