3. For the polynomial $p(x)=2x+1$, find a polynomial $q(x)$ of the first degree such that $p^{2}(q(x))=q\left(p^{2}(x)\right)$ for any $x$.
3. Solution. Let $q(x)=a x+b$. Then

$$
p^{2}(q(x))=(2 q(x)+1)^{2}=4(a x+b)^{2}+4(a x+b)+1=4 q^{2}(x)+4 q(x)+1=4 a^{2} x^{2}+(8 a b+4 a) x+4 b^{2}+4 b+1
$$

and

$q\left(p^{2}(x)\right)=a\left(4 x^{2}+4 x+1\right)+b=4 a x^{2}+4 a x+a+b$.

By the condition of the problem $p^{2}(q(x))=q\left(p^{2}(x)\right)$. Equating the coefficients of like powers of $x$, we get the system:
$\left\{\begin{array}{c}4 a^{2}=4 a \\ 4 a b+4 a=4 a \\ 4 b^{2}+4 b+1=a+b\end{array}\right.$ or $\left\{\begin{array}{c}a^{2}=a \\ a b=0 \\ 4 b^{2}+3 b+1=a\end{array}\right.$.

From the first equation we have $a=1$ or $a=0$. For $a=0$ we get $4 b^{2}+3 b+1=0$. The last equation has no solutions. For $a=1$ we find $b=0$. Therefore, $q(x)=x$.