Professional Documents
Culture Documents
Theorem 1.1. Let a and b be integers with d = (a, b). The equation ax + by = c, has
no integral solutions if d - c. If d|c, then there are infinitely many integral solutions.
Moreover, if x = x0 , y = y0 is a particular solution of the equation, then all solutions
are given by
x = x0 + (b/d)n, y = y0 − (a/d)n,
where n is an arbitrary integer.
Proof. Assume that x, y ∈ Z such that ax + by = c. Then, since d|a and d|b, it follows
that d|c. Hence if d - c, there are no integral solutions of the equation.
Now assume that d|c. Since d = (a, b), there are integers s, t with d = as + bt.
We can find an integer e such that c = de. Therefore
1
Prof A. Munagi Linear Diophantine Equations MATH4024-Number Theory
To show that there are infinitely many solutions, let x = x0 + (b/d)n and y =
y0 − (a/d)n for any n ∈ Z. Then (x, y) is a solution because
But we know that (a/d, b/d) = 1. It follows that (a/d)|(y0 − y). So there is an integer
n such that y0 − y = (a/d)n, that is, y = y0 − (a/d)n.
Substituting this value of y into a(x − x0 ) = b(y0 − y) gives a(x − x0 ) = b(a/dn), which
implies that x = x0 + (b/d)n.
2
Prof A. Munagi Linear Diophantine Equations MATH4024-Number Theory
Interpretations of these solutions should be clear; for example, (x, y) = (8, 7) means
that we could purchase 8 copies of 200-rand checks and 7 copies of 500-rand checks,
etc, (note that 200 · 8 + 500 · 7 = 5100) . . . .
Exercise 1. Find all solutions for each of the following Diophantine equations.
(a) 2x + 5y = 11
(b) 21x + 14y = 147
(c) 102x + 222y = 1256
Exercise 2. A student returning from Europe changes his French francs and Swiss
francs into SA money. If he receives R1706 and has received 19 cents for each French
francs and 59 cents for each Swiss franc, how much of each type of currency did he
exchange?
Exercise 3. A postal clerk has only 28- and 35-rand stamps to sell. What combinations
of these may be used to mail a package requiring postage of exactly each of the following
amounts?
(a) R350 (b) R400 (c) R777.
Exercise 5. Find the solutions of the equation 91x + 221y = 1053. Are there solutions
in positive integers?