GCD of an empty set?

Yes, the convention $\gcd \emptyset =0 $ makes sense.

Every integer divides all elements of $\emptyset$ thus the "greatest" among them is $0$, when "greatest" is understood with respect to the partial order given by divisibility, which is the appropriate notion of 'size' in this context.


Define $\gcd(S)$ to be natural number $g$ (if it exists) such that:

  1. $g \mid x$ for every $x \in S$.

  2. For any $d$ such that $d \mid x$ for every $x \in S$, we have $d \mid g$.

Then indeed $\gcd(\{\}) = 0$, and moreover it can be proven that $\gcd(S)$ exists for every set $S \subset \mathbb{Z}$.

Also $\gcd(\{0,0\}) = 0$. (This differs from the other common definition of $\gcd$ as the greatest common divisor in terms of size, which would simply stipulate that $\gcd(0,0)$ is undefined.)