<s>[INST] Positive integers $a$ and $b$ are such that $a+b=a/b + b/a$. Find $a^2+ b^2$. This is PRE RMO 2015 question. Positive integers $a$ and $b$ are such that $$a+b=a/b + b/a$$ Find $$a^2+ b^2$$
My try:-
Given that
$$a+b=a/b + b/a$$On simplification we get
$$a^2 b+ b^2 a= a^2 + b^2$$
But in my book the given answer is 2. Please tell me how it is possible.
 [/INST] You know that $a^2b+b^2a=a^2+b^2$. However, you haven't used that $a,b$ are positive integers. Rewrite the expression as $a^2(b-1)+b^2(a-1)=0$. Then, since $a,b > 0$, we have $a^2 >0$ and $b^2>0$. Also, $b-1\geq 0$ and $a-1\geq 0$. So $a^2(b-1)+b^2(a-1)$ is positive or zero, where it is zero if $b-1= 0$ and $a-1= 0$.
Hence $a=b=1$ and hence $a^2+b^2=1^2+1^2=2$. 
</s>