# Number of primefactors in $f(n,W) = \prod_{k=1}^W (p_k^n -1) \text{ where } p_k=Prime(k)$

I'm reviving an old fiddling, although I do not yet really see its benefit. Beginning with the eulerproduct for the zeta-function in the representation $\small \zeta(n)=\prod {1\over 1-p^{-n} } = \prod {p^n \over p^n-1 }$ I asked whether it might be meaningful to try to find an asymptotic expression for the occurences of primefactors in the denominator, depending on the number W of Eulerterms and then exponent n. So I define $$\ z(n,W) = \prod_{k=1}^W p_k^n - 1 \qquad p_k \in \mathbb P$$ and count the primefactors $\small q_k$ (with multiplicity) in $$\small z(n,W) = q_1^{a_{1,n}} q_2^{a_2} q_3^{a_3} \ldots$$ Of course this is increasing with W and erratically. But due to the randomness and seemingly uniform distribution of the primes with respect to their moduli to any primes I seem to get meaningful constants for the first few, say 20, primes $\small q_k$ when W goes to 10000 or to 100000 and I evalute their relative frequencies $\small z(n,W)/W$.
I get the provisorical formula for the exponents of the primefactors $\small q_k \gt 2$ $${a_{k,n}\over W} \sim gcd(n,q_k-1)\cdot {q_k + (q_k - 1)\{n,q_k\} \over (q_k -1)^2}$$ where the bracketed expression means "exponent of primefactor $\small q_k$ in n "

My first question is: can this be justified? If I understand things correctly, this would require, that the primes are not only equally distributed modulo any prime, but even modulo any prime-power, and in general completely "symmetric" , just like $\small \mathbb N$ it self.

My second question concerns the primefactor $\small q_1 = 2$ Here I concluded from the achieved numerical evidence, that the same formula is asymptotically valid with a small correction
$${a_{k,n}\over W} \sim gcd(n,q_k-1)\cdot {q_k + [2|n]+ (q_k - 1)\{n,q_k\} \over (q_k -1)^2} = 2 + [2|n] + \{n,2 \}$$ where the iverson-bracket $\small [2|n]$ evaluates to 1 or 0 depending on whether 2 divides n or not. From the construction of the whole expression it looks reasonable under the hypothese, that the distribution of primes (mod 2), (mod 4), (mod 8) etc is also "symmetric" in the long run. But after a closer look it seems, that there is a nonneglectable small error of 2% say: for W=10000 I expect for exponent n=1 $\small a_1=20000$ but empirically 46 are missing; for W=20000 I get 96 missing and for W=30000 I get 127 missing. (Some more example in that region for W suggest, that this is not a fluctuation around a zero-error, but has a bias)

Question 2: Is there some systematic reason for that bigger error with the primefactor 2? And if, what would be a better aymptotic formula/formula for the relative frequency of that primefactor?

table for relative frequencies of primefactors q_k( horizontal) and n (vertical), scaled by $\small (q_k-1)^2$, rounded to integers, based on the first W=60000 terms of the Eulerproduct: $$\small \begin{array} {r|rrrrrr} n & 2 & 3 & 5 & 7 & 11 & 13 & 17 & 19 & \text{ primefactors } q_k \\ \hline \\ 1 & 2 & 3 & 5 & 7 & 11 & 13 & 17 & 19 \\ 2 & 4 & 6 & 10 & 14 & 22 & 26 & 34 & 38 \\ 3 & 2 & 5 & 5 & 21 & 11 & 39 & 17 & 57 \\ 4 & 5 & 6 & 20 & 14 & 22 & 52 & 68 & 38 \\ 5 & 2 & 3 & 9 & 7 & 55 & 13 & 17 & 19 \\ 6 & 4 & 10 & 10 & 42 & 22 & 78 & 34 & 114 \\ 7 & 2 & 3 & 5 & 13 & 11 & 13 & 17 & 19 \\ 8 & 6 & 6 & 20 & 14 & 22 & 52 & 136 & 38 \\ 9 & 2 & 7 & 5 & 21 & 11 & 39 & 17 & 171 \\ 10 & 4 & 6 & 18 & 14 & 110 & 26 & 34 & 38 \\ 11 & 2 & 3 & 5 & 7 & 21 & 13 & 17 & 19 \\ 12 & 5 & 10 & 20 & 42 & 22 & 156 & 68 & 114 \end{array}$$ For instance the primefactor $\small q_3=5$ occurs asymptotically in 10 of $\small (5-1)^2 =16$ cases, or, if W=16000 for the denominator of the partial Eulerproduct with exponent 2, then we'll have about $\small 10 \cdot W/16 = 1000$ occurences of the primefactor 5.

I've put this question also with a bit more better(?) explanation in mathoverflow and have received one answer (which does however not cover the whole question)

-
 @anon: Ah, thanks - corrected. – Gottfried Helms Oct 25 '11 at 13:26