Properties of the remainders from division into primes

407 Views Asked by At

This is a question that has bothered me for almost 6 years now on and off, and I still don't really know enough to tackle it.

To phrase it somewhat formally:

Let $P$ be the series of prime numbers such that $P(i)$ is the i-th prime number.

Let $N$ be a positive integer with a value greater than $2$.

Let $X$ be the series of numbers such that $X(0) = 0$ and $X(i) = (X(i - 1) + P(i)) \pmod N$

Does there exist an $N$ for which the set of elements $X(0),\ldots,X(N-1)$ contain every number from $0$ to $N-1$ exactly once? Can we prove it one way or another?

I've made computer simulations and let them run overnight and the results seem to suggest that no, there is no such N, but the graphs I got out of doing this are fairly interestingly shaped.

For instance, this is a scatter plot where the $x$-axis is $N$ and the $y$-axis is the percent of numbers in $X(0), \ldots, X(N-1)$ that were reached before a duplicate. Proportions

And if we zoom in we can see some definite "structure" to the proportions, which is also interesting. Zoomed in

And on the long tail there seems to be a definite "range", with some outliers

Long tail I don't know how to explain why the graph is shaped like it is, or what the structure in it means, or why it seems like a "thick" logarithmic curve. The shape would seem to imply.

Also interestingly, the minimum proportion seems to approach ~0.0001592, which I have no clue the significance of.