The primary goal of this course is to become familiar with some of the basic mathematical ideas used in programming.
Homework 3
p 86 #1, #5abc (convex quadrilaterals only), #7
p 99 #2. Note that what is wanted here, at least for c, is some sort of proof, which you may take to mean some kind of explanation. Part (a) is easy if you apply the multiplication principle.
Investigate! examples on page 81
What is a permutation? Counting them.
How many functions f:{1,...,8} -> {1,...,8} are bijections? Such functions are also known as permutations
We can also talk about k-permutations of n elements: P(n,k) = n!/k!
= number of injective functions from k elements to n elements, n>=k
Compare with (n k) = C(n,k) (or B(n,k))
Example of dinner party on page 85 of Levin
Example on page 89
Example 1.4.1 on page 90
Wednesday
Page 93: Example 1.4.5
Page 95: 4 A's, 3 B's, 2 C's, 1 D problem
Page 96 example 1.4.6
Page 97, example 1.4.7
Friday
Page 103: stars and bars counting: how many ways can we give 7 cookies to 4 kids?
Page 106: Example 1.5.1
Page 106: Example 1.5.2
Page 107: Example 1.5.3
Page 112 (PIE): 1.6.1
1.6.2
1.6.4: Derangements
1.6.5