A famous inequality that has been proved by J.B. Rosser and L. Schoenfeld says that
$\frac{n}{\ln n-1/2}$ < $\pi(n)$<$\frac{n}{\ln n-3/2} , n\ge 67$.
Using this inequality we can prove that when $\pi(n)$ divides $n$ (and this happens infinitely often) then
$\pi(n)=\frac{n}{[\ln n-1/2]}$ (for $n\ge 67$)
(By $[\ln n-1/2]$ we denote the integer part of $\ln n-1/2$).
This is an exact formula for $\pi(n)$ that occurs infinitely often.
The question is: Do we have any knowledge about when $\pi(n)$ divides $n$ or anything in this direction?
Thank you for viewing.
Best Answer
Golomb, "On the ratio of $N$ to $\pi(N)$", proves that $N/\pi(N)$ takes every integer value greater than $1$. In particular, this happens infinitely often. The proof is completely elementary, using only that $\pi(N) = o(N)$ and $\pi(N+1)-\pi(N)$ is $0$ or $1$.
Recipe for finding this: Write a line of Mathematica code to find all such $N$ under $200$. Plug the sequence into Sloane's encylcopedia to find A057809. Stumble around the "related sequence" links until I find A038626, which cites Golomb.