<s>[INST] Solving the equation $X^2 + (3 +i)X + 1 +i =0$ I have to find the roots of the equation
$$X^2 + (3 +i)X + 1 +i =0.$$
The first step is to find the discrimant which is $4 + 2i$. Then, I assume that the square root of the discriminant is in the form of $a+bi$, so we have to solve the below system
$$a^2-b^2=4\qquad\text{ and }\qquad ab=1.$$
How can I solve the above system ? Please do not provide another solution (e.g using trigonometric form)
 [/INST] Hint:
Multiplying by $a^2$,
$$a^2-b^2=4\land ab=1\implies a^4-a^2b^2=a^4-1=4a^2$$ and you get a biquadratic equation in $a$.

More generally, the square root of $u+iv$ is obtained by solving
$$\begin{cases}a^2-b^2&=u,\\2ab&=v\end{cases}$$ and
$$a^4-ua^2-\frac{v^2}4=0.$$
So,
$$a^2=\frac{\sqrt{u^2+v^2}+u}2$$ (the negative root must be rejected) and similarly
$$b^2=\frac{\sqrt{u^2+v^2}-u}2.$$
After taking the square roots, there are two solutions such that the sign of $ab$ matches that of $v$.
</s>