I'm a bit confused on Artin's proof of Corollary 2.3.9. After defining the $\gcd$ of integers $d = \gcd(a,b)$ by $\mathbb{Z} d = \mathbb{Z} a + \mathbb{Z} b$ and $m = \text{lcm}(a,b)$ by $\mathbb{Z} m = \mathbb{Z} a \cap \mathbb{Z} b$, he proves:
Let $d = \gcd(a,b)$ and $m = \text{lcm}(a,b)$ be the greatest common divisor and least common multiple of a pair $a,b$ of positive integers, respectively. Then $ab = dm$.
I'm going to try to paraphrase his proof in my own words. What's causing me the greatest confusion is that he seems to make use of division, which isn't defined on the integers. If $a \mid b$, it makes sense that $\frac{b}{a}$ is an integer, but I don't think I can say $\frac{a}{b} = ab^{-1}$ because $b^{-1}$ only exists in $\mathbb{Z}$ if $b = \pm 1$. b
By definition, we have $d \mid a$ and $d \mid b$, so $\frac{a}{d}$ and $\frac{b}{d}$ are integers. So we can say, in $\mathbb{Z}$, that $a$ divides the integer $\frac{ab}{d}$ and $b$ divides the integer $\frac{ab}{d}$. As $\frac{ab}{d}$ is divisible by $a$ and $b$, it is divisible by $m$, so there exists $k \in \mathbb{Z}$ such that $mk = \frac{ab}{d}$. Multiplying both sides by $d$ gives $(dm)k = ab$, so $dm \mid ab$. We will now show that $ab \mid dm$. As a consequence of the fact that $\mathbb{Z} d = \mathbb{Z} a + \mathbb{Z} b$, there exist $r,s \in \mathbb{Z}$ such that $d = ra + sb$. Multiplying by $m$, we obtain $dm = ram + sbm$. As $m$ is a multiple of $b$, we have $\frac{m}{b} \in \mathbb{Z}$, hence $\frac{rm}{b} \in \mathbb{Z}$, so $(ab) \cdot \frac{rm}{b} = ram$, so $ram$ is divisible by $ab$. Analogously, $m$ is a multiple of $a$, so $\frac{m}{a} \in \mathbb{Z}$, hence $\frac{sm}{a} \in \mathbb{Z}$, so $(ab) \cdot \frac{sm}{a} = sbm$, so $ab$ divides $sbm$. As $ab$ divides $ram$ and $sbm$, it divides their sum, so $ab$ divides $dm$. As $ab \mid dm$ and $dm \mid ab$, and $ab,dm$ are both positive, we conclude that $ab = dm$.
I think I'm ok with the mechanics, but there are several points where I use division, and even though I'm ultimately still working with integers, I'm not certain this is allowed.