Discrete math: determine whether $f(x) = x\log(x)$ is an element of $O(x^2)$

2.3k Views Asked by At

I'd really appreciate if someone could let me know if this is a valid approach to proving that $f\left(x\right) = x\log \left(x\right)$ is in fact not of complexity $O\left(x^2\right)$:

Proof by contradiction

I'll assume that $f\left(x\right) = x\log \left(x\right)$ is of complexity $O\left(x^2\right)$, which implies that for some witnesses $c$ and $k$, for all $x \geq k$, we have that $f\left(x\right) \leq c * x^2$. Let us choose $k = 1$ such that $x \geq 1$:

  1. $x \log \left(x\right) \leq c*x^2$

  2. $\frac{\log \left(x\right)}{x} \leq c$ (note that this is because $x \ne 0$)

  3. An expression involving variables cannot always be less than a chosen constant. Therefore, this function does not satisfy the requirements for complexity of $O\left(x^2\right)$.