2

I know that $2017 = 9^2+44^2$, but how can I prove that this is the only possible way you can write 2017 as a sum of 2 squares?

carmichael561
  • 53,688
furfur
  • 598
  • 4
    if you are unfamiliar with advanced number theory topics such as Gaussian integers, then brute force checking is pretty much the only way to convince yourself. – dezdichado Jul 12 '17 at 19:59
  • observation by Euler, having more than one expression means the number is composite. Article by Brillhart, December 2009, A Note on Euler's Factoring Problem – Will Jagy Jul 12 '17 at 20:01
  • It is quite quick to check in a spreadsheet. Put the numbers from $0$ to $45$ in column A, then in column B write =sqrt(2017-A^2) and scan down for an integer. Copy down is your friend. – Ross Millikan Jul 12 '17 at 20:07
  • While obviously not a proof, you can always quickly check wolframalpha, giving it the query 'solve x^2+y^2 over the integers' – Bram28 Jul 12 '17 at 20:13

1 Answers1

8

$2017$ is a prime number of the form $4k+1$, and for such a numbers it is well known that the decomposition as a sum of two squares is essentially unique.

The point is that the equality $2017=9^2+44^2$ can be translated in the ring of Gaussian integers $\mathbb{Z}[i]$ as $$2017 = (9+44i)(9-44i).$$

Since $\mathbb{Z}[i]$ is a unique factorization domain, any other factorization of $2017$ coincides with the one above up to units. But the units of Gaussian integers are $\{\pm1, \, \pm i\}$, so the representation $2017= a^2+b^2$ is unique up to order and up to sign of $a$ and $b$.