Proof about difference of squares

cragar
Messages
2,546
Reaction score
3

Homework Statement


Show that an integer n can be represented as a difference of 2 squares if it is either
odd or divisible by 4, otherwise not. The representation is unique if and only if n is a prime number.

The Attempt at a Solution


let x and y be integers so then we have x^2-y^2=n=(x-y)(x+y)
we would look at the case where x and y are even, then we could factor a 2 out of x-y and x+y so it would be divisible by 4. if x or y was odd then n would be odd. and if x and y were both odd we could factor a 2 out of x-y and x+y. But I am not sure how to prove the part
where n is prime, and that would imply x and y are unique. It seems that if n is prime
then x-y or x+y has to be 1 or else n would be composite.
 
Physics news on Phys.org
cragar said:
the case where x and y are even, then we could factor a 2 out of x-y and x+y so it would be divisible by 4.
True, but it isn't x and y both being even that really characterises this case.
if x or y was odd then n would be odd.
No, think that through again.
 
There are two things I don't understand about this problem. First, when finding the nth root of a number, there should in theory be n solutions. However, the formula produces n+1 roots. Here is how. The first root is simply ##\left(r\right)^{\left(\frac{1}{n}\right)}##. Then you multiply this first root by n additional expressions given by the formula, as you go through k=0,1,...n-1. So you end up with n+1 roots, which cannot be correct. Let me illustrate what I mean. For this...
Back
Top