Groups of units of $\mathbb{Z}\left[\frac{1+\sqrt{-3}}{2}\right]$ On page 230 of Dummit and Foote's Abstract Algebra, they say: the units of $\mathbb{Z}\left[\frac{1+\sqrt{-3}}{2}\right]$ are determined by the integers $a,b$ with $a^2+ab+b^2=\pm1$ i.e. with $(2a+b)^2+3b^2=4$, from which is is easy to see the group of units is a group of order $6$ given by $\{\pm1,\pm\rho,\pm\rho^2\}$ where $\rho=\frac{-1+\sqrt{-3}}{2}$.
First, why change the characterization of unit from integers solutions of $a^2+ab+b^2=\pm1$ to integers solutions of $(2a+b)^2+3b^2=4$? How did they arrive at their answer?

The reason you may want to change it from $a^2+ab+b^2=\pm 1$ to $(2a+b)^2+3b^2 = \pm 4$ is because the latter is a sum of squares, so this immediately cuts down on the possibilities: for one thing, you can tell that the answer must be $4$ and not $-4$ (sum of squares), that you must have $|2a+b|\leq 2$ and $3b^2\leq 4$; so that $b$ must be either $0$, $1$, or $-1$, etc.  Whereas in $a^2+ab+b^2 = \pm 1$, $ab$ may be negative, which makes searching for solutions somewhat more complicated. (Not much, but things are not so quickly evident).
To go from $a^2+ab+b^2 = \pm 1$ to $(2a+b)^2 + 3b^2=\pm 4$, multiply by $4$ and complete the square:
$$\begin{align*}
a^2 + ab + b^2 &= \pm 1\\
4a^2 + 4ab + 4b^2 &= \pm 4\\
(2a)^2 + 2(2a)b + b^2 +3b^2 &=\pm 4\\
(2a+b)^2 + 3b^2 &= \pm 4
\end{align*}$$
Alternatively, start by completing the square and then clear denominators:
$$\begin{align*}
a^2 + ab + b^2 &= \pm1\\
\left(a+\frac{1}{2}b\right)^2 + \frac{3}{4}b^2 &=\pm 1\\
\left(2a+b\right)^2 + 3b^2 &=\pm 4.
\end{align*}$$
