0% found this document useful (0 votes)
43 views

CSC201 Assignment 1

This document provides instructions for Assignment 01 on induction, counting, and combinatorics. It includes 20 problems covering topics like counting combinations and permutations, binomial coefficients, probability, and proofs by mathematical induction. Submissions are due three weeks before the final exam in Summer 2020 and must follow a specific naming convention and include student information on the front page.

Uploaded by

Elaf Mohammed
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
43 views

CSC201 Assignment 1

This document provides instructions for Assignment 01 on induction, counting, and combinatorics. It includes 20 problems covering topics like counting combinations and permutations, binomial coefficients, probability, and proofs by mathematical induction. Submissions are due three weeks before the final exam in Summer 2020 and must follow a specific naming convention and include student information on the front page.

Uploaded by

Elaf Mohammed
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 5

CSC201 Assignment 01

Induction, Strong Induction, Counting, and Combinatorics

N.B. This assignment will be graded.

You can submit ONLY TYPED soft copies (​NOT​ handwritten) for submissions with the
SUBJECT exactly in the following format:
AssignmentSubm01-CSC201-Sec03-Summer20-{YourFullName}-{YourStudentID}
e.g. AssignmentSubm01-CSC201-Sec03-Summer20-Md.Shahjahan-1910517
All submissions must be TYPED and the front page should be labeled with all
necessary student information.

Submission Deadline: Three weeks prior to the Final Exam, Summer 2020

1. Given ten points in the plane with no three collinear,


1.1. How many different segments joining two points are there?
1.2. How many ways are there to choose a directed path of length two through three
distinct points?
1.3. How many different triangles are there?
1.4. How many ways are there to choose 4 segments?
1.5. If you choose 4 segments at random, what is the chance that some three form a
triangle?

2. Prove using any method that ​C(n,k) = (n/k)*C(n-1, k-1) = (n/(n-k))*C(n-1, k)​.

3. Forty equally skilled teams play a tournament in which every team plays every other
team exactly once, and there are no ties.
3.1. How many different games were played?
3.2. How many different possible outcomes for these games are there?
3.3. How many different ways are there for each team to win a different number of
games?

4. A computer password is 6-8 characters long. Each character must be a digit, an


uppercase letter, or a lowercase letter. Each password must contain at least one digit,
one uppercase letter and one lowercase letter. How many passwords are possible?
Explain.
5. Let C(n,k) be the number of ways to choose k objects from a set of n. Prove by a
combinatorial argument:
5.1. C(n,0) + C(n, 1) + … + C(n, n) = 2​n​.
5.2. C(n,m)C(m,k) = C(n,k)C(n-k, m-k).
5.3. C(n, n-k) = C(n, k).
5.4. C2​ ​(n,0) + C2​ (n,
​ ​
1) + … + C2​ (n, n) = C(2n, n)​. (Hint: Use 5.3).

6. You choose three cards in order from a set of cards numbered 1 to 10.
6.1. How many possible outcomes are there? Explain.
6.2. How many of these are in sorted order from highest to lowest. Explain.

7. Prove the following combinatorial identities by formulae or mathematical induction


7.1. C(n+1, k+1) = C(n, k+1) + C(n, k)​.
7.2. C(r, r) + C(r+1, r) + C(r+2, r) + … + C(n, r) = C(n+1, r+1)​.
7.3. Using the identity in 7.2 above, derive a formula for the sum ​(1)(2)(3) + (2)(3)(4) +
… + (n-2)(n-1)(n)​.

8. How many ways are there to choose three different numbers each between one and a
hundred so that their sum is even? Explain.

9. If you have ​2n​ socks in a drawer, ​n​ white and ​n​ black, and you reach in to choose ​2
socks at random,
9.1. How many ways are there to choose?
9.2. How many of these ways result in getting a pair of the same color?
9.3. Write a simple closed formula in terms of ​n​ for the chance of choosing a
matching pair of socks from a drawer with ​n​ white and ​n​ black socks.

10. Emma’s pizza shop has 21 different toppings, three kinds of sauce, and three kinds of
cheese. Assume that someone can order any combination of sauces and cheeses
(including none), but must order exactly two different toppings.
10.1. How many different pizzas can one create? Explain.
10.2. If three people are sharing a pizza, and each can order their third as in 10.1, then
how many different pizzas can they order? Explain carefully.

11. A few short problems:


11.1. How many ways are there to choose a president, vice president, secretary and
treasurer from 9 people?
11.2. How many ways can 13 identical balls be distributed into 3 distinct boxes?
11.3. How many numbers greater than 3,000,000 can be formed from permutations of
1,2,2,4,6,6,6?
11.4. How many nine-digit numbers with twice as many odd digits as even digits?
(leading zeros are allowed)
11.5. How many passwords can be created in the form [A-Z][a-z]​9​[0,1]​6​? (That is, a
capital letter followed by 9 lowercase letters followed by 6 bits).

12. Prove by induction that the sum of any six consecutive squares leaves a remainder of
seven when divided by 12.

13. Poker:
13.1. How many different 5-card Poker hands are there?
13.2. How many of these are 1 pair?
13.3. How many of these are a flush (all one suit)?
13.4. How many are a full house (3 of a kind and a pair)?

14. What’s wrong with the proof by induction below?


Any non-zero number raised to the ​nt​ h power equals one. The proof is by induction on ​n​.
For ​n=0,​ the theorem is trivial. By induction, since ​n-1​ and ​n-2​ are both less than ​n​,
an​ ​ = (an-1
​ ​an-1
​ ​)/a​n-2​ = (1×1)/1.​

15. How many ways are there to distribute eight balls into six distinct boxes with at least one
ball in each box if:
15.1. The balls are identical?
15.2. The balls are distinct?

16. How many numbers between 7500 and 7800 are divisible by 5 but not divisible by 7?
Explain how you got your answer. Make a picture if necessary.

17. How many ways are there to distribute eight balls into six distinct boxes with at most four
balls in the first two boxes if:
17.1. The balls are identical?
17.2. The balls are distinct?

18. In the game ​War,​ two cards are chosen at random from a standard deck of cards, and if
they are the same rank (the ranks are in the set {2-10, J, Q, K, A}), there is a war. What
is the probability of a war? Explain.

19. Fibonacci in Pascal’s Triangle:


Prove by induction that the ​nt​ h Fibonacci number F​n​ equals C(n, 0) + C(n-1, 1) + C(n-2,
2) + … + C(⌈n/2⌉ , ⌊n/2⌋ ). You should assume that F​0​ = F​1​ = 1.

20. Five of 60 computers have a virus. Ten are selected at random. What’s the chance that
none of the selected computers have the virus?
21. Given a deck of 52 cards, how many ways are there to choose a set of four cards in
order followed by one additional card? Three in order followed by two additional
unordered cards? Two? One?

22. Four soldiers each choose a card from a standard deck. The highest card must lead the
charge to the front of the battlefield. One of the soldiers chooses the 3 of diamonds and
that ends up being the highest card, and he’s off to the front. On his way the soldier
wonders, “what was the chance of the 3 of diamonds being the highest card?” (Assume
that the suits are ordered clubs, diamonds, hearts and spades, and the ranks are
ordered 2 through Ace). While he is busy ducking bullets, answer his question for him.

23. There’s a new screensaver that displays a random rectangular piece of an ​n​ by ​n
checkerboard.
23.1. How many rectangles are there in a checkerboard of size 1? 2? 3? 4?
23.2. How many squares are there in a checkerboard of size 1? 2? 3? 4?
23.3. Guess a general formula for the number of squares and rectangles. Put each in
closed form in terms of ​n.​
23.4. Prove your formulas are true either by induction or using a combinatorial
argument.
23.5. What’s the chance that the rectangle displayed is a square? Give a simplified
closed form in terms of ​n.​
23.6. Although the number of squares and rectangles increase without bound as ​n
increases, what happens to the ratio of squares to rectangles?

24. The Pyramid numbers are the number of balls in a triangular pyramid of height ​n.​
P(0) = 0. P(1) =1. P(2) = 1+3 = 4. P(3) = 1+3+ 6 = 10.
Think of cannon balls in a pyramid pile. Write down the first 7 or 8 rows of Pascal’s
triangle, and use this to find a simple formula in terms of binomial coefficients for P(n).

25. What’s wrong with the following proofs by induction?


25.1. All binary strings are identical. The proof is by induction on the size of the string.
For ​n=0​ all binary strings are empty and therefore identical. Let ​X = b​nb ​ ​…b​1​b​0
​ n-1
be an arbitrary binary string of length ​n+1.​ Let ​Y = b​nb ​ ​n-1…b
​ ​ ​ and ​Z = b​n-1…b
1 ​ ​1b ​ .​
​ 0
Since both ​Y​ and ​Z​ are strings of length less than ​n+1​, by induction they are
identical. Since the two strings overlap, ​X​ must also be identical to each of them.
25.2. Any amount of change greater than or equal to twenty can be gotten with a
combination of five cent and seven cent coins. The proof is by induction on the
amount of change. For twenty cents use four five-cent coins. Let ​n > 20​ be the
amount of change. Assume that ​n = 7x + 5y​ for some non-negative integers ​x
and ​y​. For any ​n > 20,​ either x​ > 1​, or ​y > 3​. If ​x > 1,​ then since ​3(5) – 2(7) = 1​,
n+1 = 5(y+3)+7(x–2).​ If ​y > 3​, then since ​3(7) – 4(5) = 1,​ ​n+1 = 7(x+3)+5(y–4).​ In
either case, we showed that ​n+1 = 7u + 5v​ where ​u​ and ​v​ are non-negative
integers.
26. Prove by induction that:
26.1. The determinant of the ​n​ by ​n​ square matrix below is equal to the determinant of
B,​ where ​B​ is a matrix of ​m​ by ​m (m<n)​, and ​I​ is the ​m–n​ identity matrix.
B 0
0 I
26.2. Any amount of change greater than or equal to 24 can be gotten with a
combination of five and seven cent coins

27. A particular graph-matching algorithm on ​n​ nodes, works by doing ​n2​ ​ steps, and then
solving a new matching problem on a graph with one vertex less. Show that the number
of steps it takes to run the algorithm on a graph with ​n​ nodes is equal to the sum of the
first ​n​ perfect squares.

28. Consider the sequence defined as follows:


a0​ ​=1, a1​ =6,
​ a​n=6a
​ ​n-1−
​ 9a​n-2​ for n≥2​.
Prove that, ​an​ ​=(n+1)3​n,​ for every non-negative integer ​n​.

29. Prove by induction that:


29.1. The ​n​th Fibonacci number equals ​(1/√5)[(1/2 + √5/2)n​ ​ – (1/2 – √5/2)​n​],​ where
F0​ ​ = 0​ and ​F​1​ = 1.​
29.2. The sum of the geometric series ​1 + a + a2​ ​ + … + a​n​ equals ​(1–an+1
​ ​) ​/ (​ 1–a)​,
where ​a​ does not equal one.
29.3. 21 divides ​4n+1 ​ ​ + 52n-1

29.4. The number of leaves in a complete binary tree is one more than the number of
internal nodes. (Hint: Split the tree up into two smaller trees)

30. Consider the sequence defined as follows:


a1​ ​=1, a2​ =3,
​ a​n=a
​ ​n-1​+ a​n-2​ for n≥3.
Prove that, ​an​ ​<(7/4)n​ ​ for all positive integers ​n​.

You might also like