\((x^2-5x+2)^2-(x^2-5x)=8\\ (x^2-5x+2)(x^2-5x+2)-x^2+5x-8=0\\ x^4-5x^3+2x^2-5x^3+25x^2-10x+2x^2-10x+4-x^2+5x-8=0\\ ...\\ x^4-10x^3+28x^2-15x-4=0\\ \)
Now I am going to look for factors. I am using the remainder theorem.
If I sub in x=1, which was just the first number that I tried. I get
1 - 10 +28 - 15 - 4 and that DOES =0 so that means that one of the factors is (x-1)
so now I am going to do an algebraic division to see what (x-1) would be multiplied by
x^3 - 9x^2 + 19x + 4
---------------------------------------------
x-1 | x^4 - 10x^3 + 28x^2 - 15x - 4
x^4 - x^3
--------------------------
- 9x^3+28x^2
- 9x^3 +9x^2
------------------------
19x^2 - 15x
19x^2 - 19x
---------------------
4x - 4
4x - 4
--------
0
-------
So we have
\((x-1)(x^3-9x^2+19x+4)=0\)
I tested +1,-1,+2,-2,+4,-4 I chose these because they are all factors of 4
x=4 made that second bracket = 0 therefore another factor is (x-4)
I did another algebraic division the same as before and found that
\((x^3-9x^2+19x+4)\div (x-4)=x^2-5x-1\\ so\\ (x-1)(x-4)(x^2-5x-1)=0\\ so\\ x-1=0\qquad or \qquad x-4=0 \qquad or\qquad x^2-5x-1=0\\ x=1\qquad or \qquad x=4 \qquad or\qquad x=\frac{5\pm\sqrt{25-\;-4}}{2*1}\\ x=1\qquad or \qquad x=4 \qquad or\qquad x=\frac{5\pm\sqrt{29}}{2}\\ x=1\quad or \quad x=4 \quad or\quad x=\frac{5+\sqrt{29}}{2}\quad or \quad x=\frac{5-\sqrt{29}}{2} \)
\(x=1 \quad or \quad x=4 \quad or \quad x\approx5.193 \quad or \quad x\approx -0.193\)
NOW I have not checked thes BUT if you substitute them back into the initial equation they should all make the equation true.
Let's have a look at the graph y=(x^2-5x+2)^2-(x^2-5x)-8 and see where y = 0
https://www.desmos.com/calculator/lhcjfgppxk
There you go, that is how it is done. If you would like to ask questions go ahead and ask. :))