Euclidean Domain is GCD Domain

Theorem
Let $\left({D, +, \times}\right)$ be a Euclidean domain.

Then any two elements $a, b \in D$ have a greatest common divisor $d$ such that:
 * $d \mathrel \backslash a \land d \mathrel \backslash b$
 * $x \mathrel \backslash a \land x \mathrel \backslash b \implies x \mathrel \backslash d$

and $d$ is written $\gcd \left\{{a, b}\right\}$.

For any $a, b \in D$:
 * $\exists s, t \in D: s a + t b = d$

Any two greatest common divisors of any $a, b$ are associates.

Proof
Let $a, b \in D$.

Let $U \subseteq D$ be the set of all elements $h a + k b$ of $D$ where $h, k \in D$.

Then $U$ is an ideal of $D$. Note that $U = (a) + (b)$ where $(a)$ and $(b)$ are Principal Ideal.

By Sum of Ideals is Ideal, $U$ is an ideal.

By Euclidean Domain is Principal Ideal Domain, $U$ is a principal ideal, $\left({d}\right)$ say.

As $a, b \in U$ it follows that $d$ is a divisor of $a$ and $b$, i.e.:


 * $d \mathrel \backslash a \land d \mathrel \backslash b$

Since $d$ itself is in $U$, we have:
 * $\exists s, t \in D: s a + t b = d$

So:
 * $x \mathrel \backslash a \land x \mathrel \backslash b \implies x \mathrel \backslash d$

by Common Divisor in Euclidean Domain Divides Linear Combination.

So $d$ is a greatest common divisor of $a$ and $b$.

If $d$ and $d'$ are both greatest common divisors of $a$ and $b$, then $d \mathrel \backslash a \land d \mathrel \backslash b$ and so $d \mathrel \backslash d'$.

Similarly $d' \mathrel \backslash d$.

So $d$ and $d'$ are associates.