1
$\begingroup$

So I'm trying to figure this one out, suppose this problem A.

$f(n) = n^2 - 2n$ and $g(n) = n^2$.

I want to prove that $f(n) \in \Omega(g(n))$ by showing a set of inequalities between $f(n)$ to $g(n)$ to derieve the $c > 0$ and $n_0 > 0$.

For example, say

$f(n) = n^2 + 2n$ and $g(n) = n^2$ and $f(n) \in O(g(n))$.

Clearly, $n^2 + 2n \le n^2 + 2n^2 = 3n^2 \quad \forall n_0>0$ Thus, if $c = 3$ and $n_0 > 0$, we have proved $f(n) \in O(g(n))$.

How do I do this for the former problem, problem A?

Thanks.

2 Answers 2

0

For large $n$, $$f(n)=n^2-2n \ge \frac{1}{2} n^2 = \frac{1}{2} g(n).$$ To find $n_0$ explicitly, note $$n^2-2n - \frac{1}{2}n^2= \frac{1}{2} n(n-4) > 0$$ for $n>4$.

0

We have that $f(n) \in \Omega(g(n))$ if there exists a constant $c>0$ and an $n_0$ such that $f(n) \geq c \cdot g(n)$ whenever $n \geq n_0$. In other words, $f(n) \in O(g(n))$ if and only if $g(n) \in \Omega(f(n))$.

If $f(n) = n^2 - 2n$ and $g(n) = n^2$, you must find a $c > 0$ and an $n_0$ such that

$$n^2 - 2n \geq c \cdot n^2 \text{ whenever } n \geq n_0$$

This is the case iff

$$(1 - c)n^2 \geq 2n \text{ whenever } n \geq n_0$$

iff $n \geq \frac{2}{1-c}$. So take $n_0 = \lceil \frac{2}{1-c} \rceil$.