Here is the idea I was told for the solution:
we will consider the cosets of the form $a + bx + cx^2 + dx^3 + J$ where $J = x^4 + x^2 +1$ because by adding a multiple of $(x^2 + x + 1)^2$ we can get rid of all the forth power terms (I want an example to see this please). Then $a + bx + cx^2 + dx^3$ can be written as $(a + bx) + (e + fx)(x^2 + x + 1)$ (I also do not know why is this correct, so if someone explain it to me I would appreciate it). Finally when is this element invertible in $R$ (this is also something that I need help in it please).
Question: "Here is the idea I was told for the solution:
we will consider the cosets of the form $a + bx + cx^2 + dx^3 + J$ where $J = x^4 + x^2 +1$ because by adding a multiple of $(x^2 + x + 1)^2$ we can get rid of all the forth power terms (I want an example to see this please). Then $a + bx + cx^2 + dx^3$ can be written as $(a + bx) + (e + fx)(x^2 + x + 1)$ (I also do not know why is this correct, so if someone explain it to me I would appreciate it). Finally when is this element invertible in $R$ (this is also something that I need help in it please)."
Answer: If $k:=\mathbb{F}_2$ and $A:=k[x]$. Let $f:=x^2+x+1 \in A$. It follows $\mathfrak{m}:=(f)$ is a maximal ideal (the polynomial $f$ is irreducible). Your ring $R:=k[x]/\mathfrak{m}^2$ is a local ring with maximal ideal $\mathfrak{n}:=\mathfrak{m}/\mathfrak{m}^2$ and there is an exact sequence
$$0 \rightarrow \mathfrak{m}/\mathfrak{m}^2 \rightarrow R \rightarrow k[x]/\mathfrak{m}:=K \rightarrow 0.$$
where $K$ is a field. Hence a unit in $R$ is an element $z$ not in the maximal ideal $\mathfrak{n}$. The ring $R$ has a basis $\{1,z,z^2,z^3\}$ where $z:=\overline{x}$ is the equivalence class of $x$ in $R$. The maximal ideal $\mathfrak{n}$ is the principal ideal generated by the element $t:=z^2+z+1$. Hence any element $s$ in $R$ may be written as
$$(1)s:= (a_1+a_2z)+ (a_3+a_4z)(z^2+z+1)$$
with $a_i \in k$. Hence a unit in $R$ is an element $w:=a_1+a_2z$ with $a_i \in k$ and $a_1\neq 0$.
You may prove $(1)$ as follows: Let $s:= a+bz+cz^2+dz^3$ with $a,b,c,d\in k$. It follows
$$ s=a+bz + (c+dz)(z^2+z+1-(z+1)) =$$
$$a+bz + (c+dz)(z^2+z+1)-(c+dz)(z+1).$$
It follows
$$ -(c+dz)(z+1)=d-c-cz-d(z^2+z+1)$$
and hence
$$s=a-c+d+(b-c)z +(c-d+dz)(z^2+z+1).$$
Hence any element $s\in R$ may be written on this form. The element $s$ is not in the maximal ideal iff $s=a_1+a_2z$ with $a_i\in k$ and $(a_1,a_2) \neq (0,0)$.
Note: If $(R, \mathfrak{n})$ is a local ring and $z \in R-\mathfrak{n}$ is any element, it follows $z$ is a unit: Else $(z)+\mathfrak{n}$ is a strict ideal containing $\mathfrak{n}$.