Let's determine all polynomials $P(x)$ with real coefficients that satisfy the equation

$$
P(a-b)+P(b-c)+P(c-a)=2 P(a+b+c)
$$

whenever $a, b, c$ are real numbers such that

$$
a b+b c+c a=0
$$
Solution by Hubai Tamás. If $a=b=c=0$, then the condition is satisfied, so $3 P(0)=2 P(0)$, which means $P(0)=0$. The condition is clearly also satisfied if $b=c=0$, and thus $P(a)+P(0)+P(-a)=2 P(a)$, from which $P(-a)=P(a)$ follows for all real $a$. The polynomial function $P(x)$ is therefore even, which is only possible if all its odd-degree terms are zero. (By rearranging the condition $P(-a)=P(a)$, we indeed get that $P(x)-P(-x)$ is the zero polynomial, and in this difference, precisely the odd-degree terms of $P(x)$ appear.)

Let $Q(x)$ be the polynomial in which the terms of $P(x)$ appear with half the exponent, that is, for which $Q\left(x^{2}\right)=P(x)$, and let's see what must be true for the polynomial $Q(x)$. Using the relationship between $a, b, c$, let's reduce the number of variables. Introduce the variables $x$ and $y$ as follows: let $a=x+y+c, b=y+c$. For any $a, b$, and $c$ triple, such $x$ and $y$ clearly exist, and for any values of $x$ and $y$, there is an $a, b, c$ triple for which the condition is satisfied. This precisely means that the system of equations $a=x+y+c, b=y+c, a b+b c+c a=0$ has a solution $(a, b, c)$. Substituting, we get the equation $(x+y+c)(y+c)+(y+c) c+c(x+y+c)=0$, which, after rearrangement, is a quadratic in $c$:

$$
3 c^{2}+(2 x+4 y) c+\left(x y+y^{2}\right)=0
$$

The discriminant, $4 x^{2}+4 x y+4 y^{2}=2\left(x^{2}+y^{2}+(x+y)^{2}\right)$, is non-negative.

Express the quantities appearing in the condition using the new variables, $x$ and $y$: $a-b=x, b-c=y, c-a=-x-y$, and

$$
(a+b+c)^{2}=a^{2}+b^{2}+c^{2}+2 a b+2 b c+2 c a=
$$

(using the fact that $a b+b c+c a=0$ by the condition and further simplifying)

$$
\begin{aligned}
& =a^{2}+b^{2}+c^{2}-a b-b c-c a=\frac{(a-b)^{2}+(b-c)^{2}+(c-a)^{2}}{2}= \\
& =\frac{x^{2}+y^{2}+(x+y)^{2}}{2}=x^{2}+y^{2}+x y
\end{aligned}
$$

Thus, the conditions of the problem are satisfied for the polynomial $P$ if and only if for any real pair of numbers $x, y$,

$$
P(x)+P(y)+P(x+y)=2 P\left(\sqrt{x^{2}+y^{2}+x y}\right)
$$

(Note that the third term on the left originally is $P(c-a)=P(-x-y)$, which can now be written as $P(x+y)$ because $P$ is an even function.)

For the polynomial $Q(x)$, this means that

$$
Q\left(x^{2}\right)+Q\left(y^{2}\right)+Q\left(x^{2}+y^{2}+2 x y\right)=2 Q\left(x^{2}+y^{2}+x y\right)
$$

In the equality, two polynomials in $x$ stand, whose coefficients are polynomials in the variable $y$. Suppose that the polynomial $Q(x)$ is of degree $n$ and let $n>1$. The leading coefficient of $Q(x)$ can be divided by (1), so it can be assumed that it is 1. Since (1) is an equality of two polynomials, the coefficients of every power of $x$ on both sides are equal. It is worth paying attention to the $x^{2 n-2}$ term. If the coefficient of $x^{n-1}$ in $Q(x)$ is $\lambda$, then the coefficients of $x^{2 n-2}$ on both sides of (1) are:

$$
\lambda+0+\left(\lambda+n y^{2}+\binom{n}{2} \cdot 4 y^{2}\right)=2\left(\lambda+n y^{2}+\binom{n}{2} \cdot y^{2}\right)
$$

Rearranging, we get $2 \cdot\binom{n}{2}=n$, and thus $n=2$ for $n>1$. This means that $n \leq 2$, so $Q(x)$ is at most a quadratic polynomial, and $P(x)$ is at most a quartic even polynomial with a zero constant term: $P(x)=\alpha \cdot x^{4}+\beta \cdot x^{2}$.

We will show that these polynomials satisfy the problem's condition. It is sufficient to verify this in the two special cases when $P(x)=x^{4}$ and $P(x)=x^{2}$. It can be easily verified that the sum of two solutions and a scalar multiple of a solution is also a solution, so we can obtain all polynomials of the given form from the above two special polynomials.

If $P(x)=x^{4}$, then

$$
\begin{aligned}
& 2 P(a+b+c)-P(a-b)-P(b-c)-P(c-a)= \\
= & 2(a+b+c)^{4}-(a-b)^{4}-(b-c)^{4}-(c-a)^{4}= \\
= & 12\left(a^{3} b+b^{3} c+c^{3} a+a b^{3}+b c^{3}+c a^{3}\right)+6\left(a^{2} b^{2}+b^{2} c^{2}+c^{2} a^{2}\right)+ \\
& +24\left(a^{2} b c+b^{2} a c+c^{2} a b\right)= \\
= & 6(a b+b c+c a)^{2}+12\left(a^{2}+b^{2}+c^{2}\right)(a b+b c+c a)=0
\end{aligned}
$$

If $P(x)=x^{2}$, then

$$
\begin{aligned}
& 2 P(a+b+c)-P(a-b)-P(b-c)-P(c-a)= \\
= & 2(a+b+c)^{2}-(a-b)^{2}-(b-c)^{2}-(c-a)^{2}= \\
= & 2\left(a^{2}+b^{2}+c^{2}+2 a b+2 b c+2 c a\right)-\left(a^{2}+b^{2}-2 a b\right)- \\
& -\left(b^{2}+c^{2}-2 b c\right)-\left(c^{2}+a^{2}-2 c a\right)=6(a b+b c+c a)=0
\end{aligned}
$$

This completes the solution, the sought polynomials can be written in the form $P(x)=\alpha \cdot x^{4}+\beta \cdot x^{2}$, where $\alpha$ and $\beta$ are arbitrary real numbers.