If we start with the identity n=((n+1)/2)^{2}-((n-1)/2)^{2}, then, if n is an odd whole number, it can clearly be written as a difference of squares (of whole numbers). If n is the square of an odd number, i.e. n=(2k+1)^{2}, then we have the identity (2k+1)^{2}= (2k^{2}+2k+1)^{2}-(2k^{2}+2k)^{2}. Hence every **odd** number, other than 1, must appear in some Pythagorean triple. Also, every **even** number, other than 2, appears in some Pythagorean triple.

Cubes can also be represented as differences of squares, e.g. n^{3} = (n(n+1)/2)^{2} – (n(n-1)/2)^{2}.

An application of the above identity is to∑_{1≤k≤n}k^{3} = (n(n+1)/2)^{2}.

For higher powers, if we try n^{a} = (n^{b}(n^{c} + 1)/2)^{2} – (n^{b}(n^{c}-1)/2)^{2} ,

where a, b and c are whole numbers, then a=2b+c. So, if a=5, we can have b=2 and c=1 or b=1 and c=3.

Hence, for n^{5}(say) we can have either n^{5} = (n^{2}(n+1)/2)^{2} – (n^{2}(n-1)/2)^{2 }or

n^{5}= (n(n^{3}+1)/2)^{2}– (n(n^{3}-1)/2)^{2}.

**Divisibility by 3**

If (x,y,z) is a PPT (Primitive Pythagorean Triple) then z^{2} = x^{2} + y^{2}. Looking at examples of PPT’s it is evident that **exactly** one of x and y is divisible by 3. This follows from an application of n^{3}≡ n mod 3 for any integer n.

**Proof**

If z^{2}= x^{2}+ y^{2 }^{}then 2x^{2}y^{2} = z^{4} – x^{4} – y^{4 }≡ z^{2}– x^{2}– y^{2 }mod 3≡ 0 mod 3 and so 3|2x^{2}y^{2}. Hence, 3 divides x or y or both. 3 can’t divide both x **and** y because then 3 would then divide z, since z^{2}= x^{2}+ y^{2}, meaning that (x,y,z) is not primitive. Hence the result.

For positive integer powers of positive integers it is clear that these can be expressed as differences of squares of positive integers. What is also clear is that in all cases at least one of these squares must be divisible by 3.

**Case 1 Odd powers, 3 and higher**

n^{2k+1} = (n^{k}(n+1)/2)^{2} – (n^{k}(n-1)/2)^{2 }, k≥1

**Case 2 Even powers, 4 and higher**

n^{2k} = (n^{k-1}(n^{2} + 1)/2)^{2} – (n^{k-1}(n^{2} – 1)/2)^{2 }, k≥2

Obviously if 3|n then both squares in the above cases are divisible by 3. Otherwise, in **Case 1** either the first or the second square must be divisible by 3 depending on n, while in **Case 2** the second square is always divisible by 3.

**Divisibility by 5**

If (x,y,z) is a PPT (Primitive Pythagorean Triple) then z^{2}= x^{2}+ y^{2}. Looking at examples of PPT’s it is evident that **exactly **one of x, y and z is divisible by 5. This follows from an application of n^{5}≡ n mod 5 for any integer n.

**Proof**

If z^{2}= x^{2}+ y^{2 }^{}then z^{6} = x^{6} + 3x^{4}y^{2} + 3x^{2}y^{4} + y^{6} = x^{6} + y^{6} + 3x^{2}y^{2}z^{2}.

Hence, 3x^{2}y^{2}z^{2} = z^{6} – x^{6} – y^{6}≡ z^{2} – x^{2} – y^{2} mod 5≡ 0 mod 5. Therefore 5|3x^{2}y^{2}z^{2} and so **the result follows**.

If we look at n^{2k}= (n^{k-1}(n^{2}+ 1)/2)^{2}– (n^{k-1}(n^{2}– 1)/2)^{2}, k≥2, then the product of the terms to be squared gives n^{2k-2}(n^{4} – 1)/4 = n^{2k-3}n(n^{4}– 1)/4≡ 0 mod 5, so at least one of the squared terms must be divisible by 5.