TITLE: Is there a monotonic $f$ such that $\sum f(n)$ diverges but $\sum f(p)$ converges?
QUESTION [10 upvotes]: (where the former summation is over natural numbers $n$ and the latter is over prime numbers $p$, and $f: \mathbb{N} \to \mathbb{R}$ is a monotonic function.)
For the class of functions $f_s(n) = \frac 1 {n^s}$, the sum over the primes converges iff the sum over $\mathbb{N}$ does (and this question perturbs this class of functions by asking about the case $f(n) = \frac 1 {n^{1+\frac 1 n}}$, but again both sums diverge). Indeed, the fact that $\sum \frac 1 p$ diverges is often viewed as a strengthened version of the fact that there are infinitely many primes, saying that the primes are "not too far" from being dense in $\mathbb{N}$.
But since the primes are not dense in $\mathbb{N}$, I'd expect that there should be reasonable functions $f$ whose sum over the primes converges while the sum over $\mathbb{N}$ diverges. (The monotonicity condition I've imposed on $f$ is meant to rule out "stupid" examples such as the characteristic function of the composite numbers. But if there are "non-stupid" non-monotonic examples, I'd be interested to hear about that too.)
I haven't thought about this question enough to see whether the prime number theorem will be all that matters or whether more refined information will be relevant.

REPLY [4 votes]: If you let $f(n)=\frac{1}{p_n}$, where $p_n$ is the $n$th prime, the sum on the reciprocals of the primes:
$$
\sum_{k=1}^\infty{\frac{1}{p_k}}
$$
Diverges, but for $f(p_n)$ the sum over the reciprocal of the super-primes:
$$
\sum_{k=1}^\infty{\frac{1}{p_{p_k}}}=.958...
$$
Converges, as well as the function being strictly decreasing.