Pretty Primes

Find all solutions in primes p q n p \leq q \leq n to the equation

p ( p + 1 ) + q ( q + 1 ) = n ( n + 1 ) p(p+1) + q(q+1) = n(n+1)

Enter your solution as p i + q i + n i \sum p_i + q_i + n_i .


The answer is 7.

This section requires Javascript.
You are seeing this because something didn't load right. We suggest you, (a) try refreshing the page, (b) enabling javascript if it is disabled on your browser and, finally, (c) loading the non-javascript version of this page . We're sorry about the hassle.

1 solution

Our equation yields, p(p+1) = n(n+1) - q(q+1) p(p+1) = (n-q)(n+q+1) .............................. (1) Now, We must have n>q.

For p is a prime ,

Case 1 : p | (n-q) Case 2: p | (n+q+1)

Proceeding with case 1 we have,

p ( n q ) p \le (n-q) which implies that, p ( p + 1 ) ( n q ) ( n q + 1 ) p(p+1) \le (n-q)(n-q+1) But from (1) we get,

( n + q + 1 ) ( n q + 1 ) (n+q+1) \le (n-q+1) which is inadmissible , so we cancel this case.

For Case 2 :

p | (n+q+1) So, n+q+1 = ap (For some a) Therefore,

p(p+1) = (n-q)(n+q+1)

p(p+1) = (n-q)ap

p+1 = (n-q)a .................................................. (2)

If we had a = 1, (n+q+1) = p & (p+1) = n-q, which gives p-q = n+1 & p+q = n-1, which is impossible. p+q > p-q n - 1 > n + 1 which is impossible . Thus, a > 1.

From (2) we easily obtain,

2q = (n+q)-(n-q)

= ap-1-(n-q)

= a[a(n-q)-1]-I-(n-q)

= (a+1)[(a-l)(n-q)-I] ......................... (3)

Now since a 2 a \ge 2 , ( a + 1 ) 3 (a+1) \ge 3

From (3) we see that the divisors of L.H.S are 1,2,q,2q only.

So if (a+1) = q .

(a-1)(n-q) - 1 = 2

(a-1)(n-q) = 3

(q-2)(n-q) = 3 , which leads to either ,

q-2 = 1 or n-q = 3

So,
Here q=3,n=6,a=2

And from n+q+1=ap,

we see that p=5.

Again , if (q-2)=3 & (n-q)=1

We get q=5,n=6,k=4 & p=3

On the other hand if (a+1) = 2q,

(a-1)(n-a) = 2 2(q-1)(n-a) = 2 (q-1)(n-a) = 1

So, q-1 = 1 & n-a = 1

We get

q=2,n=3 and p=2 from (n+q+1) = ap.

Thus we observe that there is only one set of solution in primes for the above equation.

p=q=2 & n=3

p+q+n=2+2+3 = 7

Moderator note:

I do not understand how

So, n+q+1 = ap (For some a)
Therefore,
p+1 = (n-q)a (2)

(In the next line, you want "a=1" instead of "k=1").

From there on, I'm unable to follow your solution.

Good answer

Sayandeep Ghosh - 5 years, 3 months ago

I do not understand how

So, n+q+1 = ap (For some a)
Therefore,
p+1 = (n-q)a (2)

(In the next line, you want "a=1" instead of "k=1").

From there on, I'm unable to follow your solution.

Calvin Lin Staff - 5 years, 3 months ago

Log in to reply

Sorry sir, I have edited that 'k' as 'a' and that line :

we have p | (n+q+1) so n+q+1 = ap (For some integer a)

putting it in,

p(p+1) = (n-q)(n+q+1) p(p+1) = (n-q)ap So we get , p+1 = (n-q)a .

Aditya Narayan Sharma - 5 years, 3 months ago

Log in to reply

Ah ic. Please add that step in. Otherwise, from n + q + 1 = a p n+q + 1 = ap , I only conclude that p = n + q + 1 a p = \frac{n+q+1}{a} . Now I understand the rest of your solution.

I think that it can be greatly simplified, by using the symmetric condition that q n + p + 1 q \mid n+p+1 . We have n < p + q n < p + q and n + p + 1 4 q n+p+1 \leq 4q , from which considering the values of a q = 1 , 2 , 3 , 4 a_q = 1, 2, 3, 4 could be easier.

Calvin Lin Staff - 5 years, 3 months ago

Log in to reply

@Calvin Lin Ya sir i hv plugged that step in and the method u described , I want to know about that. So I would be working on that solution

Aditya Narayan Sharma - 5 years, 3 months ago

0 pending reports

×

Problem Loading...

Note Loading...

Set Loading...