+ Ta có: \(x^3-x^2-21x+45=0\)
\(\Leftrightarrow\left(x^3+5x^2\right)-\left(6x^2+30x\right)+\left(9x+45\right)=0\)
\(\Leftrightarrow x^2.\left(x+5\right)-6x.\left(x+6\right)+9.\left(x+5\right)=0\)
\(\Leftrightarrow\left(x+5\right).\left(x^2-6x+9\right)=0\)
\(\Leftrightarrow\left(x+5\right).\left(x-3\right)^2=0\)
\(\Leftrightarrow\left[{}\begin{matrix}x+5=0\\x-3=0\end{matrix}\right.\Leftrightarrow\left[{}\begin{matrix}x=-5\left(TM\right)\\x=3\left(TM\right)\end{matrix}\right.\)
Vậy \(S=\left\{-5,3\right\}\)
+ Ta có: \(\left(x^2-2x+1\right)-9=0\)
\(\Leftrightarrow x^2-2x+1-9=0\)
\(\Leftrightarrow\left(x^2-4x\right)+\left(2x-8\right)=0\)
\(\Leftrightarrow x.\left(x-4\right)+2.\left(x-4\right)=0\)
\(\Leftrightarrow\left(x-4\right).\left(x+2\right)=0\)
\(\Leftrightarrow\left[{}\begin{matrix}x-4=0\\x+2=0\end{matrix}\right.\Leftrightarrow\left[{}\begin{matrix}x=4\left(TM\right)\\x=-2\left(TM\right)\end{matrix}\right.\)
Vậy \(S=\left\{-2,4\right\}\)
+ Ta có: \(x.\left(x-2\right)=-x+12\)
\(\Leftrightarrow x^2-2x+x-12=0\)
\(\Leftrightarrow x^2-x-12=0\)
\(\Leftrightarrow\left(x^2-4x\right)+\left(3x-12\right)=0\)
\(\Leftrightarrow x.\left(x-4\right)+3.\left(x-4\right)=0\)
\(\Leftrightarrow\left(x-4\right).\left(x+3\right)=0\)
\(\Leftrightarrow\left[{}\begin{matrix}x-4=0\\x+3=0\end{matrix}\right.\Leftrightarrow\left[{}\begin{matrix}x=4\left(TM\right)\\x=-3\left(TM\right)\end{matrix}\right.\)
Vậy \(S=\left\{-3,4\right\}\)