How to factorize this cubic equation? In one of the mathematics book, the author factorized following term

$$x^3 - 6x + 4 = 0$$
to

$$( x - 2) ( x^2 + 2x -2 ) = 0.$$

How did he do it?
There is a neat trick called the rational roots theorem.  All we have to do is factor the first and last numbers, put them over a fraction, and take $\pm$.  This gives us the following possible rational roots:

$$x\stackrel?=\pm1,\pm2,\pm4$$

due to the factorization of $4$.  Checking these, it is clear $x=2$ is the only rational root, since

$$\begin{align}0&amp;\ne(+1)^3-6(+1)+4\\0&amp;\ne(-1)^3-6(-1)+4\\\color{#4488dd}0&amp;=\color{#4488dd}{(+2)^3-6(+2)+4}\\0&amp;\ne(-2)^3-6(-2)+4\\0&amp;\ne(+4)^3-6(+4)+4\\0&amp;\ne(-4)^3-6(-4)+4\end{align}$$

leaving us with

$$x^3-6x+4=(x-2)(\dots)$$

We can find the remainder through synthetic division:

$$\begin{array}{c|c c}2&amp;1&amp;0&amp;-6&amp;4\\&amp;\downarrow&amp;2&amp;4&amp;-4\\&amp;\hline1&amp;2&amp;-2&amp;0\end{array}$$

which gives us our factorization:

$$x^3-6x+4=(x-2)(x^2+2x-2)$$
If $P$ is a polynomial with real coefficients and if $a\in\mathbb{R}$ is a root, which means that $P(a)=0$, then there exists a real polynomial $Q$ such that $\forall x\in\mathbb{R},\quad P(x)=(x-a)\,Q(x)$.

On this case, you can see by inspection, that $P(2)=0$.

It remains to find real constants $A,B,C$ such that :

$$\forall x\in\mathbb{R},\quad x^3-6x+4=(x-2)(Ax^2+Bx+C)$$

Identification of coefficients leads to $A=1$, $-2C=4$ and, for example, $A-2B=0$ (equating the coeffts of $x^2$ in both sides).