Professional Documents
Culture Documents
Number Theory Midterm
Number Theory Midterm
陳冠廷 40940903S
March 27, 2023
a 6919 5957 b
b 5957 5772 6a − 6b
a−b 962 185 −6a + 7b
−30a + 35b 925 185
31a − 36b 37 0
we have
31 · 6919 − 36 · 5957 = gcd(6919, 5957) = 37.
Problem 2.
Solution (a).
1
PWO
Solution (b).
2
PWO
• Note that 0 ≤ 245 < 330. Hence (5657 (mod 329)) = 245.
Problem 3.
(a) Find all incongruent solutions to 2863x ≡ 2023 (mod 3157). (6 pts)
(b) Find all incongruent solutions to 15939x ≡ 7357 (mod 3266). (6 pts)
(c) Find all incongruent solutions to x ≡ 31 (mod 34) and x ≡ 29 (mod 88). (6 pts)
a 2863 3157 b
−10a + 10b 2940 2863 a
11a − 10b −77 294 −a + b
215a − 195b −70 308 −44a + 40b
−204a + 185b −7 −14 43a − 39b
−14
0
3
PWO
we know that
204 · 2863 − 185 · 3157 = 7 = gcd(2863, 3157).
a 15939 3266 b
5b 16330 3128 −8a + 40b
a − 5b −391 138 8a − 39b
−24a + 117b −414 138
25a − 122b 23 0
we know that gcd(15939, 3266) = 23. Since gcd(15939, 3266)̸ | 7457, by Thm. 8.1, there
has no solution.
Solution (c).
• Notice that
x ≡ 31 ≡ 1 (mod 2)
x ≡ −3 (mod 17)
x ≡ 31 (mod 34) x ≡ 31 ≡ −3 (mod 17)
⇐⇒ ⇐⇒ x ≡ −3 (mod 8)
x ≡ 29 (mod 88)
x ≡ 29 ≡ −3 (mod 8)
x ≡ −4
(mod 11)
x ≡ 29 ≡ −4 (mod 11)
• Since gcd(17, 8) = 1,
x ≡ −3 (mod 17)
⇐⇒ x ≡ −3 (mod 136),
x ≡ −3 (mod 8)
4
PWO
a 4 11 b
−2a + b 3 8 2a
3a − b 1 3 −2a + b
3
0
we have
• So
x = 136y − 3 = 136 · (−3) − 3 = −411
x ≡ −3 (mod 136)
is a solution to . By the Chinese remainder theorem,
x ≡ −4 (mod 11)
x ≡ −3 (mod 136)
⇐⇒ x ≡ −411 (mod 1496),
x ≡ −4 (mod 11)
where 1496 = 136 · 11. Thus, x ≡ −411 (mod 1496) the desired solution.
Problem 4. (a) Let m ∈ N. Suppose that p1 , p2 , . . . , pr are the distinct primes that divide
m. Show that (5 pts)
( )( ) ( )
1 1 1
ϕ(m) = m 1 − 1− ··· 1 − .
p1 p2 pr
5
PWO
k=1
pk
( r
k=1
)( r (
k=1 k=1
) ) (
k=1
)( ) ( )
∏ m ∏ 1 1 1 1
= pk k
1− =m 1− 1− ··· 1 − ,
k=1 k=1
pk p1 p2 pr
as desired.
Problem 5. Suppose a, m ∈ N and gcd(a, m) = 1. Let 1 = b1 < b2 < · · · < bϕ(m) < m are
relatively prime to m and ri ≡ abi (mod m), where 0 ≤ ri < m.
m | xa(bi − bj ) + ym(bi − bj ) = bi − bj .
6
PWO
Moreover,
2◦ Since ri ≡ abi (mod m), we have m | ri − abi . By the lemma (of the division
algorithm, in Note I), we have
6ϕ(8) − 1 = 64 − 1 ≡ −1 ≡ 7 (mod 8)
but
(6 − 1)(6 − 3)(6 − 5)(6 − 7) = 5 · 3 · 1 · (−1) ≡ 1 (mod 8).
Problem 6. Let c ∈ Z and let a, b and m be positive integers with a ̸= b, and let d = gcd(a, b).
Prove or give a counter example.
7
PWO
(h) If a = bq + r for some q and 0 ≤ r < b, then gcd(a, b) = gcd(b, r). (5 pts)
8
PWO
We conclude that the common divisors of a, b and m are exactly the same as the
common divisor of d and m, which implies gcd(a, b, m) = gcd(d, m).
(g) True. Note that there exist u, v ∈ Z s.t. ua + vb = gcd(a, b) = d. Then we have
a b d
u + v = = 1,
d d d
which implies that gcd(a/d, b/d) = 1 by the corollary.
(h) True.
We therefore conclude that the common divisors of a and b are exactly the same as
the common divisor of b and r, which implies gcd(a, b) = gcd(b, r).
ac = 2 ≡ 6 = bc (mod m)
but
a = 1 ̸≡ 3 = b (mod m).
9
PWO
−3 7n + 3 12n + 5 2
6n + 3 14n + 6
−n n −2n − 1 −2
n −2n
0 −1
we have
gcd(7n + 3, 12n + 5) = |−1| = 1.
p1 | am−1 − 1
p1 p2 | am−1 − 1
p1 p2 p3 | am−1 − 1
..
.
m = p1 p2 · · · pk | am−1 − 1.
10