# 2008 JBMO Problems/Problem 3

## Problem

Find all prime numbers , such that

## Solution

The given equation can be rearranged into the below form:

then we have

and and

then we have

and and

note that if , then which is a contradiction.

and

then we have

and and We have that exactly one of is a multiple of .

cannot be a multiple of since . Since is prime, then we have is a prime.
contradiction.

Also, cannot be a multiple of since, contradiction.

So,
and

Thus we have the following solutions:

## Solution 2 (similar to Solution 1, credit to dskull16)

The equation can be rearranged into this form

By the nature of primes this means that either q divides (p-q) or (r+1) and if q divides (p-q) then that means that q divides p which is a contradiction since any two primes have a GCD of 1 meaning that q divides . We can easily deal with the case where r is 2 but this gives a contradiction since we get that where it needs to be prime.

In the case k is 4, we get that p and q have a difference of 1 meaning that and therefore which clearly works.

In the case that k is 2, we get that p and q have a difference of 2 meaning that and therefore which also works.

In the case that k is 1, we get that p and q have a difference of 4 meaning that and therefore which works too and is our final solution.