
3. Let $P(x)=x^{2}+\frac{1}{2} x+b$ and $Q(x)=x^{2}+c x+d$ be two polynomials with real coefficients such that $P(x) Q(x)=Q(P(x))$ for all real $x$. Find all the real roots of $P(Q(x))=0$.


Solution: Observe that

$$
P(x) Q(x)=x^{4}+\left(c+\frac{1}{2}\right) x^{3}+\left(b+\frac{c}{2}+d\right) x^{2}+\left(\frac{d}{2}+b c\right) x+b d
$$

Similarly,

$$
\begin{aligned}
Q(P(x)) & =\left(x^{2}+\frac{1}{2} x+b\right)^{2}+c\left(x^{2}+\frac{1}{2} x+b\right)+d \\
& =x^{4}+x^{3}+\left(2 b+\frac{1}{4}+c\right) x^{2}+\left(b+\frac{c}{2}\right) x+b^{2}+b c+d
\end{aligned}
$$

Equating coefficients of corresponding powers of $x$, we obtain

$$
c+\frac{1}{2}=1, \quad b+\frac{c}{2}+d=2 b+\frac{1}{4}+c, \quad \frac{d}{2}+b c=b+\frac{c}{2}, \quad b^{2}+b c+d=b d
$$

Solving these, we obtain

$$
c=\frac{1}{2}, d=0, b=\frac{-1}{2}
$$

Thus the polynomials are

$$
P(x)=x^{2}+\frac{1}{2} x-\frac{1}{2}, \quad Q(x)=x^{2}+\frac{1}{2} x
$$

Therefore,

$$
\begin{aligned}
P(Q(x)) & =\left(x^{2}+\frac{1}{2} x\right)^{2}+\frac{1}{2}\left(x^{2}+\frac{1}{2} x\right)-\frac{1}{2} \\
& =x^{4}+x^{3}+\frac{3}{4} x^{2}+\frac{1}{4} x-\frac{1}{2}
\end{aligned}
$$

It is easy to see that

$$
P(Q(-1))=0, \quad P(Q(1 / 2))=0
$$

Thus $(x+1)$ and $(x-1 / 2)$ are factors of $P(Q(x))$. The remaining factor is

$$
h(x)=x^{2}+\frac{1}{2} x+1
$$

The discriminant of $h(x)$ is $D=(1 / 4)-4<0$. Hence $h(x)=0$ has no real roots. Therefore the only real roots of $P(Q(x))=0$ are -1 and $1 / 2$.
