# Using the 2nd Chebyschev function for describing sums of primes

The question is as follows:

Show that for any $n\ge1$, we have $$\psi(n)=\sum_{p\ge n}\left \lfloor\frac{\log n}{\log p}\right \rfloor \log p$$ where $\psi(x)=\sum_{p^m\le x}\log p$, where the sum ranges over all prime powers that are at most $x$, and $\psi(x)$ can be written as $\psi(x)=\vartheta(x)+\vartheta(x^{1/2})+\vartheta(x^{1/3})+...$ , and $\vartheta(x)=\sum_{p\le x}\log p$.

There is a section prior to this where I had to show that $\psi(n)\le 2\log 2\cdot n+2n^{1/2}\log n$ for any $n\ge1$

In essence, I think I want to find the $m$ such that $p^m\le n$ where $p$ is prime and $n\in\mathbb N$.

This is what I've done so far: $m\log p\le\log n \Rightarrow m\le\frac{\log n}{\log p}\Rightarrow m=\left\lfloor\frac{\log n}{\log p}\right \rfloor$ since $m \in\mathbb Z$, using what I think above.

Does anyone know where I go from here to show the $\psi(n)$ summation, or if I've got the complete wrong idea of the question?

Any help would be greatly appreciated.