If $a$ and $b$ are relatively prime to each other then each factor of $a^2 + b^2$ is the sum of two squares.
I have tried but couldn't able to find anything that leads to the conclusion.
EDIT : I want to mention that I have read two propositions of Euler from wikipedia.
(1) If a number is the sum of two squares and if it is divisible by a prime which is also a sum of two squares then the quotient thus obtained is also a sum of two squares.
With the help of this proposition the second proposition of Euler is proved which asserts that
(2)If a number is the sum of two squares which is divisible by a prime which is not the sum of two squares then there exists a factor of the quotient thus obtained which is not the sum of two squares.
With the help of (2) it has been proved that
(3) If $a$ and $b$ are relatively prime to each other then each factor of $a^2 + b^2$ is the sum of two squares.
Finally with the help of (3) Fermat's theorem of two squares has been proved.
My problem is I fail to grasp the entire proof of (3) from wikipedia.Can anybody please help me understanding it?
Thank you in advance.