Maths Olympiad Prep

Library / /16 of 22

Number theory Difficulty 7.0 National olympiad Prove it South Africa

Let aa, bb, and cc be nonzero integers. Show that there exists an integer kk such that
gcd(a+kb,c)=gcd(a,b,c). \gcd(a + kb, c) = \gcd(a, b, c).
(Note: 'gcd' stands for 'greatest common divisor')

Solutions — 2

Solution 1

We may assume that aa, bb, cc are all positive, since if aa, bb, cc are all positive, and gcd(a+kb,c)=gcd(a,b,c)\gcd(a + kb, c) = \gcd(a, b, c) for some integer kk, then we immediately have gcd(a+(k)b,±c)=gcd(a+k(b),±c)=gcd(a+(k)(b),±c)=gcd(±a,±b,±c)\gcd(-a + (-k)b, \pm c) = \gcd(-a + k(-b), \pm c) = \gcd(a + (-k)(-b), \pm c) = \gcd(\pm a, \pm b, \pm c). Moreover, if at least one of aa, bb and cc is equal to 11, then the result follows immediately: if a=1a = 1 or c=1c = 1, choose k=0k = 0; otherwise, if b=1b = 1, choose k=1ak = 1 - a. In all these cases, gcd(a+kb,c)=gcd(a,b,c)=1\gcd(a + kb, c) = \gcd(a, b, c) = 1.

Henceforth, assume that all of aa, bb and cc are greater than 11. This implies that there is a list of prime numbers p1,p2,,pnp_1, p_2, \dots, p_n and non-negative integers αi,βi,γi\alpha_i, \beta_i, \gamma_i, i=1,2,,ni = 1, 2, \dots, n, such that
a=p1α1p2α2pnαn a = p_1^{\alpha_1} p_2^{\alpha_2} \cdots p_n^{\alpha_n}
b=p1β1p2β2pnβn b = p_1^{\beta_1} p_2^{\beta_2} \cdots p_n^{\beta_n}
c=p1γ1p2γ2pnγn. c = p_1^{\gamma_1} p_2^{\gamma_2} \cdots p_n^{\gamma_n}.
Let us first assume that gcd(a,b,c)=1\gcd(a, b, c) = 1. This implies that, for each i{1,2,,n}i \in \{1, 2, \dots, n\}, not all three of αi,βi\alpha_i, \beta_i and γi\gamma_i are positive. We may also assume that, for each i{1,2,,n}i \in \{1, 2, \dots, n\}, not all three of αi,βi\alpha_i, \beta_i and γi\gamma_i are 00 (otherwise we could simply discard the primes pip_i for which this happens). We now call a prime pip_i a *one-prime* if exactly one of αi,βi\alpha_i, \beta_i and γi\gamma_i is positive. Likewise, we call a prime pip_i a *two-prime* if exactly two of αi,βi\alpha_i, \beta_i and γi\gamma_i are positive. Let E={pi1,pi2,,pit}E = \{p_{i_1}, p_{i_2}, \dots, p_{i_t}\} be the complete list of one-primes among p1,p2,,pnp_1, p_2, \dots, p_n. If there are no one-primes in this list, put E=E = \emptyset. Let
k={pi1pi2pitif E1if E=. k = \begin{cases} p_{i_1} p_{i_2} \cdots p_{i_t} & \text{if } E \neq \emptyset \\ 1 & \text{if } E = \emptyset. \end{cases}
We show that, for this kk, gcd(a+kb,c)=gcd(a,b,c)=1\gcd(a + kb, c) = \gcd(a, b, c) = 1.
Since gcd(a+kb,c)\gcd(a + kb, c) is a divisor of cc, the only possible way that gcd(a+kb,c)>1\gcd(a + kb, c) > 1 is that it is divisible by at least one of p1,p2,,pnp_1, p_2, \dots, p_n. We show that this is not the case.

Firstly, consider any pijEp_{i_j} \in E (if EE \neq \emptyset). For the triple (αij,βij,γij)(\alpha_{i_j}, \beta_{i_j}, \gamma_{i_j}) there are three possibilities:

I. (αij,βij,γij)=(αij,0,0)(\alpha_{i_j}, \beta_{i_j}, \gamma_{i_j}) = (\alpha_{i_j}, 0, 0), with αij>0\alpha_{i_j} > 0. Here, pijp_{i_j} does not divide cc.

II. (αij,βij,γij)=(0,βij,0)(\alpha_{i_j}, \beta_{i_j}, \gamma_{i_j}) = (0, \beta_{i_j}, 0), with βij>0\beta_{i_j} > 0. Here, again, pijp_{i_j} does not divide cc.

III. (αij,βij,γij)=(0,0,γij)(\alpha_{i_j}, \beta_{i_j}, \gamma_{i_j}) = (0, 0, \gamma_{i_j}), with γij>0\gamma_{i_j} > 0. Here, pijp_{i_j} does not divide a+kba + kb (where k=pi1pi2pitk = p_{i_1}p_{i_2}\cdots p_{i_t}).

So gcd(a+kb,c)\gcd(a+kb, c) is not divisible by any of the one-primes.

Secondly, let prp_r denote any of the two-primes. For the triple (αr,βr,γr)(\alpha_r, \beta_r, \gamma_r) there are three possibilities:

I'. (αr,βr,γr)=(αr,βr,0)(\alpha_r, \beta_r, \gamma_r) = (\alpha_r, \beta_r, 0), with αr,βr>0\alpha_r, \beta_r > 0. Here, prp_r does not divide cc.

II'. (αr,βr,γr)=(αr,0,γr)(\alpha_r, \beta_r, \gamma_r) = (\alpha_r, 0, \gamma_r), with αr,γr>0\alpha_r, \gamma_r > 0. Here, prp_r does not divide a+kba+kb (recall that kk is not divisible by prp_r).

III'. (αr,βr,γr)=(0,βr,γr)(\alpha_r, \beta_r, \gamma_r) = (0, \beta_r, \gamma_r), with βr,γr>0\beta_r, \gamma_r > 0. Here, again, prp_r does not divide a+kba+kb.

It follows that gcd(a+kb,c)=1=gcd(a,b,c)\gcd(a+kb, c) = 1 = \gcd(a, b, c).

Finally, if gcd(a,b,c)=d>1\gcd(a, b, c) = d > 1, then gcd(ad,bd,cd)=1\gcd(\frac{a}{d}, \frac{b}{d}, \frac{c}{d}) = 1, and from the above, there exists an integer kk such that gcd(ad+kbd,cd)=1=gcd(ad,bd,cd)\gcd(\frac{a}{d} + k \cdot \frac{b}{d}, \frac{c}{d}) = 1 = \gcd(\frac{a}{d}, \frac{b}{d}, \frac{c}{d}). Multiplying both sides by dd gives gcd(a+kb,c)=d=gcd(a,b,c)\gcd(a + kb, c) = d = \gcd(a, b, c), and we are done.

Solution 2

As in Solution 1, we may assume that gcd(a,b,c)=1\gcd(a, b, c) = 1. By Dirichlet's Theorem, the sequence sn=a/gcd(a,b)+nb/gcd(a,b)s_n = a/\gcd(a, b) + n \cdot b/\gcd(a, b), nNn \in \mathbb{N}, contains infinitely many primes. Let p=a/gcd(a,b)+kb/gcd(a,b)p = a/\gcd(a, b) + k \cdot b/\gcd(a, b), kNk \in \mathbb{N}, be prime, with p>cp > c. Then, as gcd(a,b)\gcd(a, b) and cc are relatively prime,
1=gcd(p,c)=gcd(pgcd(a,b),c)=gcd(a+kb,c). 1 = \gcd(p, c) = \gcd(p \cdot \gcd(a, b), c) = \gcd(a + kb, c).

Want a route through all this instead of an archive? The track puts 2,000 problems in a working order, from AMC 10 level to the IMO shortlist.

Source: MathNet, licensed CC-BY-4.0. Statement and solution reproduced as published; topic and difficulty added by this site.