3-4 Asymptotic notation properties
Let f(n) and g(n) by asymptotically positive functions. Prove or disprove each of the following conjectures.
a. f(n)=O(g(n)) implies g(n)=O(f(n)).
b. f(n)+g(n)=Θ(min(f(n),g(n))).
c. f(n)=O(g(n)) implies lg(f(n))=O(lg(g(n))), where lg(g(n))≥1 and f(n)≥1 for all sufficiently large n.
d. f(n)=O(g(n)) implies 2f(n)=O(2g(n)).
e. f(n)=O((f(n))2).
f. f(n)=O(g(n)) implies g(n)=Ω(f(n)).
g. f(n)=Θ(f(n/2)).
h. f(n)+o(f(n))=Θ(f(n)).
a. Disprove, n=O(n2), but n2=O(n).
b. Disprove, n2+n=Θ(min(n2,n))=Θ(n).
c. Prove, because f(n)≥1 after a certain n≥n0.
∃c,n0:∀n≥n0,0≤f(n)≤cg(n)⇒0≤lgf(n)≤lg(cg(n))=lgc+lgg(n).
We need to prove that
lgf(n)≤dlgg(n).
We can find d,
d=lgg(n)lgc+lgg(n)=lgg(n)lgc+1≤lgc+1,
where the last step is valid, because lgg(n)≥1.
d. Disprove, because 2n=O(n), but 22n=4n=O(2n).
e. Prove, 0≤f(n)≤cf2(n) is trivial when f(n)≥1, but if f(n)<1 for all n, it's not correct. However, we don't care this case.
f. Prove, from the first, we know that 0≤f(n)≤cg(n) and we need to prove that 0≤df(n)≤g(n), which is straightforward with d=1/c.
g. Disprove, let's pick f(n)=2n. We will need to prove that
∃c1,c2,n0:∀n≥n0,0≤c1⋅2n/2≤2n≤c2⋅2n/2,
which is obviously untrue.
h. Prove, let g(n)=o(f(n)). Then
∃c,n0:∀n≥n0,0≤g(n)<cf(n).
We need to prove that
∃c1,c2,n0:∀n≥n0,0≤c1f(n)≤f(n)+g(n)≤c2f(n).
Thus, if we pick c1=1 and c2=c+1, it holds.