3
$\begingroup$

I was checking this number theory exercise:

The numbers $11, 13, 17, 19$ are four odd integers ending in $1, 3, 7, 9$ that lie between two multiples of $10$. Find the next such set of prime numbers ending in $1, 3, 7, 9$.

By trying several numbers I found the answer is $101,103,107,109$ but I have been unable to find such numbers by a mathematic approximation or a different way.

If you have another way it will be really appreciated.

$\endgroup$
  • 1
    $\begingroup$ oeis.org/A007530 $\endgroup$ – JMoravitz Sep 8 '18 at 20:43
  • $\begingroup$ Well, by looking only divisibility by $3$, we can immediately throw out the $2/3$ of possibilities, leaving only $41,\dots$, then $71,\dots $ and $101,\dots$. $\endgroup$ – Berci Sep 8 '18 at 20:44
2
$\begingroup$

The best optimization you can do by elementary means is to note that, like Berci said, with one exception, all these prime quadruples surround odd multiples of 15.

Algebraically, given $n \equiv 15 \pmod{30}$, we have $p = n - 4$, $p + 2 = n - 2$, $p + 6 = n + 2$ and $p + 8 = n + 4$.

So then there's no point in checking the 20s, because 21 is a nontrivial multiple of 3. Nor the 30s, for, even though 31 is prime, 33 is a nontrivial multiple of 3.

But do look at the 40s: we have 41, 43, 47... oh, dang, $49 = 7^2$. Actually, this suggests one other optimization, to swap 30 out for 210.

Then $n$ can be $15, 105, 195 \pmod{210}$. Looking at Sloane's http://oeis.org/A007530, you will see that except for 5, the lowest number $p$ of the prime quadruple is $11, 101, 191 \pmod{210}$.

$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.