Finding all complex numbers $z$ for which $z^2+az+a^2$ and $az^2+a^2z$ are both real During my course on complex numbers, I found this problem: Let $a\in \Bbb C$. Find all complex numbers $z$ for which $z^2+az+a^2$ and $az^2+a^2z$ are simultaneously real numbers.
 A: Write $z:=w-{a\over2}$. Then
$$z^2+az+a^2=w^2+{3\over4}a^2,\qquad az(z+a)=a\left(w^2-{a^2\over4}\right)\ .$$
Put $w^2=:W$. Then we want
$$W+{3\over4}a^2\in{\mathbb R},\qquad a\left(W-{a^2\over4}\right)\in{\mathbb R}\ .$$
The first of these equations implies $W=t-{3\over4}a^2$ for some $t\in{\mathbb R}$, and from the second it then follows that
$$a(t-a^2)=\bar a(t-\bar a^2)\ ,$$
or
$$(a-\bar a)t=(a-\bar a)(a^2+a\bar a+\bar a^2)\ .\tag{1}$$
We now have to distinguish the cases (i) $a\in{\mathbb R}$ and (ii) $a\notin{\mathbb R}$.
In case (i) the condition $(1)$ is fulfilled for arbitrary $t\in{\mathbb R}$, and it then follows that $W\in{\mathbb R}$ is arbitrary. This in turn implies $w\in X:={\mathbb R}\cup i{\mathbb R}$, and all $z\in X-{a\over2}$ fulfill the given conditions.
In case (ii) we may divide $(1)$ by $a-\bar a\ne0$ and obtain the single admissible $t$-value $t=a^2+a\bar a+\bar a^2$. This then leads to
$$W={a^2\over4}+a\bar a+\bar a^2\ne0\ ,$$
so that we obtain exactly two admissible $z$, namely $z=\pm\sqrt{W}-{\displaystyle{a\over2}}$.
