CS 131 Spring 2015, Midterm 2 Study Questions
Please post solutions to Piazza max 1 proof per customer
Question 1. Prove that 1(1!) + 2(2!) + . . . n(n!) = (n + 1)! 1. For practice, prove it two different ways: by
standard induction, and by applying the w
CS 131: Combinatoric Structures
Fall 2015
Homework 10
Instructor: Lorenzo Orecchia
Due: Wednesday, December 3 at 11am
Reading Assignment:
MIT Notes Chapter 12.1, 12.2, 12.3, 12.4.1-12.4.3, 12.6
Assigned Exercises:
1. (a) Find the generating function for
CS 131: Combinatoric Structures
Fall 2015
Homework 7
Instructor: Lorenzo Orecchia
Assigned Exercises:
1. (a) How many different n bits long binary strings in total ?
(b) How many different n bits long binary strings contain exactly 3 zeroes ?
(c) Define A
CS 131: Combinatoric Structures
Fall 2015
Homework 1
Instructor: Lorenzo Orecchia
Due: Tuesday, September 22 at 12pm noon
Reading Assignment:
Review HTPI sections 2.2,which was covered in our Tuesday lecture. In particular, make sure you are
aware of the
CS 131: Combinatoric Structures
Fall 2015
Homework 1
Instructor: Lorenzo Orecchia
Due: Tuesday, September 15 at 12pm noon
Reading Assignment:
Read HTPI sections 1.3 (Variables and Sets), 1.4 (Operations on Sets). We will only sketch some of
this material
CS 131: Combinatoric Structures
Fall 2015
Homework 8
Instructor: Lorenzo Orecchia
Due: Wednesday, November 18 at 11am
Reading Assignment:
MIT Notes 11.1-11.7. Try to go through 11.7 and solve each example on your own before reading the
solution.
Assigned
CS 131: Combinatoric Structures
Fall 2015
Homework 5 Solutions
Instructor: Lorenzo Orecchia
Due: Wednesday, October 21 at 11am
Assigned Exercises:
1. We show that the parity of the number of switched-on lights is invariant under switch flips.
Let L(n) be
CS 131: Combinatoric Structures
Fall 2015
Homework 9
Instructor: Lorenzo Orecchia
Due: Tuesday, November 24 at 5pm
Reading Assignment:
MIT Notes Chapter 11
Assigned Exercises:
1. In a survey on the chewing gum preferences of baseball players, it was foun
CS 131 Spring 2015, Assignment 9
Problems due by 5PM, Friday May 1
Question 1. Give a combinatorial proof (see Section 11.9) that 2n =
n
0
+
n
1
+
n
2
+ . +
n
n
.
(a) First, give a combinatorial argument that the total number of subsets of set A = cfw_x1
CS 131 Spring 2015, Midterm 1 Study Questions
Students are invited to discuss and post solutions to these problems on Piazza, but please wait until after the HW3
deadline, i.e., after Tuesday 5PM, so students can focus on that rst. One solution per studen
CS 131 Spring 2015, Assignment 7
Problems due by 5PM, Friday, April 10
Question 1. Another basic sorting algorithm is Insertion Sort, which can be described recursively as follows. As
with Mergesort, the input is a list of n numbers, and the output is the
CS 131 Spring 2015, Assignment 6
Problems due by 5PM, Friday March 27
Question 1. Number theory terms and algorithms.
(a) Prove that a linear combination of linear combinations of integers a0 , a1 , . . . , an is a linear combination of
a0 , a1 , . . . ,
CS 131 Spring 2015, Assignment 8
Problems due by 5PM, Friday April 24
For all of the counting problems below, you must justify your work, such as we did in class for the counting
passwords problem.
Question 1. Next week, Im going to get really fit. On day
CS 131 Spring 2015, Assignment 1
Problems due in the drop-box by 5PM, Friday January 30. Hard deadline!
All of our homeworks will require short proofs. In writing up proofs, try to follow the style in our textbooks and
make sure your reasoning ows logical
CS 131: Combinatoric Structures
Fall 2015
Homework 11
Instructor: Lorenzo Orecchia
Due: Wednesday, December 9 at 11am
Reading Assignment:
MIT Notes Chapter 12 - all sections except 12.4.4 and 12.5.3
Alternative Source: notes by Michel Goemans on generat
CS 131: Combinatoric Structures
Fall 2015
Homework 6 Solutions
Instructor: Lorenzo Orecchia
Assigned Exercises:
1. problem 1
(a) F T F T(By change of basis of log function, we know that f (n) = g(n)log2 10.)
2n
(b) T T F F (Clearly, lim 10
n = 0 )
(c) F T
CS 131: Combinatoric Structures
Fall 2015
Homework 8 Solutions
Instructor: Lorenzo Orecchia
Due: Wednesday, November 18 at 11am
1. I have ten distinct chairs to paint. In how many ways may I paint three of them green, three of them
blue, and four of them
Introductory Lecture
Basic Notions
Combinatorics
is a branch of mathematics concerning the study
of countable or finite discrete structures.
Discrete Structures:
abstract mathematical structures that represent
discrete objects and the relationships be
Propositions
A proposition is a declarative sentence that is either true or false.
Examples of propositions:
a)
The Moon is made of green cheese.
b) Trenton is the capital of New Jersey.
c)
Toronto is the capital of Canada.
d) 1 + 0 = 1
e) 0 + 0 = 2
Ex
based on How to Prove It (chapter 6)
To prove a goal of the form n P( n):
First prove the base case:
P(n0) is true
then prove the induction step:
n n >n0 (P( n) P( n + 1).
Example 6.1.1. Prove that for every natural number n,
20 + 21 + + 2n = 2 n +
CS 131
Fall 2012
Problem Set #2
Due: Thursday, September 20 by 3:30 pm
To be completed individually. No late submission will be accepted
Reading: Section 4.2, pages 171-178.
Problems:
1. Each of the following statements talks about all sets A of a certain
CS 131: Combinatoric Structures
Fall 2015
Homework 11 Solutions
Instructor: Lorenzo Orecchia
1. Let (an )n0 be the sequence defined by a0 = 0, a1 = 5 and an = an1 + 6an2 for n 2. Find an
explicit expression for an .
Solution: We calculate the generating f
CS 131: Combinatoric Structures
Fall 2015
Homework 9 solution
Instructor: Lorenzo Orecchia
Assigned Exercises:
1. Define the set A to be the people who like fruit. Define the set B to be the people who like spearmint.
Define the set C to be the people who
CS 131: Combinatoric Structures
Fall 2015
Homework 7
Instructor: Lorenzo Orecchia
Assigned Exercises:
1. (a) How many different n bits long binary strings in total ?
2n
(b) How many different n bits long binary strings contain exactly 3 zeroes ?
n(n 1)(n
CS 131: Combinatoric Structures
Fall 2015
Homework 10 solution
Instructor: Lorenzo Orecchia
Assigned Exercises:
1. (a) Its clear that
(1 x)n =
n
n
X
X
n
n
(x)k =
(1)k xk
k
k
k=0
k=0
n
Therefore, the generation function is (1 x)
1
(b) We calculate the co
CS131 Homework #4 (18 pts)
Prove the following statements. To prove them, start by writing givens and goals,
modifying givens and goals, as discussed in the lectures, and then write the proof
reasoning going from givens to goals.
1)
2)
3)
4)
5)
6)
7)
8)
9