A square root of −4 modulo the ideal generated by $(x^2 + 1)^2$ Let $S= \mathbb R[x]$ denote the polynomial ring in one variable over the field $\mathbb R$ of real numbers. Find a
monic polynomial of least degree in $S$ that is a square root of $−4$ modulo the ideal $I$ generated by
$(x^2 + 1)^2$.
Let $p(x)$ be a monic polynomial that is a square root of $−4$ modulo the ideal $I$.
Then ${(p(x))}^2 = -4 + \langle(x^2 + 1)^2\rangle$.
$p(x)$ is of the form $a_0 + a_1x + a_2x^2 + x^3$. Thus, $(a_0 +a_1x + a_2x^2 + x^3)^2 = -4 + \langle (x^2 + 1)^2\rangle$.
Solving this rigorously (reducing and equating) may get such $p(x)$.
But Is there any other simple way?

The basis $1,x,x^2,x^3$ has no relation to $(x^2+1)^2$, which is the polynomial which you are trying to go modulo. Instead, what is usually done is traditionally called "lifting" as suggested in the comments by Jyrki. (So it wasn't misread, it was a hint).
The idea of lifting is simple : if an equation is true modulo $p(x)$, then it's also true modulo $q(x)$ where $q$ is a factor of $p$. Therefore, it should be possible to solve the equation modulo $q(x)$ and then "lift" it to a solution modulo $p(x)$, using the solution obtained modulo $q(x)$.
In this scenario, $x^2+1$ is a factor of $(x^2+1)^2$, so you want to first solve this equation modulo $x^2+1$, and then modulo $(x^2+1)^2$, by lifting.

Let's first solve $q(x)^2 = -4 \pmod{x^2+1}$. Now, here the degree of the polynomial $q$ can be chosen to be at most $1$ i.e. $q(x) = ax+b$ for some $a,b$. Then, note that $(ax+b)^2 = a^2x^2+2abx+b^2$ , which modulo $x^2+1$ becomes $2abx + (b^2-a^2)$. Thus, $2abx + (b^2-a^2) = 4 \pmod{x^2+1}$, hence $2ab=0$ and $b^2-a^2 = 4$. We easily get $b=0,a=\pm 2$ from here. Sticking with $a=2$ gives us one of the solutions, $q(x) = 2x$. (And the set of all solutions would be $2x$ or $-2x$ modulo $x^2+1$).
Now, suppose that $p(x)$ satisfies $p(x)^2 = -4 \pmod{(x^2+1)^2}$. Then, $p$ also satisfies $p(x)^2 = -4 \pmod{x^2+1}$, but then we've already seen that one solution to this is $q(x)$! Therefore, there could be a solution $p(x) \equiv q(x) \equiv 2x\pmod{x^2+1}$. In fact, there is one. Similarly, there will also be a solution for $p(x) \equiv -2x \pmod{x^2+1}$, as I urge you to calculate (later on, you can see the similarity between the solution you get from here, and the solution I'm about to derive : they will be $-1$ times each other).
Thus, suppose that $p(x) = (ax+b)(x^2+1) - 2x$ for some $a,b$ (following the realization that $p$ has degree at most $3$). We need this to satisfy $p(x)^2 = -4 \pmod{(x^2+1)^2}$. While squaring $p(x)$, the entire $(ax+b)(x^2+1)$ term squares to something that is $0$ modulo $(x^2+1)^2$. Neglecting this gives $$
2(ax+b)(x^2+1)(-2x) + (4x^2) = -4 \pmod{(x^2+1)^2}
$$
which ... we don't need to expand and make life complicated! Why? Because taking the $-4$ to the other side :
$$
2(ax+b)(x^2+1)(-2x) + (4x^2 +4) = 0  \pmod{(x^2+1)^2} \\
\implies 2(ax+b)(-2x)(x^2+1)+4(x^2+1)=0 \pmod{(x^2+1)^2} \\
\implies (x^2+1) \left[(2(ax+b)(-2x) + 4)\right] = 0 \pmod{(x^2+1)^2}
$$
which happens if and only if
$$
(2(ax+b)(-2x) + 4) = 0 \pmod{x^2+1}
$$
and expanding this out gives us $-4ax^2-4bx + 4 = 0 \pmod{x^2+1}$, which then simplifies to $-4bx + 4a+4 =0 \pmod{x^2+1}$. As the LHS is linear, this can occur only if $b = 0$ and $a = -1$. Thus, the final $p(x)$ is $-x(x^2+1) - 2x = -x^3-3x$.
To confirm this, one can check that $(-x^3-3x)^2 =-4 \pmod{(x^2+1)^2}$.
The other solution, will in fact be $x^3+3x$, which you can note is a different element modulo $(x^2+1)^2$. Our analysis confirms that these are the only two solutions.
