Q:

Relation Big-O and limit of a function?

It is not clear to me what it the relationship (if any) between Big-O and limit of a function. Suppose that a function $f(x)=O(g(x))$: does this imply that $f(x)$ converges to a limit as $x\rightarrow \infty$? And viceversa, suppose that $f(x)$ converges to a limit as $x\rightarrow \infty$: does this imply that there exists a function $g(x)$ s.t. $f(x)=O(g(x))$? 

A:

When we say a function $f$ is $O(g)$ we are making a statement about its asymptotic behavior. This means that there exists some threshold $M\gt 0$ and some constant $N$ such that $x\gt M\implies |f(x)|\le N|g(x)|$. 
Let's compare this to the definition of a limit.
$\lim_{x\to\infty}f(x) = L$ if for all $\epsilon\gt 0$ there exists $M\gt 0$ such that $x\gt M\implies |f(x)-L|\lt\epsilon$.
The two different definitions are very similar but not the same. With big $O$ notation we are simply saying that, for large $x$, the magnitude of $f$ is no larger than the magnitude of $g$. The limit is saying that $f$ is getting arbitrarily close to a constant.
To see if you understand this I leave you with two exercises.

If $\lim_{x\to\infty}f(x) = L$, prove that $f$ is $O(1)$
Prove that $f$ is $O(f)$

