|
| 1 | +--- |
| 2 | +sidebar_position: 1 |
| 3 | +--- |
| 4 | + |
| 5 | +# GCD Properties |
| 6 | + |
| 7 | +- **Blueprint of Numbers:** The GCD (Greatest Common Divisor) of a set of numbers can be thought of as a blueprint of those numbers. If you keep adding the GCD, you can make all numbers that belong to that set. |
| 8 | + |
| 9 | +- **Common Divisors:** Every common divisor of $a$ and $b$ is a divisor of $\gcd(a,b)$. |
| 10 | + |
| 11 | +- **Linear Combination:** $\gcd(a,b)$, where both $a$ and $b$ are non-zero, can also be defined as the smallest positive integer $d$ which can be expressed as a linear combination of $a$ and $b$ in the form |
| 12 | + |
| 13 | + $$ |
| 14 | + d = a \cdot p + b \cdot q |
| 15 | + $$ |
| 16 | + |
| 17 | + where both $p$ and $q$ are integers. |
| 18 | + |
| 19 | +- **GCD with Zero:** |
| 20 | + |
| 21 | + $$ |
| 22 | + \gcd(a, 0) = |a|, \text{ for } a \neq 0 |
| 23 | + $$ |
| 24 | + |
| 25 | + since any number is a divisor of 0, and the greatest divisor of $a$ is $|a|$. |
| 26 | + |
| 27 | +- **Division Property:** If $a$ divides $b \cdot c$ and $\gcd(a,b) = d$, then |
| 28 | + |
| 29 | + $$ |
| 30 | + \frac{a}{d} \text{ divides } c |
| 31 | + $$ |
| 32 | + |
| 33 | +- **Scaling Property:** If $m$ is a non-negative integer, then |
| 34 | + |
| 35 | + $$ |
| 36 | + \gcd(m \cdot a, m \cdot b) = m \cdot \gcd(a, b) |
| 37 | + $$ |
| 38 | + |
| 39 | + It also follows from this property that if $\gcd(a,b) = g$, then |
| 40 | + |
| 41 | + $$ |
| 42 | + \frac{a}{g} \text{ and } \frac{b}{g} \text{ should be coprime.} |
| 43 | + $$ |
| 44 | + |
| 45 | +- **Translation Property:** If $m$ is any integer, |
| 46 | + |
| 47 | + $$ |
| 48 | + \gcd(a,b) = \gcd(a + m \cdot b, b) |
| 49 | + $$ |
| 50 | + |
| 51 | +- **Euclidean Algorithm:** The GCD can be found using the Euclidean algorithm: |
| 52 | + |
| 53 | + $$ |
| 54 | + \gcd(a, b) = \gcd(b, a \mod b) |
| 55 | + $$ |
| 56 | + |
| 57 | +- **Common Divisor Scaling:** If $m$ is a positive common divisor of $a$ and $b$, then |
| 58 | + |
| 59 | + $$ |
| 60 | + \gcd\left(\frac{a}{m}, \frac{b}{m}\right) = \frac{\gcd(a, b)}{m} |
| 61 | + $$ |
| 62 | + |
| 63 | +- **Multiplicative Function:** The GCD is a multiplicative function. That is, if $a_1$ and $a_2$ are coprime, |
| 64 | + |
| 65 | + $$ |
| 66 | + \gcd(a_1 \cdot a_2, b) = \gcd(a_1, b) \cdot \gcd(a_2, b) |
| 67 | + $$ |
| 68 | + |
| 69 | + In particular, recalling that GCD is a positive integer-valued function, we obtain that |
| 70 | + |
| 71 | + $$ |
| 72 | + \gcd(a, b \cdot c) = 1 \text{ if and only if } \gcd(a, b) = 1 \text{ and } \gcd(a, c) = 1. |
| 73 | + $$ |
| 74 | + |
| 75 | + If the GCD is one, then they need not be coprime to distribute the GCD; moreover, each GCD individually should also be 1. |
| 76 | + |
| 77 | +- **Commutative Property:** The GCD is a commutative function: |
| 78 | + |
| 79 | + $$ |
| 80 | + \gcd(a, b) = \gcd(b, a) |
| 81 | + $$ |
| 82 | + |
| 83 | +- **Associative Property:** The GCD is an associative function: |
| 84 | + |
| 85 | + $$ |
| 86 | + \gcd(a, \gcd(b, c)) = \gcd(\gcd(a, b), c) |
| 87 | + $$ |
| 88 | + |
| 89 | + Thus, |
| 90 | + |
| 91 | + $$ |
| 92 | + \gcd(a, b, c, \ldots) |
| 93 | + $$ |
| 94 | + |
| 95 | + can be used to denote the GCD of multiple arguments. |
| 96 | + |
| 97 | +- **Relation with LCM:** $\gcd(a, b)$ is closely related to the least common multiple $\operatorname{lcm}(a, b)$: we have |
| 98 | + |
| 99 | + |
| 100 | + $$ |
| 101 | + \gcd(a, b) \cdot \operatorname{lcm}(a, b) = |a \cdot b| |
| 102 | + $$ |
| 103 | +- **the Subtraction Property of GCD or Substitution Lemma:** It forms one of the foundational principles of the Euclidean Algorithm, which leverages the idea of subtracting the smaller number from the larger one to reduce the problem of finding the GCD to smaller numbers. |
| 104 | +In general terms, this property expresses that the GCD remains unchanged when multiples of one number are subtracted from the other. Thus, we can state: |
| 105 | + |
| 106 | + $$ |
| 107 | + \gcd(a, b) = \gcd(a - b, b) |
| 108 | + $$ |
| 109 | + |
| 110 | +- **Distributivity Versions:** The following versions of distributivity hold true: |
| 111 | + |
| 112 | + $$ |
| 113 | + \gcd(a, \operatorname{lcm}(b, c)) = \operatorname{lcm}(\gcd(a, b), \gcd(a, c)) |
| 114 | + $$ |
| 115 | + |
| 116 | + $$ |
| 117 | + \operatorname{lcm}(a, \gcd(b, c)) = \gcd(\operatorname{lcm}(a, b), \operatorname{lcm}(a, c)) |
| 118 | + $$ |
| 119 | + |
| 120 | +- **Prime Factorization:** If we have the unique prime factorizations of $a = p_1^{e_1} p_2^{e_2} \cdots p_m^{e_m}$ and $b = p_1^{f_1} p_2^{f_2} \cdots p_m^{f_m}$, where $e_i \geq 0$ and $f_i \geq 0$, then the GCD of $a$ and $b$ is: |
| 121 | + |
| 122 | + $$ |
| 123 | + \gcd(a,b) = p_1^{\min(e_1,f_1)} p_2^{\min(e_2,f_2)} \cdots p_m^{\min(e_m,f_m)} |
| 124 | + $$ |
| 125 | + |
| 126 | +- **Cartesian Coordinate System Interpretation:** In a Cartesian coordinate system, $\gcd(a, b)$ can be interpreted as the number of segments between points with integral coordinates on the straight line segment joining the points $(0, 0)$ and $(a, b)$. |
| 127 | + |
| 128 | +- **Euclidean Algorithm in Base $n$:** For non-negative integers $a$ and $b$, where $a$ and $b$ are not both zero, provable by considering the Euclidean algorithm in base $n$, it simply states that: |
| 129 | + |
| 130 | + $$ |
| 131 | + \gcd(n^a - 1, n^b - 1) = n^{\gcd(a, b)} - 1 |
| 132 | + $$ |
| 133 | + |
| 134 | + If you want an informal proof, think of numbers in base 2. We are calculating GCDs of numbers which contain all continuous 1s in their binary representations. For example: 001111 and 000011; their GCD can be the greatest common length, which in this case is 2. Thus, the GCD becomes 000011. Think of numbers in terms of length; maybe you get the idea. |
| 135 | + |
| 136 | +- **Euler's Totient Function Identity:** An identity involving Euler's totient function: |
| 137 | + |
| 138 | + $$ |
| 139 | + \gcd(a,b) = \sum \phi(k) |
| 140 | + $$ |
| 141 | + |
| 142 | + where $k$ are all common divisors of $a$ and $b$. |
| 143 | + |
0 commit comments