$\mathbb{Z}[i]$ consists of exactly the numbers of the field extension $\mathbb{Q}(i)|\mathbb{Q}$, which fulfull the normed equation $x^2+ax+b=0$ with coefficients $a,b\in\mathbb{Z}$.
Proof: An element $\alpha=c+id\in\mathbb{Q}(i)$ is root of the polynomial $x^2+ax+b\in\mathbb{Q}[x]$ with $a=-2c, b=c^2+d^2$.
If $c$ and $d$ are integers, then $a$ and $b$ are. If in reverse $a$ and $b$ are integers, so are $2c$ and $2d$. Because $(2c)^2+(2d)^2=4b\equiv 0\mod 4$ hence $(2c)^2\equiv (2d)^2\equiv 0\mod 4$, since quadratic integers are either $\equiv 0$ or $\equiv 1$. So $c$ and $d$ are integers.
This is taken from the german edition of "Algebraic Number Theory" by Jürgen Neukirch. I hope I translated sufficiently.
In my opinion this proof is pretty short, so I do not understand it in detail. I was not able to fix everything, so I would like to ask for your advice.
Also I am actually a little bit confused. I understand and read the proof that there is an equivalence to be shown.
So:
The elements of $\mathbb{Z}[i]$ are the elements of $\mathbb{Q}(i)|\mathbb{Q}$ which solve the equation $x^2+ax+b=0$ with integer coefficients.
If an element of $\mathbb{Q}(i)|\mathbb{Q}$ solves $x^2+ax+b=0$ then this element is in $\mathbb{Z}[i]$.
The conclusion "An element $\alpha=c+id\in\mathbb{Q}(i)$ is root of the polynomial $x^2+ax+b\in\mathbb{Q}[x]$ with $a=-2c, b=c^2+d^2$." needs more elobaration in my opinion.
It is clear what to do:
$(c+id)^2+a(c+id)+b=0 \Leftrightarrow\quad$ $c^2-d^2+ac+b=0$ and $ad+2cd=0$, when we compare imaginary part and real part.
I see that the result in the proof comes from the case where $d\neq 0$. So I wanted to know, why $d=0$ does not occur.
We get $c^2+ac+b=0$. With the quadratic formula $c_{1,2}=-\frac{a}{2}\pm\sqrt{\left(\frac{a}{2}\right)^2-b}$.
I tried to show that the RHS can not be an element of $\mathbb{Q}$, but I was not able too.
Can you provide some more elaboration to this proof? Also what seems to be the other implication "$\Leftarrow$" puzzles me.
Thanks in advance.