Solution (source code)

= Solution

A <Euclidean domain> is a commutative <integral domain> $R$ with a function $\delta:R\setminus\{0\}\to\mathbb Z_{\geq0}$ such that, for $a,b\in R$ with $b\ne0$, there are $q,r\in R$ satisfying $a=qb+r$, where either $r=0$ or $\delta(r)<\delta(b)$. One may also impose the usual monotonicity $\delta(a)\leq\delta(ab)$ for nonzero $a,b$; the example below has it.

\b[The <integers> form a <Euclidean domain> that is not a <field>.] Use $\delta(a)=|a|$. <Integer> division by $|b|$ supplies a remainder with $0\leq r<|b|$, and changing the sign of the quotient handles negative $b$. The <integers> are an <integral domain>, while $2$ has no multiplicative inverse in them. This verifies both the Euclidean property and the failure to be a <field>.