The greatest common divisor of a set of integers is the largest number that divides each integer in the set. We denote the greatest common divisor by . We can attempt to find this value by listing all divisors of the integers and finding the largest divisor. However, such a procedure can get tedious.
If we know the prime factorization, then there is a simpler approach. If the prime factorizations of and are
then the GCD of the numbers is equal to
A similar formula holds for finding the GCD of several integers, by taking the smallest exponent for each prime.
Similarly, the least common multiple of a set of integers is the smallest (positive) number which is a multiple of each integer in the set. We denote this value as . We can attempt to find this value by listing all multiples of the integers in the set, and then finding the one which is the smallest.
However, as above, if we know the prime factorization, then computing the least common multiple is much simpler:
Note: Another approach to find the GCD of 2 numbers is through the Euclidean Algorithm.
1. Show that the GCD of 2 numbers is indeed equal to
Solution: Clearly, is a divisor of both and , and so .
We will now show that there is no greater common divisor, by considering the prime factorization of . Any prime divisor of is also a prime divisor of and . Hence, it is sufficient for us to simply consider the primes that divide or .
Given any prime that divides or , let and be the largest powers of that divide and respectively. Note that we could have . Clearly,
and , hence . Furthermore, since does not divide either or by construction, thus does not divide . Hence, .
As such, we have .
Note: You can use a similar method to prove the claim for .
2. Show that .
First, we show that . Without loss of generality, . Hence, and , thus .
Applying this to each of the pairs , we get that
3. Given that and are 2 integers such that and , what are the values of and ?
Let and .
Let and where by construction.
Since , we get that . Hence, we have . WLOG, we may assume that , and thus .
Since , thus . Thus, .