## Task 1 - 321211

Determine all pairs $(a ; b)$ of non-negative integers $a$ and $b$ for which the square of their product is twice as large as the sum of their squares.
I. If a pair $(a ; b)$ of non-negative integers $a$ and $b$ satisfies the given condition $(a b)^{2}=2\left(a^{2}+b^{2}\right)$, then

$$
a^{2}\left(b^{2}-2\right)=2 b^{2}
$$

and from this, due to the integrality of $b$, thus $b^{2}-2 \neq 0$,

$$
a^{2}=\frac{2 b^{2}}{b^{2}-2}=2+\frac{4}{b^{2}-2}
$$

Since $a^{2}$ is an integer, $b^{2}-2$ must be a divisor of 4, i.e., one of the numbers $1, -1, 2, -2, 4, -4$. The values $1, 4, -4$ are excluded, as they would lead to $b^{2}=3, b^{2}=6$ or $b^{2}=-2$, none of which hold for any integer $b$. Also, $b^{2}-2=-1$ is excluded, as it would imply $a^{2}=-2$ according to (1), which is not possible for any $a$.

Thus, only $b^{2}-2=2$ or $b^{2}-2=-2$ can hold, which, together with (1), due to $a \geq 0, b \geq 0$, leads to $(a ; b)=(2 ; 2)$ or $(a ; b)=(0 ; 0)$

(2) follows.

II. The pairs mentioned in (2) satisfy the conditions. With I. and II., it is shown that exactly the pairs mentioned in (2) satisfy the conditions of the problem.