Math 223 Number Theory, Spring `07 Homework 3 Solutions

advertisement
Math 223 Number Theory, Spring ’07
Homework 3 Solutions
(1) Use the definitions of an even and an odd integer to prove the following.
(a) The product of an even integer with any integer is an even integer.
(b) The sum of two odd integers is an even integer.
Solution:
(a) Suppose a is an even integer, so a = 2k for some k ∈ Z. Then if b is any integer, ab = 2kb =
2(kb) so ab is a multiple of 2 and hence even by definition.
(b) Suppose a and b are odd, so a = 2k + 1 and b = 2l + 1 for some k, l ∈ Z. Then a + b =
2k + 1 + 2l + 1 = 2(k + l + 1) and so a + b is even.
(2) Suppose r ∈ R, r 6= 1. Use induction to prove that, for any n ∈ N,
n
X
ri = 1 + r + r2 + r3 + · · · + rn =
i=0
rn+1 − 1
.
r−1
Solution: For the base case, we have
1+r =
1
X
ri =
i=0
r2 − 1
r1+1 − 1
=
= r + 1.
r−1
r−1
For the inductive hypothesis, assume
k
X
ri =
i=0
rk+1 − 1
.
r−1
For the inductive step, we then have
k+1
X
i=0
ri =
k
X
i=0
ri + rk+1 =
rk+1 − 1
rk+1 − 1 + rk+1 (r − 1)
rk+2 − 1
+ rk+1 =
=
r−1
r−1
r−1
which is precisely what we wanted to prove.
(3) Let F1 = F2 = 1 and define a sequence of numbers Fn , n ≥ 2, by
Fn = Fn−1 + Fn−2 .
A sequence whose nth term is defined in terms of previous ones is said to be defined recursively.
The sequence defined above is the famous Fibonacci sequence. Prove that F5n is divisible by 5 for
all n ≥ 1.
Solution: We prove this by induction. Since F5 = 2 + 3 = 5, it is divisible by 5. Now assume 5|F5k .
We want to prove 5|F5(k+1) . We have
F5(k+1) = F5k+5 = F5k+4 + F5k+3 = 2F5k+3 + F5k+2 = 2(F5k+2 + F5k+1 ) + F5k+2
= 3F5k+2 + 2F5k+1 = 3(F5k+1 + F5k ) + 2F5k+1 = 5F5k+1 + 3F5k .
Since the first summand has a factor of 5, it is divisible by 5. The second summand is divisible
by 5 by inductive hypothesis. Thus we know form class (and will be proved rigorously in problem
4(a) below) that the sum is also divisible by 5. But this sum is F5(k+1) .
(4) Suppose a, b, c, d ∈ Z and ai , ci ∈ Z for 1 ≤ i ≤ n.
(a) Suppose d|a and d|b. Prove d|(a + b) and d|(a − b).
(b) Suppose ∀ai , d|ai . Show d|
Pn
i=1 ci ai .
Explain why this generalizes part (a).
Solution:
(a) Since d|a and d|b, we have a = kd and b = ld for some k, l ∈ Z. Then a ± b = kd ± ld = (k ± l)d
so a ± b is a multiple of d. In other words, d|(a ± b).
(b) Since d|ai for all 1 ≤ i ≤ n, there exist ki ∈ Z, 1 ≤ i ≤ n, such that ai = ki d. Then
!
n
n
n
X
X
X
ci ai =
ci ki d = d
ci ai
i=1
i=1
i=1
Pn
and so i=1 ci ai is a multiple of d. Taking n = 2, c1 = 1 and c2 = ±1 reduces this problem to
part (a) (with a = a1 and b = a2 ).
(5) (5.1) Use the Euclidean Algorithm to compute
(a) gcd(12345, 67890)
(b) gcd(54321, 9876)
(It is ok to use a calculator on these problems.)
Solution:
(a) The Euclidean Algorithm is
67890 = 5 · 12345 + 6165
12345 = 2 · 6165 + 15
6165 = 411 · 15 + 0
So gcd(12345, 67890) = 15.
(b) (This problem was done in class.) The Euclidean Algorithm is
54321 = 5 · 9876 + 4941
9876 = 1 · 4941 + 4935
4941 = 1 · 4935 + 6
4935 = 822 · 6 + 3
6=2·3+0
So gcd(54321, 9876) = 3.
(6) (5.4) A number l is called a common multiple of m and n if both m and n divide l. The smallest
such l is called least common multiple of m and n and is denoted by lcm(m, n).
(a) Compute
(i) lcm(8, 12), (ii) lcm(20, 30), (iii) lcm(51, 68), (iv) lcm(23, 18)
(b) For each of the lcm’s you computed in (a), compare the value of lcm(m, n) with the values of
m, n, and gcd(m, n). Try to find a relationship.
(c) Prove that the relationship you found is correct for all integers m and n.
(d) Use your result from (c) to compute lcm(301337, 307829).
Solution:
(a) (i) lcm(8, 12) = 24,
(b) The relationship is
(ii) lcm(20, 30) = 60,
(iii) lcm(51, 68) = 204,
lcm(m, n)gcd(m, n) = mn.
(c) Let m and n have prime factorizations
mr
1 m2
m = pm
1 p2 · · · p r
and n = pn1 1 pn2 2 · · · pnr r ,
(iv) lcm(23, 18) = 414
where the exponents are nonnegative integers and all primes occuring in either factorization
occur in both, perhaps with 0 exponents. Now let
M axj = max(mj , nj )
and
minj = min(mj , nj ),
for 1 ≤ j ≤ r.
Now notice that, for any integer to be divisible by both m and n, its prime factorization has to
include all the prime factors of both m and n. The least common multiple is thus the integer
which contains precisely all the primes in the prime factorizations of m and n, and nothing
more. In other words,
ax1 M ax2
axr
· · · pM
.
p2
lcm(m, n) = pM
r
1
On the other hand, we noticed in class that
1 min2
r
· · · pmin
.
p2
gcd(m, n) = pmin
r
1
We then have
ax1 M ax2
axr min1 min2
r
· · · pmin
p1 p 2
· · · pM
p2
lcm(m, n)gcd(m, n) =pM
r
r
1
1 +n1 m2 +n2
r +nr
· · · pm
p2
=pm
r
1
nr
mr n1 n2
1 m2
=pm
1 p2 · · · pr p1 p2 · · · pr = mn.
(d) Using Euclidean Algorithm it is not hard to show that gcd(301337, 307829) = 541. Thus part
(c) gives
lcm(301337, 307829) =
301337 · 307829
301337 · 307829
=
= 171460753.
gcd(301337, 307829)
541
(7) (a) Suppose m, n, s ∈ Z, m|ns, and gcd(m, n) = 1. Show that m|s.
(b) Show that if m|n and n|m, then m = ±n.
(c) Suppose a, b, c, d ∈ Z and gcd(a, b) = gcd(c, d) = 1. (If the greatest common divisor of two
numbers is 1, they are said to be relatively prime). Suppose that b and d are nonzero and that
c
a
b + d is an integer. Prove that b = ±d.
Solution:
(a) By Linear Equation Theorem, there exist integers x and y that satisfy
mx + ny = gcd(m, n) = 1.
Multiplying this equation by s gives
msx + nsy = s.
Then m divides the first summand on the left (since it is its factor) and it divides the second
summand since it divides ns by assumption. By problem 4(a), m then also divides s.
(b) From the assumptions, we have that there exist k, l ∈ Z such that n = km and m = ln.
Multiplying the two equations gives mn = klmn so kl = 1. This means either both k and l are
1 or they are both −1. In the first case, we must then have m = n and in the second m = −n.
(c) By assumption, ab + dc = k for some k ∈ Z. Multiplying through by bd gives
ad + cb = kbd.
This can be rewritten in two ways:
ad = kbd − cb
and
cb = kbd − ad
ad = b(kd − c)
and
cb = d(kb − a).
or
So b|ad and d|cb. Since gcd(a, b) = gcd(c, d) = 1, b does not divide a in the first equation so it
must divide d by part (a), and d does not divide c in the second equation so it must divide b,
again by part (a). So b|d and d|b and it follows that b = ±d by part (b).
(8) (6.1(a)) Find an integer solution to the equation
12345x + 67890y = gcd(12345, 67890).
Solution: We reverse the steps of the Euclidean Algorithm performed in problem 5(a), solving for
the remainder at each stage. Let b = 12345 and a = 67890. Then we have
6165 = a − 5b
15 = b − 2 · 6165 = b − 2(a − 5b) = −2a + 11b.
So a solution is (x, y) = (11, −2).
Download