# Is the asymptotic density of powers of primes zero?

For $A \subseteq \mathbb{N}$, we define the asymptotic density of $A$ to be the following limit (if it exists):

$$d(A) = \lim_{n \rightarrow \infty} \frac{|A \cap \{1, 2, \ldots n\}|}{n}$$

By the prime number thm, the asymptotic density of all the primes is zero. I have been wondering about the following question. Is the asymptotic density of $A = \{p^k: \text{$p$prime,$k \geq 0$integer}\}$ also zero? Intuitively I think we should have $d(A) = 0$, as the gaps between powers of primes get larger and larger.

I think for fixed $k$, we have $d(A_k) = 0$ for $A_k = \{p^k : \text{$p$prime} \}$. Maybe if we had subadditivity for density, this would prove $d(A) = 0$ by

$$d(A) = d(\bigcup_{k = 0}^\infty A_k) \leq \sum_{k = 0}^\infty d(A_k) = 0$$

Does asymptotic density have this property?

Asymptotic density is not countably subadditive since for all $n\in{\Bbb N}$, $d(\{n\})=0$ but $d(\cup_n \{n\})=d({\Bbb N})=1$. It is finitely subadditive in the sense that if $d(S)$, $d(T)$, and $d(S\cup T)$ all exist, then $$d(S\cup T)\le d(S)+d(T).$$ Also, if $d(S)=d(T)=0$, then $d(S\cup T)=0$.
If $P$ is the set of primes and $Q$ is the set of powers (squares, cubes, etc.), then $A\subseteq P\cup Q$. As you point out, $d(P)=0$, and the size of $Q\cap\{1,\dots,n\}$ is at most $$\sqrt{n}+n^{1/3}+\cdots+n^{1/k}, \qquad (*)$$ where $k$ can be taken to be the largest integer such that $n\ge 2^k$. Since $k\le \log_2 n$ and each term in the sum (*) is at most $\sqrt{n}$, the quantity (*) is at most $\sqrt{n} \log_2 n$. As $$\lim_n \frac{\sqrt{n} \log_2 n}{n}=0,$$ this proves that $d(Q)=0$. Therefore, $d(A)=0$.