Big O notation and summing functions

53 Views Asked by At

I know that if two functions, f and g are $O(h)$ then $f - g$ is also $O(h)$. Say for instance, $f$ is $O(x^2)$ and $g$ is $O(x^3)$, what does this say about $f - g$ in terms of Big $O(x^2)$? I'm assuming that the latter can't be $O(x^2)$ since both functions aren't $O(x^2)$. However, won't the limit of $ \frac{f - g} {h} $ as $x$ gets large be $ - \infty$?

1

There are 1 best solutions below

0
On

Note that if $f$ is $O(x^2)$, it is also $O(x^3)$. Note that if $x>1$, we have $x^2 < x^3$.

Hence, now you can use the result since $f$ and $g$ are $O(x^3)$.