3

enter image description here

(Not a mathematician here) I was playing with the gaps $g_n =p_{n+1}-p_{n}$ between first $10^6$ prime numbers, and I made this plot of $(g_n,\;g_{n+1})$ (black dots), and $(g_n,\;g_{n+2})$ (yellow dots). The positions in this plane of a gap with respect to its next gap is interesting and very ordered (black points do not cover all possible positions, but leave holes periodically). This "correlation"(?) is lost for the positions of a gap with respect to its second next (yellow dots cover all positions). Is there a simple explanation?

# in python:
# p : array of first 1e6 prime numbers
import numpy as np
import matplotlib.pyplot as plt
dp = np.diff(p)
plt.plot(dp[:-2], dp[2:], 'y.',ms=15)
plt.plot(dp[:-1], dp[1:], 'k.',ms=7)
scrx2
  • 161

1 Answers1

2

Yes, for $(g_n,\;g_{n+1})$ certain combination always lead to a composite. For example $(4,4)$. Because all primes $\ge5$ are of the form $6\cdot n \pm1 $. For example $(4,4)$ and $6 \cdot n +1$ prime will lead to a $6\cdot n+1+4+4=6\cdot n+9$ and is dividable by 3. When you skip one gap it always possible to get a $6\cdot n \pm1 $ again (As you can see in your graph all 6 multiples horizontal and vertical are black).