Math 22
Fall 2009 Home Page
Green Sheet

Class 21, Mon., Nov. 30, 2009
We went over a few homework problems. I emailed you all the quiz, please do number 4 for homework.
If you did not receive the email, let me know and I'll send it out to you individually.
Another counting problem I asked you to solve was to determine how many 4 by 4 Latin Squares there are (in the context of the game KenKen. This turns out to be a difficult problem - you can skip it!
We also spent time on first and second order linear recursions.
The additional homework problem was:
s(n) = 2s(n–2) – s(n–4), with S(0) = 0, s(1) = 1, s(2) = 2, and s(3) = 3. Find the solution (remember it will involve i and –i).
Do homework through section 9.3.
I will collect chapter 5 homework on Wednesday.

Class 20, Wed., Nov. 25, 2009
We went over material from chapter 8.6, 9.1, and 9.2. Do homework through the end of section 9.2.

Here's the 100 prisoner problem:

There are 100 prisoners in cells numbered 1 to 100. The keys, also numbered 1 to 100 are distributed among 100 boxes, also labeled 1 to 100. The prisoners are told that each will be given the chance to open any 50 boxes, looking for their own key. They may communicate

- and strategize - before they start opening boxes, but no communication is allowed after the first one starts opening boxes. If all of them find their own keys, then all will be released. What strategy do they adopt in order to maximize their probability of success?


If you want to see a solution, look at this link to a paper by Peter Winkler.


We also discussed the Monty Hall Problem.


Class 19, Mon., Nov. 23, 2009
We went over part 2 of Exam 2.
We went over the 6 people at the party problem, an example of Ramsey Theory.
Homework: Prove that R(3,4) = 9. That is, if the edges of the graph K9 are colored red and blue, then there is either a red K3 or a blue K4, or vice versa. Hint: see note at the very bottom of this page!
We learned about combinations with repetition.
We began going over the law of inclusion exclusion, and will apply this result to the problem of derangements, also known as the hat-check problem.
Homework: work problems through section 8.5.
Try to work the problem below before looking at the link in the next sentence!
We heard about the birthday problem: what is the "break-even" point n for which the probability that n or more randomly chosen people include at least two with the same birthdate with probability more than 50%, and this is not true for fewer than n people.

Class 18, Wed., Nov. 18, 2009
We went over the first part of exam 2, also some homework from chapter 5, and the first three sections of chapter 8 (we will skip chapters 6 and 7).
Do homework from sections 5.5, 8.1, and 8.2.
New problem to add to homework: If you choose 6 distinct numbers from the set {1,2,3,...,10}, then one will be a divisor of another. Use the pigeonhole principle to explain why this is true. Hint: odd numbers and powers of 2; the number of elements labelling each pigeonhole will not be the same - if you use a method that generalizes.

Class 17, Mon., Nov. 16, 2009
We went over material in sections 5.2 to 5.5. Do homework for sections 5.2, 5.3, and 5.4.
We also heard about the doodling coloring theorem: doodle any number of closed curves, so that curves may share common intersection points, but not entire sections of the curve. The resulting diagram will be 2-colorable. Why? Prove this!
We also eard about the Travelling Salesperson Problem (TSP), including the Nearest Neighbor Algorithm and the Sorted Edges Algorithm (neither of which works all the time!) Here's a site with links to latest research.
Did you do the two extra problems below in class 16?

Class 16, Wed., Nov. 11, 2009
We went over sections 4.5 and 5.1, and also planar graphs.
By the way, here's a totally absorbing planarity game - move the vertices so that the graph is drawn without edges crossing. Please try playing the game ... but don't get addicted!
Two additional homework problems:
(1) Can K(2,2,2) be drawn in the plane without edges crossing? If so, do it!
(2) Draw the de Bruijn graph for A,T,C,G which produces, via the Euler circuit, the string of length 17 (called a "de Bruijn sequence") which contains every possible substring of length 2.
Do homework through section 5.1.
Be ready to turn in chapter 4 homework.

Class 15, Mon., Nov. 9, 2009
We had exam 2 and also went over sections 4.3 and 4.4

Class 14, Wed. Nov. 4, 2009
Please use this answer sheet for the take-home "Coins" problem.
Note that you may skip problem 6(c) and 8(b)

We went over sections 4.1 and 4.2, and saw some applications of graph theory.
Here's an image of the internet graph.
Do homework for sections 4.1 and 4.2.
I've created a google group for this class for discussion purposes. I emailed everyone registered in the class; if someone did not receive the invitation, let me know and I'll add you directly.
Here's a study guide for exam 2 on Monday, may be a few other topics on the exam as well... (note this study guide is from a previous quarter, I'll try to update shortly.)
Be prepared to turn in chapter 3 homework on Monday.

Class 13, Mon. Nov. 2, 2009
We completed section 3.6, and began the chapter on graph theory.
Do section 3.6 homework.

Class 12, Wed., Oct. 28, 2009
We went over some quantifier problems, also some more number theory.
We also went over some material on codes from section 3.6; we'll finish the coding material on Monday.
Your second exam has been put off until Monday, Nov. 9.

Class 11, Mon., Oct. 26, 2009
We spent the first hour going over number theory questions, as well as some quantifier and logic questions.
The second hour was spent on code theory.
Begin homework for sections 3.4 and 3.5, we'll complete these sections Wednesday, and cover 3.6 as well.
I'll take up the logic and quantifier homework on Wednesday.

Here is the 2002 AKS primality test, which runs in O(log6+ε(n)) operations - not exponential, but not terribly fast either!
Here's Wikipedia on primality tests in general.
And here's how to use Fermat's Little Theorem for primality testing. (We've gone over most of the ideas at this page.)
Here's how to do fast modular exponentiation.

Here's the hat puzzle:
Three prisoners enter a room and a red or blue hat is placed on each person's head. The color of each hat is determined randomly, for example by a coin toss, with the outcome of one coin toss having no effect on the others. Each person can see the other players' hats but not his own.
No communication of any sort is allowed, except for an initial strategy session before the game begins. Once they have had a chance to look at the other hats, the prisoners must simultaneously guess the color of their own hats or pass. The prisoners will all be set free if at least one player guesses correctly and no players guess incorrectly. Otherwise they receive life sentences.
What strategy should the players adopt to insure their success rate is 3/4? How is this related to Hamming codes? What if there are 7 players?

Class 10, Wed., Oct. 21, 2009
We spent much class time looking at examples and theory of the RSA encryption algorithm.
Here is an article on Sarah Flannery's attempt at creating an alternative to RSA.
Finish the quiz we started on Wednesday, which is due Monday. Here is an example of an induction proof using strong induction.
Please read ahead the rest of chapter 3. We need to move through it fairly quickly.
Please also be prepared to turn in the logic problem handout and the handout about quantifiers on Monday.
If you have not read through the handout on modular arithmetic, and worked the problems, assigned one week ago, please do so now!
Here's the BOINC site, which organizes volunteer distributed computing, and operates in the petaflop range (quadrillions of operations per second.) BOINC stands for Berkeley Open Infrastructure of Network Computing.


Class 9, Mon., Oct. 19, 2009
We went over exam, also went over some logic problems and methods of proof, as well as quantifiers "for all" and "there exists."
Here are some more logic problems, as well as problems on proofs that we looked at briefly in class; please do for homework.
Here is a site with about 20 proofs of the irrationality of the square root of 2.

Please work the problems in the logic problem handout due on Wednesday.
Also try the problems in handout about quantifiers. We'll go over these ideas more on Wednesday.
Also read this Fido handout (originally written for the math for teachers class) and work the two problems on "bottlecaps."

For your entertainment, here is a site on Lewis Carroll and his logic problems.
Also do the homework from sections A.2 and A.3.


Class 8, Wed., Oct. 14, 2009

We went over more of section 3.3, more on linear congruences, learned how to apply the extended Euclidean algorithm to solve linear congruences, and began the appendix (section A.1).
Do homework from sections 3.1-3.3 and A.1 for Monday. Also read A.2 and A.3.

We went over modular arithmetic in great detail, including Fermat's Little Theorem, the Phi function (also known as Euler's totient function), and Euler's Theorem.
Read through this handout on modular arithmetic, and try as many of the problems as you can.

We've begun looking at logic. Here are some puzzles by Raymond Smullyan, from his new book, Logical Labyrinths. (Recent quote by Smullyan: "Why should I be worried about dying? It's not going to happen in my lifetime!"):

An anthropologist visits an island where there are two kinds of people: knights, who always tell the truth; and knaves, who always lie.
(1) The anthropologist comes across three inhabitants, A, B, and C. He asks A, "Are you a knight or a knave?" A answers, but indistinctly so the anthropologist can not understand what he says. He then asks B, "What did A say?"B replies, "He said that he is a knave." At this point, C piped up and said, "Dont' believe that; it's a lie." Was C a knight or a knave?
(2) According to another version of the above story, the anthropologist instead asks A how many of the three are knaves. Again A answers indistictly, so he asks B what A has said. B then says that A has said that exactly two are knaves. Then, as before, C says that B is lying. Is it now possible to determine whether C is a knight or a knave?
(3) Next the anthropologist meets two inhabitants, D and E. D says, "Both of us are knaves." What is D and what is E?

Work these problems for homework also.

Class 7, Mon., Oct. 12, 2009
Went over part of section 3.3 and rest of 3.2 (the Extended Euclidean Algorithm), and had exam 1.

Class 6, Wed., Oct. 7, 2009
Went over sections 3.1 and 3.2

Class 5, Mon., Oct. 5, 2009
Your first exam is next Monday.
We went over basic set theory ideas, and why the basketball I brought in is really a Venn diagram.
We went over basic ideas about relations that are posets or equivalence relations.
We looked at functions that are all possible combinations of one-to-one and onto (or not).
We examined inductive proof and looked at examples that are algebraic as well as geometric.
Your homework: problems in sections 2.5 and 2.6 (see below) - I will collect chapter 2 homework Monday.


Class 4, Wed., Sep. 30, 2009
We went over equivalence relations more, especially the concepts of modular arithmetic.
We went over partial orders (section 2.3) and functions (section 2.4) also.
Homework: text problems in sections 2.3 and 2.4 (see list below).

I also asked you to figure out what the "basketball" I brought to class had to do with Venn diagrams.
And do this homework problem for next class too:
Let the domain and codomain be the set of all integers, Z. Find:
(1) A function that is one-to-one and onto.
(2) A function that is one-to-one but not onto.
(3) A function that is not one-to-one but is onto.
(4) A function that is not one-to-one and also not onto.

Class 3, Mon., Sep. 28, 2009
We went over many homework problems from sections 1.3 and 1.4, and then went over material from sections 2.1 and 2.2.
Do the homework for sections 2.1 and 2.2, but be prepared to turn in homework for 1.1-1.4.
Here's a reference for the fast exponentiation algorithm we examined today.
The Wikipedia write-up on the empty set has an entertaining section on the philosophy of the thing.
More on equivalence relations.
In case you are wondering, wikipedia is usually pretty good on basic mathematical ideas.

Class 2, Wed., Sep. 23 2009
We went over material from sections 1.3 and 1.4.
Do homework from sections 1.3 and 1.4 (see list at bottom of this page).

Here's a reference on the Pythagorean Theorem, which mentions its history before Pythagoras, including visual proofs.
Here's more on Horner's Method. See the note towards the end on its history.
We also talked about Russell's paradox. This link has Russell's account of is development of the paradox.


Class 1, Mon., Sep. 21, 2009
Substitute Richard Lopez went over sections 1.1 and 1.2, and also the kidney dialysis problem.
Here's the first of the kidney transplant problems; work it!
Here's the second (and more difficult) of the kidney transplant problems; work it too!
Here's the list of all HW problems. Work all HW through section 1.2 for Tuesday.

Ch. 1.1 # 7,15,19
Ch. 1.2 # 6,16,18,25,26,31,32
Ch. 1.3 # 1,9,13,14,19,20,25,29
Ch. 1.4 # 9,11,17,23-27,31,32
Ch.  2.1 #1,13,15,17,26,31,33,39
Ch.  2.2 Odd problems #1-19,18,20, 22, 23,29
Ch. 2.3 1,3,5,9,13,18,19,21,32,40,41,42
Ch.  2.4 #1,3,5,9,13,18,19,21,32,40,41,42
Ch. 2.5 # 6,8,12,17,19,26
Ch. 2.6 # 5,16,27,37,43,45,47,48
Ch. 3.1 # 4,5,9,10,20,32,33,39,41,42,47,,48,51
Ch. 3.2 # 1,5,11,19,23
Ch. 3.3 # 1,5,11,15,31-37
Appendix A.1 # 1,7,12,16-18,22,25,29,33,35
Appendix A.2 # 1,9,15,21,30-34
Appendix A.3 # 3,11,15,16,18,20,23,26
Ch. 3.4 # 1,9,11,23,33
Ch. 3.5 # 5,9,15,19,29,31,35,40
Ch. 3.6 # 1,5,9,13,17,29,31,33,35,40,41,44
Ch. 4.1 # 1,7,8,16,18,21,22,24,26,31,35,42,47,48,53,54
Ch. 4.2 #19,23,31-34,40,41,50,52,61,63
Ch. 4.3 # 7,11,13,17
Ch. 4.4 # 4,6,10,11,12,13,20,22,25,2932,34.35(a little difficult)
Ch. 4.5 # 5,11,17,19,24,27,45,63,67,73,77
Ch. 5.1 # 13,18,25,27,32,37
Ch. 5.2 # 5,9 (we will definitely discuss this one in class!), 12,13,15,19,37,39
Ch. 5.3 # 3,25,28,32,33
Ch. 5.4 #13,16,21,30
Ch. 5.5 #5,16,22,28,35,41,45,53,56,64
Ch. 8.1 # 3,9,19,27,28
Ch. 8.2: # 1,3,6,7,15,19,23,34-36
Ch. 8.3: # 3,14,16,19-21,31,33-35
Ch. 8.4: # 3,9,10,15,30,34,36
Ch. 8.5: # 5,9,13,17,26,29-38
Ch. 8.6 #5,9,17,26,29-38
Ch. 9.1 #1,7,18,26,31
Ch. 9.2 # 1,2,5,11,27,34
Ch. 9.3 #1,14,23,25,

Ch. 9.4 # 11,13,15,19,25
Ch. 9.5 # 3,8,13,27,31

Hint to R(3,4) problem: Consider two possibilities for a random vertex v: v has 5 blue edges from it to its neighbors, or v has 6 or more blue edges.