Factorize $(x+1)(x+2)(x+3)(x+6)- 3x^2$

I'm preparing for an exam and was solving a few sample questions when I got this question -
Factorize : $$(x+1)(x+2)(x+3)(x+6)- 3x^2$$ I don't really know where to start, but I expanded everything to get : $$x^4 + 12x^3 + 44x^2 + 72x + 36$$
I used rational roots test and Descartes rule of signs to get guesses for the roots. I tried them all and it appears that this polynomial has no rational roots.So, what should I do to factorize this polynomial ?

(I used wolfram alpha and got the factorization : $(x^2 + 4x + 6) (x^2 + 8x + 6)$ But can someone explain how to get there ?)


A way to do it is to write $(x+2)(x+3) = x^2 + 6x + 6 - x$, $(x+1)(x+6) = x^2 + 6x + 6 + x$, so

$$ (x+2)(x+3)(x+1)(x+6) = (x^2 + 6x + 6)^2 -x^2 $$ which gives that $$ (x+2)(x+3)(x+1)(x+6) - 3x^2 = (x^2 + 6x + 6)^2 -4x^2 = (x^2+ 4x + 6)(x^2 +8x + 6). $$


I'm assuming that you are looking for a factorization of the polynomial $$ f = x^4 + 12x^3 + 44x^2 + 72x + 36 $$ in $\mathbb Q[x]$. By the Lemma of Gauss and the fact that $f$ is monic, this is the same as looking for a factorization in $\mathbb Z[x]$.

Since there are no rational roots, the only remaining possibility is the factorization into two factors of degree 2. Since the polynomial is monic, the factors may be assumed to be monic. So the putative factors have the form $x^2 + ax + b$ and $x^2 + cx + d$ with $a,b,c,d\in\mathbb Z$.

This leads to $$ f = (x^2 + ax + b)(x^2 + cx + d) = x^4 + (a + c)x^3 + (ac + b + d)x^2 + (ad + bc)x + bd. $$ Comparing the coefficients, we get four equations $$ a+c = 12\\ ac + b + d = 44\\ ad + bc = 72\\ bd = 36 $$ Up to swapping the two factors, the last equation has the solutions $$ (b,d)\in\{(1,36),(-1,-36),(2,18),(-2,-18),(3,12),(-3,-12),(4,9),(-4,-9),(6,6),(-6,-6)\}. $$ It's a bit of work, but plugging these values into the remaining three equations, you find that only for $b=d=6$ there is a solution, which is $a = 4$, $b = 8$ or $a = 8$, $b=4$. This gives you the two factors.