# Thread: Comparing growth of functions

1. ## Comparing growth of functions

I have two functions:

$\displaystyle f(n)=3^\log_{2}n^2$
and
$\displaystyle g(n)=3^\log_{2}\frac{n^2}{2}$

I have to prove it its big-Oh/theta/omega

I have to use the limit method where:
limit n going to infinity of
$\displaystyle \frac{f(n)}{g(n)}$
Then L'Hospital's rule, but when I take the derivatives of both and cancel out everything I just get what I was left with before. Am I doing something wrong? Am I not taking the derivative correctly?
I was using $\displaystyle \frac{d}{dx}a^x=log(a)a^x$ and chain rule.
Can someone help me to clarify this?

2. That L'Hospital's rule leads to the same ratio is natural since, as you pointed out, the derivative of $\displaystyle a^x$ again contains $\displaystyle a^x$.

One can easily do without L'Hospital's rule here since $\displaystyle f(n)/g(n)$ is a constant.

3. Oh, it isn't infinity over infinity?

4. It is. However, for instance, $\displaystyle 3n^2/(2n^2)$ is also infinity over infinity, and yet this fraction not only tends to 3/2, but is equal to 3/2.

I personally was taught to avoid L'Hopital's rule and to study the function's behavior. Often this results in better understanding of why the limit is what it is.