3
$\begingroup$

For how many primes $p$ is $p^2 + 2$ also prime?

I'm not sure but I think you can consider every prime number as $(3k+1)$ or $(3k+2)$

$\endgroup$
  • $\begingroup$ You can consider every prime number $\geqslant 5$ as $6k+1$ or $6k-1$, which is really the same thing, so you're right $\endgroup$ – Mr Pie Apr 12 '18 at 15:23
  • $\begingroup$ It's always a good idea to write out examples. I think you'll quickly see a common factor to all such numbers. (well, $p\neq 3$ anyway). $\endgroup$ – lulu Apr 12 '18 at 15:28
  • $\begingroup$ Approach0 is a better search engine than the on-site search when you need to include TeX-snippets. $\endgroup$ – Jyrki Lahtonen Apr 12 '18 at 16:39
5
$\begingroup$

A prime of the form $p=6k+1$ results in $$p^2+2=36k^2+12k+3=3 \times (12k^2+4k+1) $$ which is clearly divisible by $3$.

While $p=6k-1$ results in $$p^2+2=36k^2-12k+3=3 \times (12k^2-4k+1)$$ which is again divisible by $3$.

So no prime $p \ge 5$ gives $p^2+2$ as a prime too. You can check for $p<5$ easily. Turns out that $3$ satisfies this. Which is only such prime.

$\endgroup$
  • $\begingroup$ Yeh thx, that means that only 3 is the answer $\endgroup$ – Andrei Rk Apr 12 '18 at 15:30
  • $\begingroup$ @AndreiRk Yes, you are correct $\endgroup$ – Jaideep Khare Apr 12 '18 at 15:32
  • $\begingroup$ @JaideepKhare Can you give me some references for this kind of elementary number theory ? Thanks ! $\endgroup$ – Learning Apr 12 '18 at 16:21
  • 1
    $\begingroup$ I did pretty much the same as you did but your answer targets the question more :) $\endgroup$ – Mr Pie Apr 12 '18 at 17:12
  • $\begingroup$ @PrithiviRaj I would recommend you to see examples of an elementary number theory book. For instance, there is a book by Arihant Publications, written by Rajeev Manocha, a book for INMO. It covers Number Theory as well as Inequalities, Geometry, Combinatorics etc. If you read the examples and solve its exercises, you'll get to know a lot of interesting stuff and new techniques to solve questions, even a lot harder than this one! (There are a lot of books out there, but this is the one I read ^_^) $\endgroup$ – Jaideep Khare Apr 12 '18 at 17:23
4
$\begingroup$

You don't need to consider cases. Clearly $p=3$ is only one solution less than or equal $3$. Assuming now $p>3$, we have $3 \nmid p$ and by Fermat's Little Theorem $p^2+2\equiv 1+2\equiv 0 \pmod {3} $, a contradiction. So $p=3$ is the only solution.

$\endgroup$
4
$\begingroup$

Assume $p=3k+1$ or $p=3k+2$ ($k$ is a natural number).

  • If $p=3k+1$ then $p^2+2=9k^2+6k+3$, divisible by $3$.

  • If $p=3k+2$ then $p^2+2=9k^2+12k+6$, divisible by $3$.

For every positive integers $k\ge1$ (this makes $p^2+2>3$), if $p$ is not divisible by $3$ then $p^2+2$ is divisible by $3$, this can't be true because $p^2+2$ is a prime number.

This makes $k=0$, then $p=2$ because $p$ is a prime number. If $p=2$ then $p^2+2=6$, this is not a prime number.

Because of all the above, $p=3k+1$ and $p=3k+2$ are incorrect, so we eliminated them entirely and $p$ must be divisible by $3$.

We conclude that $p=3$ is the only solution (as $p^2+2=11$).

$\endgroup$
  • $\begingroup$ Looking at your expressions for $p^2+2$ in terms of $k$, it's clear that $k=1$ doesn't need to be a special case. $\endgroup$ – Joffan Apr 12 '18 at 16:28
  • $\begingroup$ @Joffan Thanks for noticing, if you use $p^2+2$ instead of $p$ prime, you can eliminate an extra choice, which is $k=1$. $\endgroup$ – user061703 Apr 12 '18 at 16:35
3
$\begingroup$

The square of any integer is either 0 or 1 mod 3. If $p^2$ is 1 mod 3, then $p^2 +2$ is divisible by 3. If it is 0 i.e. $3|p^2 $ then $3|p$ and $p=3$ is the only solution.

$\endgroup$
3
$\begingroup$

We will not consider $p=2$ because $2^2+2=6$ which is obviouly not prime.


Most definitely $p\neq n^2 + 1$ for all odd $p$ because if we assume otherwise, we want $$(n^2+1)^2+2=n^4+2n^2+3$$ to be prime. Therefore $3\nmid n$. (The only prime divisible by $3$ is $3$ itself, so $n=0$ is a solution, but note that $0^2+1=1$ which is neither prime nor composite.) Every prime is of the form $3k+1$ or $3k+2$, so if $p=n^2+1$ then $p\neq 3k+1$ and thus $p= 3k+2$. $$\begin{align}\therefore n^2+1&=3k+2 \\ \Leftrightarrow 3k&=n^2-1 \\ &=(n+1)(n-1).\end{align}$$ Since $$(n+1)-(n-1)=2<3$$ then $3\mid n+1$ or $3\mid n-1$ but not both. $$\therefore n = 3l+1\text{ or } 3l-1$$ which when we substitute, we get that $3\mid p^2+2$ for all odd $p = n^2+1$.


It is also provable by induction that $3\mid n^4 + 2n^2$ for all integers $n$. The same result is thus implied.

$\endgroup$
2
$\begingroup$

For $p=2$ we get $$p^2+2=6$$ for $p=3$ we get $$p^2+2=11$$ If $$p\equiv 1\mod 3$$ we get $$p^2+2\equiv 0 \mod 3$$ For $$p\equiv 2 \mod 3$$ we get $$p^2+2\equiv 0 \mod 3$$

$\endgroup$
  • $\begingroup$ $p^2 + 2 = 6$ *, for p=2 $\endgroup$ – Andrei Rk Apr 12 '18 at 15:27

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