lower bound for the prime number function

Solution 1:

This segment of the Wikipedia article mentions a few such bounds. In all cases, the bounds hold from a certain explicit $N$ on. They can be easily be made unconditional without changing the asymptotic behaviour by suitably redefining the functions for $x \lt N$.

For instance, the article mentions the bounds $$\frac{x}{\ln x+2}<\pi(x)<\frac{x}{\ln x-4},$$ valid for $x \ge 55$, as well as much stronger bounds by Pierre Dusart. Since $\pi(x)$ is asymptotically $x/\ln x$, the two bounds above have the right asymptotic properties. Tweaking the lower bound so that it is valid below $55$ is easy. The crudest method is to use the function which is $-1$ for $x \lt 55$, and $x/(\ln x +2)$ for $x \ge 55$. Asymptotic behaviour is unaffected.

Solution 2:

I found an more 'elegant' lower bound:

$$ \frac{n}{\log\,n} - 2 \leq \pi(n), \; n \geq 2 $$ Primality Testing in Polynomial Time