1
$\begingroup$

Let $X = a^2 +b^2$ where all the terms are positive integers and $X$ is a composite number and $\gcd(a,b)=1$ . Do there exist positive integers $c$ and $d$ other than $a$ and $b$ such that $X = c^2+d^2$ ?

By Fermat's Two Square Theorem, since $\gcd(a,b) =1$ , all prime factors of $X$ (other than $2$) must be of the form $4k+1$. I can prove that primes of the form $4k+1$ can be uniquely written as a sum of two squares, but can composites also follow the same property?

Any help will be appreciated.
Thanks.

$\endgroup$
  • 4
    $\begingroup$ $65 = 8^2 + 1^2 = 7^2 + 4^2$ $\endgroup$ – MJD May 16 '16 at 14:57
  • 1
    $\begingroup$ So that means it doesn't hold for composites... $\endgroup$ – Henry May 16 '16 at 14:58
  • $\begingroup$ Not generally. But for $X = 2^kp$ with $p \equiv 1 \pmod{4}$ prime, you have uniqueness, and if by "positive" you mean $> 0$ rather than $\geqslant 0$, then you also have uniqueness for $4^kp^2$. $\endgroup$ – Daniel Fischer May 16 '16 at 15:03
8
$\begingroup$

If $N$ is a product of two numbers of the form $4k+1$, then it usually has at least two representations as a sum of two squares, because:

$$\begin{align} (a^2+b^2)(c^2+d^2) & = (ac-bd)^2 + (ad+bc)^2 \\ & = (ac+bd)^2 + (ad-bc)^2 \end{align}$$

This is known as Brahmagupta's identity.

By applying Brahmagupta's identity repeatedly, you can find composite numbers that can be decomposed into two squares in arbitrarily many ways. For example,

$$\begin{align} 5^4\cdot 13 & = \\ 8125 & = 5^2 + 90^2 \\ & = 27^2 + 86^2 \\ & = 30^2 + 85^2 \\ & = 50^2 + 75^2 \\ & = 58^2 + 69^2 \end{align}$$

The smallest such example is $25 = 3^2+4^2 = 0^2+5^2$.

$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.