Mertens's second theorem states that $$\sum_{p \le x} \frac 1p = \log \log x+O(1).$$ Defining $p_x=p_{\lfloor x \rfloor}$ for all real $x \ge 1$, we can replace the sum by the integral $$\int_1^x \frac 1{p_t} \; dt=\log \log x+O(1)$$ and thus $\frac 1{p_x}$ is on the order of $\frac d{dx} \log \log x=\frac 1{x \log x}$, which simplifies to the prime number theorem. This is clearly not a valid proof, but why not? I suspect that it's in the step from the integral to the expression for $\frac 1{p_x}$, but I don't see why that isn't valid.
Prime Numbers – Why Mertens’s Second Theorem Doesn’t Prove the Prime Number Theorem
analytic-number-theoryprime numbers
Related Solutions
A few years ago, I assigned something a little weaker, $$\sum_{n\le x}{\Lambda(n)\over n}=\log x+r(x){\rm\ with\ }|r(x)|\le2$$ and it turned out to be the hardest problem on the assignment. Here's the proof I eventually wrote up.
Let $s=[x]$. Note $$\sum_{n\le x}{\Lambda(n)\over n}=\sum_{n\le s}{\Lambda(n)\over n}$$ and $0\le\log x-\log s\lt1$. Now
$$\log s!=\sum_{m\le s}\log m=\sum_{p^r\le s}\log p\sum_{m\le s,p^r\mid m}1=\sum_{p^r\le s}\log p[s/p^r]=\sum_{n\le s}\Lambda(n)[s/n]$$
$$=\sum_{n\le s}\Lambda(n)\left({s\over n}-\left\lbrace{s\over n}\right\rbrace\right)=s\sum_{n\le s}{\Lambda(n)\over n}-\sum_{n\le s}\Lambda(n)\left\lbrace{s\over n}\right\rbrace$$
Now $$\sum_{n\le s}\Lambda(n)\left\lbrace{s\over n}\right\rbrace\le\sum_{n\le s}\Lambda(n)\le Cs$$ for some constant $C$ by the Prime Number Theorem (which is actually overkill, as one can prove without PNT that that last sum is bounded by $2s$ for all $s$). Also, comparing $\log s!=\sum\log n$ to $\int_1^s\log t\,dt$ we get $$\log s!=s\log s-s+b(s){\rm\ with\ }|b(s)|\lt\log s+1$$ (cf. Stirling's formula). Putting it together, $$\sum_{n\le x}{\Lambda(n)\over n}=(1/s)\log s!+(1/s)\sum_{n\le s}\Lambda(n)\left\lbrace{s\over n}\right\rbrace=\log s-1+C+b(s)/s=\log x+r(x)$$ with $|r(x)|\le2$ since $C\le2$.
EDIT: The stronger result is proved in the textbook by Bateman and Diamond, Analytic Number Theory, pages 100-102. First they prove that, with the usual definitions, $\psi(x)\sim x$ implies $M(x)=o(x)$, where $M(x)$ is the summatory function for the Möbius $\mu$-function. Then from the result on $M(x)$ they deduce the result you want. It's a bit long to write out as I'd have to explain the notation introduced earlier in the chapter.
MORE EDIT: It's also Proposition 3.4.4 of Jameson's textbook, The Prime Number Theorem, and it's proved on page 91 of Tenenbaum and Mendes France, The Prime Numbers and Their Distribution, in the Student Mathematical Library series of the American Math Society. Again, the proofs require too much previously developed material for me to attempt to write them out here.
Not a full explanation, but it is too long for a comment.
Consider the Sieve of Eratosthenes.
Start with the first $n$ numbers. Remove (one less than) $\frac 12$ of them as multiples of $2$, Of the remainder, remove $\frac 13$ of them as multiples of $3$. Of the remainder, remove $\frac 15$ as multiples of $5$, etc. You should be left with about $$n\prod_{p\le n, \text{ prime}}1 - \frac 1p$$
values as primes below $n$. Now, when multiplied out
$$\prod_{p\le n, \text{ prime}}1 - \frac 1p = 1 - \sum_{k \in S_n} \frac 1k$$ Where $S_n$ is the set of all square-free integers $> 1$ whose prime factors are $\le n$.
It remains to estimate that $1 - \sum_{k \in S_n} \frac 1k\approx \frac 1{\log n}$.
Edit:
Since it was already chosen as the solution and Winther has kindly provided Merten's 3rd theorem which says just what was needed, I could just let this go. But Merten's theorem strikes me as hardly more intuitively obvious than the prime number theorem itself, so I've been thinking on heuristic concepts to explain it.
Now for $|x| < 1$, $\frac1{1-x} = 1 + x + x^2 + ...$ Therefore $$\frac 1{\prod\limits_{p\le n}1 - \frac 1p} = \prod\limits_{p\le n}\left(1 + \frac 1p + \frac 1{p^2} + ...\right)$$
Multiplying the right side out, we get $\sum_{k \in R_n} \frac 1k$, where $R_n$ is the set of all integers whose prime factors are all $\le n$. Of these, it should be expected (I'm being heuristic here, so I can get away with that weasel-wording) that the sum for $k > n$ will be significantly smaller than for $k \le n$. Thus it seems reasonable that $$\sum_{k \in R_n} \frac 1k \sim \sum_{k \in R_n, k\le n} \frac 1k = \sum_{k=1}^n \frac 1k \sim \log n$$
Best Answer
The prime number theorem, as proved by de la Vallée-Poussin, states that \[\pi(x) = \sum_{p \leq x} 1 = \mathrm{Li}(x) + O\left(xe^{-a\sqrt{\log x}}\right),\] where \[\mathrm{Li}(x) = \int_2^x \frac{dt}{\log t} \sim \frac{x}{\log x}.\] Mertens' second theorem is sometimes stated as \[\sum_{p \leq x}\frac{1}{p} = \log \log x + M + o(1),\] but the result that Mertens proved is actually slightly stronger, namely that there exists a constant $M$, the Meissel-Mertens constant, such that \[\sum_{p \leq x}\frac{1}{p} = \log \log x + M + O\left(\frac{1}{\log x}\right).\] To get from $\sum_{p \leq x} \frac{1}{p}$ to $\sum_{p \leq x} 1$, one uses partial summation, which is the rigorous way of a replacing a sum by an integral. This states that if $c_n$ is a series of complex numbers and $f(n)$ is a differentiable function, then \[\sum_{n \leq x} c_n f(n) = C(x) f(x) - \int_{1}^{x} C(t) f'(t) \, dt,\] where \[C(x) = \sum_{n \leq x} c_n.\] So if $c_n = 1/p$ if $n = p$ is a prime and $0$ otherwise, and if $f(n) = n$, then this gives \[\sum_{p \leq x} 1 = x \sum_{p \leq x} \frac{1}{p} - \int_{e^2}^{x} \left(\sum_{p \leq t} \frac{1}{p}\right) \, dt + O(1).\] Here I've changed the endpoints on the integral on the right-hand side, which leads to a change by a constant. Using Mertens' second theorem shows that the integral on the right-hand side is \[\int_{e^2}^{x} \left(\sum_{p \leq t} \frac{1}{p}\right) \, dt = \int_{e^2}^{x} \log \log t \, dt + \int_{e^2}^{x} M \, dx + O\left(\int_{e^2}^{x} \frac{dt}{\log t}\right).\] Using integration by parts, one can show that \[\int \log \log x \, dx = x \log \log x - \mathrm{Li}(x) + C,\] and so combining everything, we get \[\sum_{p \leq x} 1 = x \left(\sum_{p \leq x} \frac{1}{x} - \log \log x - M\right) + O(\mathrm{Li}(x)) = O\left(\frac{x}{\log x}\right)\] where the last step follows by Mertens' second theorem again. So we just fall short of the prime number theorem. Indeed, if we had the slightly stronger statement that \[\sum_{p \leq x}\frac{1}{p} = \log \log x + M + o\left(\frac{1}{\log x}\right),\] then we can use partial summation to prove the prime number theorem.