[Math] A counting problem related to twin primes

nt.number-theoryprime numbers

Update:

The chat room for this question: http://chat.stackexchange.com/rooms/69953/discussion-between-fedja-and-abiessu

The problem statement remains unchanged (below).


Consider the following problem:

Given the following sets with $u \in\Bbb Z^+$: $$\begin{align}A_u&=\{x^2:x\in [2^{u-1},2^u-1],\exists s,t \in\Bbb Z^+ : x^2=s^3+2s^2+st+t\}\\B_u&=\{x^2:x\in [2^{u-1},2^u-1],\exists s,t \in\Bbb Z^+ : x^2=2s^3+2s^2+2st+t\}\end{align}$$

prove that $\exists N\in\Bbb Z^+$ such that $\forall u\gt N, |A_u|\ge|B_u|$.

Edit: it has been pointed out that this problem directly correlates with the Twin Primes conjecture. This does not change the question.

My approach is to rearrange the specifier equations as follows (using $s_A,t_A,s_B,t_B$ to differentiate the sets):

$$x^2=(s_A+1)(s_A^2+t_A)+s_A^2\\
y^2=(2s_B+1)(s_B^2+t_B)+s_B^2$$

From here, it is almost "obvious" that the problem statement should be correct, and I take the path of letting $s_A=2s_B$ for all but $s_A=1$ and comparing counts of values for each such pairing. Once I have counted all the differences where $s_A=2s_B$, then I go back and count all the overlaps between $s_A=1$ and $s_A\gt 1$. When all of this is done, I get a value $N=45$ (which I am certain could be improved).

Is there a more effective or efficient approach? With such an "obvious" problem statement, it seems like there should be an easier way to get the required results…

Addendum:

I glossed over the details above, but the counting of actual results goes like this: for each value of $s_A=2s_B$ where $s_A+1$ is prime, there are exactly two possible solutions of the congruence $s_A^2\equiv x^2\pmod{s_A+1}$, and there are exactly two possible solutions of $s_B^2\equiv x^2\pmod{2s_B+1}$. These solutions exist for both congruences. Therefore the arithmetic sequences in $t_A,t_B$ given by $(s_A+1)t_A+(s_A+2)s_A^2$ and $(2s_B+1)t_B+(2s_B+2)s_B^2$ each produce the same number of values $x^2,y^2$ within a given interval whenever $s_A+1=2s_B+1$, up to a maximum difference of two values produced (per prime value $s_A+1$). The squarefree non-prime values of $s_A+1$ account for double-counted values, and if we account all the "maximum difference of two" possibilities in favor of $B_u$, we should effectively count the number of values that $s_A\gt 1$ can take on which affect the given interval and multiply it by $2$ as the "worst case" for the value of $|B_u|$. For the overlap counting between $s_A=1$ and $s_A\gt1$, we account for the "worst case" by taking the fact that $s_A+1=2$ covers all odd squares within any interval for $u\gt 5$, then multiply this result by all the overlap possibilities for each prime greater than $2$ up to the maximum possible value of $s_A+1$ as $\left(1-\frac 23\right)\left(1-\frac 25\right)\dots\left(1-\frac 2p\right)$, at which point we apply the result

$$\left(\prod_{p=3}^n\left(1-\frac 2p\right)\right)^{-1}=\frac 14e^{2\gamma}\Pi_2^{-1}\log^2n+O\left(e^{-c\sqrt{\log n}}\right)$$

(from https://math.stackexchange.com/a/22435/86846).

This question is cross-posted from Math.SE (https://math.stackexchange.com/q/2521575/86846) following an intense period of no activity whatsoever.

Best Answer

This is just to explain to everyone what is going on here.

The conditions are just $s+1|x^2-s^3-2s^2$ and $(2s+1)|4x^2-8s^3-8s^2$ (plus the positivity of the expressions on the right, i.e., roughly speaking, the inequality $s<x^{2/3}$).

Since $y^3\equiv -1$ and $y^2\equiv 1\mod y+1$, the divisibility conditions are just $s+1|x^2-1=(x-1)(x+1)$ and $2s+1|4x^2-1=(2x-1)(2x+1)$. Thus the numbers not in $A_u$ are those for which there are no divisors between $2$ and $x^{2/3}$ of either $x-1$ or $x+1$, i.e. those for which $x-1$ and $x+1$ is a twin prime pair. Similarly the numbers not in $B_u$ are the ones for which $2x-1$ and $2x+1$ is a twin prime pair. Since the complement of a larger set is smaller, we conclude that there are at least as many twin prime pairs $2x-1,2x+1$ as twin prime pairs $x-1,x+1$, when $x$ runs over $[u,2u-1]$, which is equivalent to saying that there are at least as many twin prime pairs in $[2u-1,4u-1]$ as in $[u-1,2u-1]$, so once we have at least one pair above $N$, we have it in every dyadic interval above that point giving the logarithmic growth of $\pi_2(n)$ at least.

Related Question