\(a,\left(x^2+x\right)^2+4x^2+4x-12\\ =\left(x^2+x\right)^2+4\left(x^2+x\right)+4-16\\ =\left(x^2+x+2\right)^2-16\\ =\left(x^2+x+2-4\right)\left(x^2+x+2+4\right)\\ =\left(x^2+x-2\right)\left(x^2+x+6\right)\\ b,\left(x^2+x+1\right)\left(x^2+x+2\right)-12\\ Đặtx^2+x+1=y\\ =y\left(y+1\right)-12\\ =y^2+y-12\\ =y^2-3y+4y-12\\ =y\left(y-3\right)+4\left(y-3\right)\\ =\left(y+4\right)\left(y-3\right)\\ \Leftrightarrow\left(x^2+x+1+4\right)\left(x^2+x+1-3\right)\\ \left(x^2+x+5\right)\left(x^2+x-2\right)\)
\(c,\left(x^2+x\right)^2+3\left(x^2+x\right)+2\\ =\left(x^2+x\right)^2+2\cdot\dfrac{3}{2}\cdot\left(x^2+x\right)+\dfrac{9}{4}-\dfrac{1}{4}\\ =\left(x^2+x+\dfrac{3}{2}\right)^2-\dfrac{1}{4}\\ =\left(x^2+x+\dfrac{3}{2}-\dfrac{1}{2}\right)\left(x^2+x+\dfrac{3}{2}+\dfrac{1}{2}\right)\\ =\left(x^2+x+1\right)\left(x^2+x+2\right)\\ d,\left(x^2+4x+8\right)^2+3x\left(x^2+4x+8\right)+2x^2\\ =\left(x^2+4x+8\right)^2+2\cdot\dfrac{3}{2}x\left(x^2+4x+8\right)+\dfrac{9}{4}x^2-\dfrac{1}{4}x^2\\ =\left(x^2+4x+8+\dfrac{3}{2}x\right)^2-\dfrac{1}{4}x^2\\ =\left(x^2+4x+8+\dfrac{3}{2}x-\dfrac{1}{2}x\right)\left(x^2+4x+8+\dfrac{3}{2}x+\dfrac{1}{2}x\right)\\ =\left(x^2+5x+8\right)\left(x^2+6x+8\right)\)