Show that $\gcd(a + b, a^2 + b^2) = 1$ or $2$ if $\gcd(a, b)=1$.
I have absolutely no clue where to start and what to do, please provide complete proof and answer.
Show that $\gcd(a + b, a^2 + b^2) = 1$ or $2$ if $\gcd(a, b)=1$.
I have absolutely no clue where to start and what to do, please provide complete proof and answer.
Suppose that $\gcd(a+b,a^2+b^2)=d$ Then $d \mid a+b$ and $d \mid a^2+b^2$.
$d \mid (a+b)(a+b)-(a-b)(a+b)=2a^2$.
$d \mid (a+b)(a+b)+(a-b)(a+b)=2b^2$
$d \mid (2a^2,2b^2) = 2(a^2,b^2)=2(a,b)^2=2.1=2 \implies d=1$ or $2$.
We use repeatedly the identity $\gcd(x,y)=\gcd(x,y+kx)$ for any integer $k$.
For $k=-(a+b)$, we have $$\gcd(a+b,a^2+b^2)=\gcd(a+b,-2ab)$$
But $\gcd(a,b)=1$ so $\gcd(a,a+b)=1$ and similarly $\gcd(b,a+b)=1$. Combining, we get $\gcd(ab,a+b)=1$. Hence $\gcd(a+b,a^2+b^2)=\gcd(a+b,-2)$, which is $1$ or $2$.
We first show that there is no odd prime $p$ that divides both $a+b$ and $a^2+b^2$.
For if $p$ divides both, then $p$ divides $(a+b)^2-(a^2+b^2)$, so $p$ divides $2ab$. Since $p$ is odd, it divides one of $a$ or $b$, say $a$. But then since $p$ divides $a+b$, it must divide $b$. This contradicts the fact that $a$ and $b$ are relatively prime.
So the only possible common divisors of $a+b$ and $a^2+b^2$ are powers of $2$. If $a$ is even and $b$ is odd (or the other way) then the greatest common divisor of $a+b$ and $a^2+b^2$ is therefore $1$.
If $a$ and $b$ are both odd, then $a^2+b^2\equiv 2\pmod{8}$, and therefore the highest power of $2$ that divides $a^2+b^2$ is $2^1$. So in that case $\gcd(a+b,a^2+b^2)=2$.