Existence of limit of function $f(x)$ is a real function such that for every $a>0$ is $\lim_{n \to \infty} f(an)=0$. Does there necessarily exist $\lim_{x \to \infty}f(x)$?
 A: No, let $(x_k)_{k\geq 1}$ be a sequence of rationally independent reals with $\lim_k x_k=+\infty$ and define the function $f(x)=1$ if $x=x_k$ some $k$ and zero otherwise. Then for any $a>0$ there is at most one value of $n$ for which $f(an)>0$. So $f$ verifies the condition but does not converge at infinity.
A: no! consider the function $$f(n+\frac{1}{p})=\frac{p}{n-p}$$ where $p$ is prime, $n\in \mathbb{N},n>p$, and $0$ otherwise.
then if $a\notin \mathbb{Q}$, or $a\leq 0$, then $\forall n, f(an)=0$,
and if $a\in\mathbb{Q}$ it has a finity number of prime factors. let the largest be $P$. and let $0<\epsilon<1$.
then $$an=n+1/p \Rightarrow  p\leq P $$and so $$an>2P\dfrac{1}{\epsilon} \Rightarrow  |f(an)|<\dfrac{P}{2P\dfrac{1}{\epsilon}-P}<\dfrac{P}{P\dfrac{1}{\epsilon}}=\epsilon$$ which gives $$lim_{n\rightarrow\infty}f(an)=0$$
but, $lim_{x\rightarrow\infty}\neq 0$, because for $b_n=p_n+\dfrac{1}{p_n}$, where $p_n$ is the enumeration of primes, $$f(b_{n}) = \dfrac{p_n}{p_n+\dfrac{1}{p_n}-p_n}=p_n^2$$
