Math 290 Section 2 and 4 – Midterm Exam 3 April 1 – April 2, 2015 True-false questions 1. (False) For nonempty sets A and B, a relation R from A to B is a function when every b ∈ B appears exactly once in an ordered pair in R. 2. (True) A function f : A → B is one-to-one if whenever f (x) = f (y) for x, y ∈ A, we have x = y. 3. (False) Every injective function is surjective. 4. (True) There exist functions f : A → B and g : B → C such that f is not surjective but g ◦ f : A → C is surjective. 5. (True) Every two denumerable sets are numerically equivalent. 6. (False) For every set A, there exists a bijection from A to its power set P(A). 7. (False) Every infinite subset of an uncountable set is uncountable. 8. (True) For a, b, c, d ∈ Z with a 6= 0 and c 6= 0, if a | b and c | d, then ac | (ad + bc). 9. (True) For integers a and b, not both zero, there are infinitely many integers s and t for which gcd(a, b) = as + bt. 10. (True) The integers 10 and 21 are relatively prime. Multiple choice section 11. Let A be a nonempty set. How many equivalence relations are there on A that are also functions? (a) 0 (b) 1 (c) 2 (d) 3 (e) 4 (f) none of the above 12. The number of functions from A = {x, y, z} to B = {1, 2} is (a) 2 (b) 4 (c) 8 (d) 16 (e) 32 (f) none of the above. 1 13. The inverse of the permutation (a) (b) (c) (d) (e) 1 1 1 4 1 4 1 2 1 2 1 2 3 4 in S4 is 3 2 4 1 2 3 4 2 3 4 2 3 4 2 1 3 2 3 4 3 2 1 2 3 4 1 4 3 2 3 4 3 4 1 (f) none of the above. 14. Which of the following sets are denumerable? (i) 5Z, (ii) Q − 2Z, (iii) R − Q. (a) none of them (b) only (i) (c) only (ii) (d) only (iii) (e) only (i) and (ii) (f) only (i) and (iii) (g) only (ii) and (iii) (h) all of them 15. Which of the following sets have the same cardinality as that of R? (i) R − {1}, (ii) the open interval (−1, 5), (iii) the closed interval [4, 10]. (a) none of them (b) only (i) (c) only (ii) (d) only (iii) (e) only (i) and (ii) (f) only (i) and (iii) (g) only (ii) and (iii) (h) all of them 2 16. Any prime integer p > 2 can be written in the form p = 30k + r for integers k and r with 0 ≤ r < 30 when the value of r is (a) 0 (b) 1 (c) 2 (d) 6 (e) 15 (f) none of the above. 17. Which of the following prime numbers appear in the canonical factorization of 90? (a) 2 (b) 5 (c) 7 (d) all of them (e) some, but not all of them (f) none of them 18. The smallest prime factor of 529 is (a) 3 (b) 7 (c) 11 (d) 19 (e) 23 (f) none of the above. 19. Which of the following sets are denumerable? (i) {x ∈ N : x is prime}, (ii) {y ∈ N : 15 | y}, (a) none of them (b) only (i) (c) only (ii) (d) only (iii) (e) only (i) and (ii) (f) only (i) and (iii) (g) only (ii) and (iii) (h) all of them 3 (iii) {z ∈ N : gcd(z, 6) = 1}. 20. For the sets, A = {n ∈ Z : n is composite}, B = 2N , C = A × B, which of the following hold? (a) |A| < |B| and |B| ≤ |C| (b) |B| ≤ |C| and |C| ≤ |A| (c) |C| < |A| and |A| < |B| (d) |A| = |C| and |C| < |B| (e) |C| < |B| and |B| < |A| (f) none of the above Written Answer Section 21. Let a, b, c, n ∈ Z with n ≥ 2. Prove that if ac ≡ bc (mod n) and gcd(c, n) = 1, then a ≡ b (mod n). Solution 1. Since ac ≡ bc (mod n), if follows that n | c(a − b). Since n | c(a − b) and gcd(c, n) = 1, Euclid’s Lemma (stated below) tells us that n | (a − b). Hence a ≡ b (mod n). Euclid’s Lemma: Let x, y, z ∈ Z with x 6= 0. If x | yz and gcd(x, y) = 1, then x | z. Solution 2. Since gcd(c, n) = 1, there exist x, y ∈ Z such that 1 = cx + ny, and so cx ≡ 1 (mod n). Then ac ≡ bc (mod n) acx ≡ bcx (mod n) a ≡ b (mod n) [since cx ≡ 1 (mod n)] Solution 3. Use an argument that is essentially the same idea as the proof of Euclid’s Lemma. Grading Remarks: (a) A wrong or incomplete argument is that since n | c(a − b) and since gcd(n, c) = 1 we have n - c and therefore n | (a − b). The reason it is wrong or incomplete is that it is suggest lack of understanding of the essential need for Euclid’s Lemma (or something equivalent to Euclid’s Lemma) in the argument. What is to prevent the situation that n - c and n - (a − b) but n | c(a − b)? (b) A common error was to assert that n | c(a − b) implies n | c or n | (a − b), apparently as a generally true statement. In general, this is false. (c) I took points off for using the = symbol incorrectly. Please don’t invent nonstandard and ungrammatical usages of standard notation. Using notation badly is an almost sure way to eventually get nonsense. (d) When doing proofs involving integers and congruence of integers, many student who introduce fractions eventually make a logical error. I don’t know why. I suspect it has to do with the fallacy that if x | yz then x | y or x | z. 4 22. Let f : Z5 → Z5 be defined by f ([a]) = [2a + 1]. (a) Prove that f is well-defined. Proof. If [a] = [b], we must show that [2a + 1] = [2b + 1]. Since addition and multiplication of equivalence classes in Z5 are well-defined operations, we have [a] = [b] [2][a] = [2][b] [2a] = [2b] [2a] + [1] = [2b] + [1] [2a + 1] = [2b + 1] Thus, f is well-defined because the right hand side of the formula f ([a]) = [2a + 1] is independent of the representative of the equivalence class [a]. Grading Remark: To prove that f is well-defined, we must show that if [a] = [b], then [2a + 1] = [2b + 1] which implies that the formula f ([a]) = [2a + 1] makes sense. A number of students confused this with injectivity which is almost the converse of the previous statement: The function f would be injective if [2a + 1] = [2b + a], implies [a] = [b]. (b) Prove that f is a bijection. Proof. We simply compute all the values of f , as follows: f ([0]) = [2 · 0 + 1] = [1] f ([1]) = [2 · 1 + 1] = [3] f ([2]) = [2 · 2 + 1] = [5] = [0] f ([3]) = [2 · 3 + 1] = [7] = [2] f ([4]) = [2 · 4 + 1] = [9] = [4] By inspection, we see that if [a] 6= [b], then f ([a]) 6= f ([b]) and so f is injective. Since each member of Z5 is in the image of f , the function f is surjective. Hence, f is bijective. 5 23. Prove that the function f : R − {1} → R − {3} defined by f (x) = 3x x−1 is a bijection, and determine its inverse f −1 . Proof. First, we’ll verify that f is injective. Assuming a, b ∈ R − {1} and f (a) = f (b), we’ll show that a = b. So, we have f (a) = f (b) 3a 3b = a−1 b−1 b a = a−1 b−1 a(b − 1) = b(a − 1) ab − a = ab − b −a = −b a=b This proves that f is injective. Next, we’ll show that f is surjective. Let y ∈ R − {3}. Set r = f (r) = 3r r−1 3 = y y−3 y y−3 y y−3 . Then r ∈ R − {1}, and = −1 3y 3y = = y. y − (y − 3) 3 So, f is surjective. [Of course, the way we found r in the previous paragraph was to solve the equation f (r) = y for r in terms of y on scratch paper.] Since f is injective and surjective, it is bijective. We have already seen the algebra in the proof of surjectivity to know f −1 : R−{3} → R−{1}. It is given by the formula x f −1 (x) = . x−3 6 24. Let A and B be the subsets of R given by A = [1, 4] ∪ {5} and B = (2, 5). Prove that |A| = |B|. (Hint: Schr¨ oder-Bernstein) Proof. We already know that any function h : R → R given by a linear formula h(x) = ax + b where a 6= 0 is injective. So, the restriction of such a function to any smaller domain will still be injective. Now define functions f and g by f: A→B x f (x) = + 2 2 g: B → A g(x) = x − 1 Observe that since both f and g are increasing functions we can very easily compute their images: f (A) = [f (1), f (4)] ∪ {f (5)} = [2.5, 4] ∪ {4.5} ⊂ B = (2, 5) and g(B) = (g(2), g(5)) = (1, 4) ⊂ A = [1, 4] ∪ {5}. This verifies that the images lie in the correct codomains. By the remark in the first paragraph, both f and g are injective. By the Schr¨oder-Berstein Theorem, it follows that |A| = |B|. Note: Various other correct possibilities for f and g are: f (x) = mx + 2 x g(x) = 2 g(x) = −x + 6 x g(x) = + 1 3 x g(x) = + 1 2 √ f (x) = 2.2 x for any constant m with 0 < m < 3/5 f (x) = 3 + 1/x g(x) = 3 − 1/x A few students made some very complicated correct choices. I was sorely tempted not to give full credit for giving very complicated answers when simple answers were available. 7 25. (a) Use the Euclidean algorithm to compute gcd(182, 308). Show your work, and box the answer. Proof. 308 = 182 · 1 + 126 182 = 126 · 1 + 56 126 = 56 · 2 + 14 56 = 14 · 4 + 0 gcd(308, 182) = 14 (b) Use reverse substitution in calculation from part (a) to find integers x and y such that gcd(182, 308) = 182x + 308y. Show your work, and box the answer. Proof. 14 = 126 − 56 · 2 = 126 − (182 − 126 · 1) · 2 = 126 · 3 + 182 · (−2) = (308 − 1 · 82) · 3 + 182 · (−2) = 182 · (−5) + 308 · (3) gcd(182, 308) = 182 (−5) +308 (3) | {z } |{z} x 8 y
© Copyright 2024