Task 3. (15 points) Solve the equation $5 x-x^{2}+\sqrt{\left(16-x^{2}\right)}\left(-9+10 x-x^{2}\right)=9$.

#
# Solution.

Rewrite the equation as $\sqrt{\left(16-x^{2}\right)}\left(-9+10 x-x^{2}\right)=x^{2}-5 x+9$.

$$
\sqrt{(x-4)(x+4)(x-1)(x-9)}=x^{2}-5 x+9
$$

Rearrange the factors $(x-4)(x-1)$ and $(x+4)(x-9)$, we get

$$
\sqrt{\left(x^{2}-5 x+4\right)\left(x^{2}-4 x-36\right)}=x^{2}-5 x+9
$$

Let $x^{2}-5 x+4=t$, then $x^{2}-4 x-36=t-40, x^{2}-5 x+9=t+5$, we get

$$
\begin{gathered}
\sqrt{t(t-40)}=t+5 \\
\left\{\begin{array}{l}
t+5 \geq 0 \\
t(t-40)=(t+5)^{2}
\end{array}\right. \\
t=-\frac{1}{2} \\
x^{2}-5 x+4=-\frac{1}{2} \\
2 x^{2}-10 x+9=0 \\
x_{1,2}=\frac{5 \pm \sqrt{7}}{2}
\end{gathered}
$$

Answer. $\frac{5 \pm \sqrt{7}}{2}$.