Factoring $x^4-2x^3+2x^2+x+4$ 
I need to show that the polynomial is not irreducible and I am trying to factor the polynomial 
  $$x^4-2x^3+2x^2+x+4$$

I checked from a calculator that it has a factor but how do I get it by myself?
I tried grouping but It didnt work I got 
$x^2(x^2-2x+2)+x+4$ And I dont know how should I proceed. My guts tell me that it should be of the form:
$(x^2-ax+k)(x^2+bx+l)$, should I just try to figure out the constants by trying out?
 A: If we can write $$p(x)= q(x)r(x)$$ say in $\mathbb{Z}$ then we can do that also in $\mathbb{Z}_m$ where $m$ is an arbitrary integer $>1$. So there exists $q_1,r_1$ such that 
$$p(x)\equiv_m q_1(x)r_1(x)$$ and $$r(x) \equiv_m r_1(x) \;\;\;\wedge\;\;\; q(x) \equiv_m q_1(x)  $$
and we might hope that $r(x) = r_1(x)$ or $q(x) =q_1(x)$.  

If we try this in your case for mod $2$ we get $$p(x) \equiv_2 x^4+x \equiv_2 x(x+1)(x^2+x+1)$$
and we see that $x^2+x+1$ actually divide $p(x)$.
A: $$x^4-2x^3+2x^2+x+4$$
$$=(x^2+1)^2-2x^3+x+3$$
$$=(x^2+1)^2-2x(x^2+1)+3x+3$$
$$=(x^2+1)^2+x(x^2+1)-3x^3+3$$
$$=(x^2+1)^2+x(x^2+1)-3(x-1)(x^2+x+1)$$
$$=(x^2+x+1)(x^2+1-3x+3)$$
and you are done.
A: Actually, if you just try to solve this like a general quartic equation you get a break: let $x=t+1/2$. Then
$$\begin{align}x^4-2x^4+2x^2+x+4&=\left(t+\frac12\right)^4-2\left(t+\frac12\right)^3+2\left(t+\frac12\right)^2+\left(t+\frac12\right)+4\\
&=t^4+\frac12t^2+2t+\frac{77}{16}\\
&=\left(t^2+at+b\right)\left(t^2-at+c\right)\\
&=t^4+\left(b-a^2+c\right)t^2-a(b-c)t+bc\end{align}$$
So we have
$$\begin{align}b+c&=\frac12+a^2\\
b-c&=-\frac2a\end{align}$$
With solutions
$$\begin{align}2b&=a^2+\frac12-\frac2a\\
2c&=a^2+\frac12+\frac2a\end{align}$$
Then
$$4bc=a^4+a^2+\frac14-\frac4{a^2}=\frac{77}4$$
Which simplifies to
$$a^6+a^4-19a^2-4=0$$
And here is our break: the resolvent cubic has a rational root: $a^2=4$. If we pick $a=2$, then $b=7/4$, $c=11/4$ and
$$\begin{align}x^4-2x^4+2x^2+x+4&=\left(t^2+2t+\frac74\right)\left(t^2-2t+\frac{11}4\right)\\
&=\left(\left(x-\frac12\right)^2+2\left(x-\frac12\right)+\frac74\right)\left(\left(x-\frac12\right)^2-2\left(x-\frac12\right)+\frac{11}4\right)\\
&=\left(x^2+x+1\right)\left(x^2-3x+4\right)\end{align}$$
A: Use the Rational Root Test to check if there is any real roots. It turns out that there is no such roots of this polynomial. Hence, the conclusion is that there can only be complex roots. By the fundamental theorem of Algebra, we know any non constant single variable polynomial has at least one complex root (including real ones). 
As you have mentioned, assume that the polynomial is the product of two quadratic polynomials. Solve them and find constants $a,b,k$ & $l$
