1

Say that $f(n) = \cal O(n^2)$ and $g(n) = \cal O(n)$.

If $h(n)=f(n)/g(n)$, is it true that $h(n) =\cal O(n)$?

Is it mathematically correct to say that $h(n) = \cal O(n^2)/ O(n) = O(n)$? if not, what would be the correct way to show this?

Raphael
  • 73,212
  • 30
  • 182
  • 400
user16742
  • 235
  • 2
  • 3
  • 6

1 Answers1

9

Let $f(n)= n^2$ and $g(n)=1$. Then $f(n) = \cal O(n^2)$ and $g(n) = \cal O(n)$.

However, $h(n)=f(n)/g(n)=n^2/1 = n^2 \neq \cal{O}(n)$.

Flatfoot
  • 111
  • 2