Pattern in product of primes

95 Views Asked by At

Let $p_n$ denote the $n$th prime i.e. $p_1 = 2, p_2 = 3, p_3 = 5 ....$ Can we find a pattern in the finite sequence $a_m = \prod_{j=1~j\neq i}^{k}{p_{j}} ~~( \text{mod} ~p)$ for a fixed $j$ and some finite $k$?

For example, let $j =3$ and $k = 10.$ Then $$2 (\text{mod 5}) =2$$ $$2\cdot3 (\text{mod 5}) =1$$ $$2\cdot3\cdot7 (\text{mod 5}) =2$$ $$2\cdot3\cdot7\cdot11 (\text{mod 5}) =2$$ $$2\cdot3\cdot7\cdot11\cdot13 (\text{mod 5}) =1$$ $$2\cdot3\cdot7\cdot11\cdot13\cdot17 (\text{mod 5}) =2$$ $$2\cdot3\cdot7\cdot11\cdot13\cdot17\cdot19 (\text{mod 5}) =3$$ $$2\cdot3\cdot7\cdot11\cdot13\cdot17\cdot19\cdot23 (\text{mod 5}) =4$$ $$2\cdot3\cdot7\cdot11\cdot13\cdot17\cdot19\cdot23\cdot29 (\text{mod 5}) =1$$

The sequence $a_n$ is $2,1,2,2,1,2,3,4,1...$ Is there any pattern?

1

There are 1 best solutions below

0
On

Closest you'll get is $-2ab-a-b+2 \bmod 5$ That's from the sieve of sundaram. After about the fifth round $a$ and $b$ will take on a similar form. Not much else to say. at least That's the form of this sequence.