# Does this infinite primes snake-product converge?

Form an infinite product of prime ratios as follows. Start with $$\frac{2}{3}\cdot\frac{7}{5}=\frac{14}{15} \approx 0.93 \;.$$ Continue alternating a fraction $$< 1$$ times the next fraction $$>1$$, progressively through the primes: $$\frac{2}{3}\cdot\frac{7}{5}\cdot\frac{11}{13}\cdot\frac{19}{17} = \frac{2926}{3315} \approx 0.88 \;,$$ $$\frac{2}{3}\cdot\frac{7}{5}\cdot\frac{11}{13}\cdot\frac{19}{17}\cdot\frac{23}{29}\cdot\frac{37}{31} =\frac{2490026}{2980185} \approx 0.83 \;.$$ Continue this process to $$\infty$$. One way to write the product is $$\xi = \prod_{1,5,9,\ldots}^\infty \frac{p_i}{p_{i+1}}\cdot\frac{p_{i+3}}{p_{i+2}}$$ where $$p_i$$ is the $$i$$-th prime. I call this the primes snake-product: My questions are:

Q1. Does the product converge?

Q2. If so, to what value $$\xi$$ does it converge?

Up to the $$1$$-millionth prime ($$15485863$$), the product is about $$0.9056$$: Update (26Jan2019): @Peter has calculated out to $$p_i=10^{10}$$ when the product is $$\approx 0.9048$$.

• Using the prime number theorem as an approximation, if you set $p_n=n\ln(n)$, does your product converge? – quarague Jan 25 '19 at 11:55
• $10^8$ th prime : $$0.90482881546\cdots$$ – Peter Jan 25 '19 at 15:19
• You could prove that the value of $\prod_{i=1}^{\infty} \frac{p_{2n-1}}{p_{2n}} = P$ converges. Then, you can easily see that $P < \xi < \frac{1}{P}$, which would show that your product converges. – Haran Jan 25 '19 at 16:58
• @Haran: But perhaps $P=0$, and I'd be left with $0 < \xi < \infty$. – Joseph O'Rourke Jan 25 '19 at 21:20
• Since (as I note above) the products of $\frac{p_i}{p_{i+1}}$ and of $\frac{p_{i+3}}{p_{i+2}}$ do not converge absolutely, we are lead to considering cancelations between the terms. This is closely related to asymptotics of alternating sums of primes, of which we have only a limited understanding. See this MO question. I will elaborate in an answer. – Wojowu Jan 26 '19 at 11:57

Let $$g_n=p_{2n}-p_{2n-1}$$. The product we are looking at is then $$\prod_{n=1}^\infty\left(1-\frac{g_n}{p_{2n}}\right)^{(-1)^n}.$$ Taking logarithms, we are met with a sum of the form $$\sum_{n=1}^\infty\left((-1)^{n-1}\frac{g_n}{p_{2n}}+O\left(\left(\frac{g_n}{p_{2n}}\right)^2\right)\right).$$ Using results due to Heath-Brown on second moments on prime gaps (see here), namely $$\sum_{k=1}^ng_k^2=O(x^{7/6+\varepsilon})$$, by summation by parts we can bound the sum of the error terms by a finite value.
Hence we are left with an alternating sum of $$g_n/p_{2n}$$. To deal with this, we essentially have to show the sums $$\sum_{n=1}^N(-1)^{n-1}g_n$$ are asymptotically smaller than $$p_{2N}$$ (this won't guarantee convergence, but we definitely want that to hold). Using the notation of this MO answer (and the paper it cites), this sum is equal to $$S(2N;1,4)-S(2N;3,4)$$. What we would like to know is that this difference is $$o(p_{2N})$$. So you see we are quickly lead to investigating asymptotics of $$S(N;a,q)$$. Conjecturally, we have $$S(N;a,q)\sim\frac{p_N}{q}$$ (so that the gaps are in some sense equidistributed), but available bounds are much weaker. In the cases we are interested in, we only get $$\liminf\frac{S(N;a,4)}{p_N}\geq\frac{1}{256}$$ unconditionally, and even conditionally on prime tuples conjecture we get $$\geq 1/32$$, while what we would like is for the limits to exist and be equal.
Hence, as you can see, the available methods are not capable of showing that the difference $$S(2N;1,4)-S(2N;3,4)$$ is asymptotically small.
• @JosephO'Rourke Not really, no. It should follow from suitable error term estimates for $S(N;a,q)$, but I'm not aware of such conjectures. I haven't exactly checked the references in the linked answer, you might want to look there. – Wojowu Jan 26 '19 at 13:29
• One of the strongest conjecture for the prime gap is that $g(n),n \in [N,2N]$ looks like a random variable $G_N$ with $P(G_N > a\log N) = e^{-a} \log N$ and you are essentially asking $g(n)$ to be at least slightly independent in $n$ @JosephO'Rourke – reuns Jan 27 '19 at 21:44