2. (2 points) Solve the equation $f^{-1}(g(x))=h(x)$, where $f^{-1}(x)$ is the inverse function of $f(x)$, given that $f(x)=x^{3}+2 x^{2}+3 x+1, g(x)=x^{4}-x^{3}+4 x^{2}+8 x+8, h(x)=x+1$.

Answer: $\frac{3 \pm \sqrt{5}}{2}$
Solution: The original equation can be rewritten as $g(x)=f(h(x))$, that is, as $(x+1)^{3}+2(x+1)^{2}+3(x+$ 1) $+1=x^{4}-x^{3}+4 x^{2}+8 x+8$.

Expand the brackets and move everything to the right side: $x^{4}-2 x^{3}-2 x^{2}-2 x+1=0$. Notice that the polynomial on the left side is divisible by $x^{2}+x+1$. This trinomial has no roots, but the quotient does: it is the trinomial $x^{2}-3 x+1$, and its roots are $\frac{3 \pm \sqrt{5}}{2}$.