Solutions to Homework 1 Page 8 2. 10. 9. First choose a leader from

advertisement
Solutions to Homework 1 Page 8 10. 2. 9. First choose a leader from a group, then two officers, the possibility is ; First choose two officers, then a leader, the possibility is 2
. 10. M*N. 10
11. 55. (You can choose two‐scoop of the same flavor) 13. Day 20 Sum=1+2+4+…+2^19=2^20‐1 Suppose sum of day n is Sn Sn=1+2+4+…+2^(n‐1) 2*Sn=2+4+…+2^(n‐1)+2^n =>Sn=2^n‐1 Page 20 1.
. 3 . No onto function One to one functions {(1, a), (2, b)}, {(1, b), (2, a)}, {(1, a), (2, c)}, {(1, c), (2, a)}, {(1, b), (2, c)}, {(1, c), (2, b)}. 5. if K<=n, the result is P(k,n)=n!/(n‐k)!. If k>n, there is no way to satisfy both conditions (pass out all the fruit and one child can get one piece of fruit at most). 7. There is 99999 – 10000 + 1 = 90000 base ten numbers have five digits; There is 9*9*9*9*9 = 59049 five‐digit numbers have no two consecutive digits equal; There is 90000 –59049= 30951 five‐digit numbers at least one pair of consecutive digits equal. 9 . {(1, 2, 3), (1, 3, 2), (2, 1, 3), (2, 3, 1), (3, 1, 2), (3, 2, 1), (1, 2, 4), (1, 4, 2), (2, 1, 4), (2, 4, 1), (4, 1, 2), (4, 2, 1), (1, 2, 5), (1, 5, 2), (2, 1, 5), (2, 5, 1), (5, 1, 2), (5, 2, 1), (1, 4, 3), (1, 3, 4), (4, 1, 3), (4, 3, 1), (3, 1, 4), (3, 4, 1), (1, 5, 3), (1, 3, 5), (5, 1, 3), (5, 3, 1), (3, 1, 5), (3, 5, 1), (1, 5, 4), (1, 4, 5), (5, 1, 4), (5, 4, 1), (4, 1, 5), (4, 5, 1), (4, 2, 3), (4, 3, 2), (2, 4, 3), (2, 3, 4), (3, 4, 2), (3, 2, 4), (5, 2, 3), (5, 3, 2), (2, 5, 3), (2, 3, 5), (3, 5, 2), (3, 2, 5), (4, 2, 5), (4, 5, 2), (2, 4, 5), (2, 5, 4), (5, 4, 2), (5, 2, 4), (4, 5, 3), (4, 3, 5), (5, 4, 3), (5, 3, 4), (3, 4, 5), (3, 5, 4)} 6 permutations and 10 three element subsets. 1017450. 11. The result is 13. 10
2
15. The number of pairs: 1320 ….
!
The number of pairs of serving order: 2
!
2
! 17. Suppose the domain of f is denoted n‐element set A {a1,a2,…,an}. The range of f is denoted by the n element set B {b1, b2,…,bn}. The function f is denoted by f:A‐>B. First: prove f is one‐to‐one=> f is onto. Assume f is not onto. There exists an element bi in B that cannot be mapped from any element ai in A by function of f. Therefore the total number of elements in B that can be mapped from an element in A by function of f is at most n‐1. It means that n elements of A are mapped to at most n‐1 elements of B. Therefore there exist two elements in A that are mapped to the same element bi in B. This contradicts with the premise that f is one‐to‐one. f is onto. Second: prove f is onto=> f is one‐to‐one. Assume f is not one‐to‐one. There exists two elements ai, aj in A such that ai, aj are mapped to the same element in B. Therefore the number of elements in B that can be mapped from an element in A by function of f is at most n‐1. But B has n elements. Therefore there exists an element bi in B that is not mapped from any element in A by function of f. This contradicts with the premise that f is onto. f is one to one. 
Download