<s>[INST] If $\gcd(a,b)=1$ then $\gcd(a^2+b^2,a+2ab)=1$ or $5$ The question is already in the title.    
Show that if $\gcd(a,b)=1$ then $\gcd(a^2+b^2,a+2ab)=1$ or $5$.  
I saw yesterday this exercise in a book and I tried many things but I managed  to show only that if some prime $p$ ($p$ must be $\equiv1\pmod{4}$)
divides $a^2+b^2$ and $a+2ab$ then    $p\mid2b+1$ , $p\mid4a^2+1$ and $p\mid b-2a^2$ but all these seem pointless.
Am I missing something obvious here?
 [/INST] suppose $gcd(a,b)=1$ and let $d=gcd(a^2+b^2,a+2b)$
the identity
$(a^2+b^2)+(a+2b)(2b-a)=5b^2$
shows that $d$ divides $5b^2$ and 
since $5a^2=5(a^2+b^2)-5b^2$ , $d$ divides $5a^2$
since $a$ and $b$ are relatively prime, $d$ divides $5$
</s>