Upper bound for linear function

360 Views Asked by At

What may be more surprising is that when $a>0$, any linear function $an +b$ is $\mathcal{O}(n^2)$ which is easily verified by taking $c = a + |b|$ and $n_o = \max (\frac{-b}{a}, 1)$.

$$an + b < cn^2,n>n_o$$ $$\frac{a}{n} + \frac{b}{n^2} < c, n>n_o$$ $$\implies c = a + |b|, n > 1$$

Why does the excerpt use $n_o = \max (\frac{-b}{a}, 1)$ instead of $n_o = 1$? Thanks for the help.