Prime number theorem, proof error Can someone help me find where I made an error in this attempted proof
And from there, give me some advice on what I can do to fix it
$$M(x)=\sum_{n\leq x}\mu(n)$$
$$\psi(x)=\sum_{n\leq x}\Lambda(n)=\sum_{n\leq x}\ln(n)*\mu(n)=\sum_{n\leq x}\ln(n)M{\left(\frac{x}{n}\right)}$$
$$\ln(x)=\sum_{n\leq x}\ln(x)\delta_{n,1}=\sum_{n\leq x}\ln(x)(1*\mu(n))=\sum_{n\leq x}\ln(x)M\left(\frac{x}{n}\right)$$
So that,
$$\psi(x)-\ln(x)=\sum_{n\leq x}\ln\left(\frac{n}{x}\right)M\left(\frac{x}{n}\right)$$
$$\lim_{x\to\infty}\frac{\psi(x)}{x}=\lim_{x\to\infty}\frac{1}{x}\sum_{n\leq x}\ln\left(\frac{n}{x}\right)M\left(\frac{x}{n}\right)=\lim_{x\to\infty}\sum_{n\leq x}\frac{1}{x}\ln\left(\frac{n}{x}\right)M\left(\frac{1}{\left(\frac{n}{x}\right)}\right)$$
So that, 
$$\lim_{x\to\infty}\frac{\psi(x)}{x}=\int_{0}^1\ln(x)M\left(\frac{1}{x}\right)dx=\int_{1}^\infty\frac{-\ln(x)M(x)}{x^2}dx$$
But by the mellin transform for the mertens function we have that,
$$\frac{1}{s\zeta(s)}=\int_{1}^\infty\frac{M(x)}{x^{s+1}}dx$$
$$\implies-\frac{\zeta'(s)}{s\zeta(s)^2}-\frac{1}{s^2\zeta(s)}=\int_{1}^\infty\frac{-\ln(x)M(x)}{x^{s+1}}dx$$
$$\implies1=\int_{1}^\infty\frac{-\ln(x)M(x)}{x^2}dx$$
And so, $$\lim_{x\to\infty}\frac{\psi(x)}{x}=1$$
 A: The first equation RHS and LHS is according Mertens himself and fine:
$$\psi(x)=\sum_{n\leq x}\ln(n)M{\left(\frac{x}{n}\right)}$$
But the second equation, to be cautious:
$$\ln(x)=\dots=\sum_{n\leq x}\ln(x)M\left(\frac{x}{n}\right)$$
because
$$\psi(x)\ne \ln(x)$$
Why not using Stirling's formula (up to $O(\ln(N))$) then see further.
A: As pointed in the comment, you have to prove that the function $M(1/x) \ln(x)$ is Rieman-integrable, but it is not since Riemann-integrable (on a compact interval) is equivalent to bounded and continuous almost everywhere (cf Wiki). I don't know if this can be salvaged by using the fact that you have a specific Riemann sum.
Moreover, to prove that
$$(1) \quad \lim_{s \to 1} \int_1^\infty \frac{\ln(x)M(x)}{x^{s+1}} dx = \int_1^\infty \frac{\ln(x)M(x)}{x^2} dx,$$
you will have to show that $|M(x)|=O(x^{1-\delta})$ some $\delta>0$, which is almost equivalent to the fact that $\zeta$ has no zero in $\{ Re> 1-\delta \}$ (I think no such $\delta$ has been proved to exist).
A: In my comment, I just introduced your first equation (Mertens) into the fifth equation RHS. You will then get my equation above. Then I do not see a clear justification how to come from my equation above (taking $\mu$ and $n$ behaviour into account) to your first and then (!!) second integral. I feel you are trying in this step to run Perron's formula, but cannot follow the detailed steps. In this step practically you try to mimic a (semi-)Mellin transform. Later you set up the comonly known Mellin transform of the Chebychev function again (via $\zeta$), and compare and wonder about the result. The first semi-Mellin transform has a worm.
If you really want to strictly go for this step (from sum to integral), suggest you write out all in very detail and diligently and use the precise formalism of Perron. The final result in its essence is interesting and I thing probably you will get somthing new. What I found in an own theorem is that $\psi(x) < 3.6757575...$.
