a n − b n + 2 = ( a + b ) n − 1
a and b are relatively prime positive integers and n ( > 1 ) is an integer. Find all solutions to the equation above and enter your answer as ∑ ( a + b + n ) .
This is a generalization of the problem from 1997 Russian Olympiad:
For prime numbers p and q , solve p 3 − q 5 = ( p + q ) 2 .
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.
When b>1, it's quite easy to show a=7. Since b^(a-1) = 1 (mod a), then multiplying the formula by b^(a-n-3) and expressing it in base a gives b^(a-1) + b^(a-4) =0 (mod a).
This implies b^(a-4) = -1 (mod a) so b^(2a-8) = 1 (mod a). Which is true only if a-7 divides a.
Log in to reply
How do you get b a − 1 ≡ 1 ( m o d a ) ?
Log in to reply
It's one of Format's theorems.
Log in to reply
@Malcolm Rich – Notice that none of a and b are prime. Therefore b ϕ ( a ) ≡ 1 ( m o d a ) will not reduce to b a − 1 ≡ 1 ( m o d a ) !
The solution is very lengthy. Here's the solution to the '97 Russian Olympiad problem: p 3 − q 5 = ( p + q ) 2
First suppose neither p nor q equals 3. If they are congruent modulo 3, the left side is divisible by 3 while the right is not; if they are not congruent modulo 3, the right side is divisible by 3 while the left side is not, so there are no such solutions. If p = 3 , we have q 5 < 2 7 , which is impossible. Thus q = 3 and p 3 − 2 4 3 = ( p + 3 ) 2 , whose only integer root is p = 7 .
For the generalised problem a n − b n + 2 = ( a + b ) n − 1 , we can observe another trivial solution for n = 2 which is ( 2 , 1 , 2 ) . If we can prove that there exists no solution for n ≥ 4 , then we have our answer here as ( 7 + 3 + 3 ) + ( 2 + 1 + 2 ) = 1 8
But the problem tells us that a and b must be relatively prime. Is it proper to say that 2 is "relatively prime" to 1 -- or for that matter, any integer k>1 is "relatively prime" to 1?
Log in to reply
Yes, it's proper to say that. Indeed, any integer k>1 is relatively prime to 1. Because that's the way co-primes are defined: the two integers should have no positive common factors other than 1. The numbers 2 and 1 'properly' satisfy this definition.
It's lengthy, but not ugly. It's a beautiful solution, I promise! :)) I'd love to see simpler ones.
Problem Loading...
Note Loading...
Set Loading...
It is clear that a > b ≥ 1 . Looking mod b gives b ∣ a n − 1 ( a − 1 ) and since g cd ( a , b ) = 1 we get b ∣ a − 1 and a = b c + 1 for natural number c . Looking mod a gives a ∣ b 3 + 1 . Thus a ∣ b 3 + 1 − a = b 3 + 1 − ( b c + 1 ) = b ( b 2 − c ) and there is a non-negative integer d such that b 2 − c = d a = d ( b c + 1 ) or b 2 − c d b − ( c + d ) = 0 Which is a quadratic in b . Its discriminant must be a perfect square, but note that for c > 1 and d > 1 ( c d ) 2 ≤ Δ b = c 2 d 2 + 4 ( c + d ) ≤ ( c d + 2 ) 2 Thus we must have c 2 d 2 + 4 ( c + d ) = ( c d + 1 ) 2 , which leads to c = 2 d − 4 4 d − 1 Which is not an integer. This is a contradiction and so c = 1 or d ≤ 1 . Therefore we have three cases to check: c = 1 , d = 0 and d = 1 .
For c = 1 we get a = b + 1 and equation becomes ( b + 1 ) n = b n + 2 + ( 2 b + 1 ) n − 1 ( 1 ) From this equation observe that ( b + 1 ) n > b n + 2 and ( b + 1 ) n > ( 2 b + 1 ) n − 1 . Multiply these two inequalities to get ( b 2 + 2 b + 1 ) n > ( 2 b 2 + b ) n − 1 b 3 But for b ≥ 3 we have ( b 2 + b + 1 ) n = ( b 2 + b + 1 ) n − 1 ( b 2 + b + 1 ) < ( 2 b 2 + b ) n − 1 b 3 which is a contradiction and b ≤ 2 . For b = 1 from equation ( 1 ) we get 2 n = 1 + 3 n − 1 and one can prove by induction that 1 + 3 n − 1 > 2 n for n > 2 . n = 2 satisfies the equation and leads to a = 2 . We get a solution from here: ( a , b , n ) = ( 2 , 1 , 2 ) . For b = 2 from equation ( 1 ) we get 3 n = 2 n + 2 + 5 n − 1 and one can prove by induction that 3 n < 2 n + 2 + 5 n − 1 for n > 3 and for n ≤ 3 equality does not hold.
For d = 0 we have a = b 3 + 1 and original equation becomes ( b 3 + 1 ) n − b n + 2 = ( b 3 + b + 1 ) n − 1 ( 2 ) Suppose that p is prime divisor of b 3 + b + 1 . Looking mod p gives ( − b ) n ≡ p b n + 2 or ( − 1 ) n ≡ p b 2 . For odd n it follows that b 2 + 1 ≡ p 0 , which is impossible considering that g cd ( b 2 + 1 , b 3 + b + 1 ) = 1 . Thus n is even and p ∣ b 2 − 1 and p ∣ b 3 + b + 1 − b ( b 2 − 1 ) = 2 b + 1 p ∣ b ( 2 b + 1 ) − 2 ( b 2 − 1 ) = b + 2 p ∣ 2 ( b + 2 ) − ( 2 b + 1 ) = 3 So p = 3 is the only prime divisor of b 3 + b + 1 and b 3 + b + 1 = 3 k for a natural number k . Suppose that k > 1 . RHS of b 3 + b + 1 = 3 k is divisible by 9 . Let us look when b 3 + b + 1 is divisible by 9 . \begin{array}{|*{10}{c|}} \hline b \pmod 9 & 0 & 1 & 2 & 3 & 4 & 5 & 6 & 7 & 8 \\ \hline b^3 \pmod 9 & 0 & 1 & 8 & 0 & 1 & 8 & 0 & 1 & 8 \\ \hline b^3+b+1 \pmod 9 & 1 & 3 & 2 & 4 & 6 & 5 & 7 & 0 & 8 \\ \hline \end{array} Thus we must have b ≡ 7 ( m o d 9 ) . Now from equation ( 2 ) looking mod 9 gives 2 n − 7 n + 2 ≡ 9 0 , which is impossible. Thus k = 1 and b = 1 and 2 n − 1 = 3 n − 1 , which gives the same solution of case c = 1 .
Final case is d = 1 , which gives a = b 2 − b + 1 and equation becomes ( b 2 − b + 1 ) n − b n + 2 = ( b 2 + 1 ) n − 1 ( 3 ) Suppose that p is prime divisor of b − 1 . Looking mod p gives 0 ≡ p 2 n − 1 and tells us that 2 is the only prime divisor of b − 1 and b = 2 k + 1 for a natural number k . Once again looking mod b 2 + 1 in equation ( 3 ) gives ( − b ) n ≡ b n + 2 ( m o d b 2 + 1 ) . For even n it follows that b 2 − 1 ≡ 0 ( m o d b 2 + 1 ) , which is impossible and thus n is odd. Finally look mod 2 k in equation ( 3 ) ; It follows that 0 ≡ 2 n − 1 ( m o d 2 k ) , thus n − 1 ≥ k . Now rearrange equation 3 in the following form ( b 2 − b + 1 ) n − b n = b n ( b 2 − 1 ) + ( b 2 + 1 ) n − 1 ( 4 ) Suppose k > 1 . Let us find power of 2 in the LHS of this equation using LTE lemma. Note that since n is odd v 2 ( ( b 2 − b + 1 ) n − b n ) = v 2 ( b 2 − b + 1 − b ) + v 2 ( n ) + v 2 ( b 2 + 1 ) − 1 = 2 k ( 5 ) For finding power of 2 in the RHS of equation ( 5 ) write v 2 ( b n ( b 2 − 1 ) + ( b 2 + 1 ) n − 1 ) = min { v 2 ( b n ( b 2 − 1 ) ) , v 2 ( ( b 2 + 1 ) n − 1 ) } = min { v 2 ( 2 k + 1 ( 2 k − 1 + 1 ) ( 2 k + 1 ) n ) , v 2 ( 2 n − 1 ( 2 2 k − 1 + 2 k + 1 ) n − 1 ) } = min { k + 1 , n − 1 } = 2 1 ( k + n − ∣ k − n + 2 ∣ ) So from relation ( 5 ) 2 k = 2 1 ( k + n − ∣ k − n + 2 ∣ ) ( 6 ) But we proved n − 1 ≥ k ; If k − n = − 1 relation ( 6 ) gives 2 k = k , which is impossible and for k − n ≤ − 2 relation ( 6 ) turns to 2 k = 2 1 ( k + n − ∣ k − n + 2 ∣ ) = 2 1 ( k + n + k − n + 2 ) = k + 1 Which gives k = 1 , but this is a contradiction, because we supposed k > 1 . So k = 1 and b = 3 . Putting these values in equation ( 3 ) gives 7 n = 3 n + 2 + 1 0 n − 1 . One can prove using induction that 7 n < 3 n + 2 + 1 0 n − 1 for n > 6 . Trying values n ≤ 6 gives n = 3 as an answer. It leads to second solution: ( a , b , n ) = ( 7 , 3 , 3 ) .