Uploaded by jyh92949

Assignment-2

advertisement
Discrete Mathematical Structures
(CS/AI 1202)
Assignment-2
Please adhere to these instructions:
1. For each statement that appears in the assignment, you have to either prove its correctness
or refute it with a counter example.
2. If you feel any question/statement is ambiguous, clearly state your assumption(s) and solve
it accordingly.
3. Submit your written assignment soft-copy by 13th April, 10pm (check your email for the link;
hard-copy on April 23rd, 2024 at the beginning of the class. Deadlines are firm; moreover,
No early submissions are allowed for the hard copy.
4. You can discuss with peers, but you must write it in your own words. Avoid plagiarism
at all costs.
1. Find the number of divisors of n, where n is any natural number. (Hint: Use the fact that
every natural number can be expressed as product of primes and their powers).
2. Let A be a set of n elements, where n is a positive integer. Then, find the number of possible:
(a) relations on A.
(b) reflexive relations on A.
(c) irreflexive relations on A.
(d) symmetric relations on A.
(e) anti-symmetric possible on A.
3. How many bit strings of length 10 contain either five consecutive 0s or five consecutive 1s?
4. How many numbers must be selected from the set {1, 2, 3, . . . , 2n} (where n ∈ N) to guarantee
that at least one pair of these numbers add up to 2n + 1.
5. Let X2n = {1, 2, . . . , 2n − 1, 2n} be the set of first 2n positive integers. If A is any sub set
of X2n such that #(A) = n + 1 then A contains a pair, such that one divides the other. In
other words, among any n + 1 positive integers not exceeding 2n there must be an integer
that divides one of the other integers.
6. At a party where there are at least two people, there are two people who know the same
number of other people there (assume that knowing is mutual).
7. In a group of 6 people, every two individuals are either friends or enemies. Then, there exists
a group of three people such that they are either mutual friends or mutual enemies.
1
8. In a group of five people (where any two people are either friends or enemies), three mutual
friends or three mutual enemies always exist.
9. Give a combinatorial proof for the following identities (combinatorial argument is must):
r
m
).
) = ∑ (nk)(r−k
(a) (n+m
r
k=0
(b)
(c)
(d)
(e)
2
n
(n) for any positive integer n.
)
(2n
n = ∑i=0 i
)
k(nk) = n(n−1
k−1 for any two positive integers n and k such that k ≤ n.
n
n
∑k=1 k(k ) = n2n−1 for any two positive integers n and k such that k ≤ n.
n
n
k n
∑ (2)(k ) = ( 2 )2n−2 .
k=0
10. Assuming xi s are non-negative integers, find the number of solutions to the following (in)equalities:
(a) x1 + x2 + x3 = 11.
(b) x1 + x2 + x3 ≤ 11.
(c) x1 + x2 + x3 = 11, where x1 ≤ 3, x2 ≤ 4 and x3 ≤ 6.
(d) x1 + x2 + x3 + x4 + x5 = 21, where 0 ≤ x1 ≤ 3, 1 ≤ x2 ≤ 3 and x3 ≥ 15.
11. Assume that we have six objects and four boxes, find the total number of ways to distribute
the objects into the boxes if:
(a) objects are indistinguishable, but boxes.
(b) both objects and boxes are distinguishable.
(c) objects are distinguishable, but not boxes.
(d) both objects and boxes are indistinguishable so that each of the boxes contains at least
one object.
12. Find the number of ways to distribute 10 identical blackboards to 5 different schools if:
(a) any school can receive any number of blackboards.
(b) each school should receive at least one.
13. How many ways can n books be placed on k distinguishable shelves if no two books are the
same, and the position of the shelves matter?
14. How many ways are there to assign five different jobs to four different employees if every
employee is assigned at least one job?
n
15. n! = ∑ (−1)i (ni)(n − i)n , for any natural number n (Hint: use principle of inclusion exclusion
i=0
to count the number of onto-functions from a set with n-elements to a set with n-elements).
16. Find the number of equivalence relations possible on a set with n number of elements.
17. A derangement is a permutation of the elements of a set, such that no element appears in
its original position. Find the number of derangements of a set of size n. (Hint: You may
use principle of inclusion and exclusion).
2
18. Find a recurrence relation and give initial conditions for the following problems:
(a) the number of bit strings of length n that contain a pair of consecutive 0s.
(b) the number of bit strings of length n that do not have (two) consecutive 0s.
(c) the number of ternary strings (over {0, 1, 2}) that do not contain two consecutive 0s or
two consecutive 1s.
(d) the number of ways to climb n stairs if the person climbing the stairs can take one, two,
or three stairs at a time.
(e) the number of ways to parenthesize the product of n+1 numbers, x0 ∗x1 ∗x2 ∗. . .∗xn , to
specify the order of multiplication, denoted by Cn . For example, C3 = 5 because there
are five ways to parenthesize x0 ∗ x1 ∗ x2 ∗ x3 to determine the order of multiplication:
((x0 ∗ x1 ) ∗ x2 ) ∗ x3 , (x0 ∗ (x1 ∗ x2 )) ∗ x3 , (x0 ∗ x1 ) ∗ (x2 ∗ x3 ), x0 ∗ ((x1 ∗ x2 ) ∗ x3 ),
x0 ∗ (x1 ∗ (x2 ∗ x3 )).
19. Solve the following recurrence relations:
(a) an = an−1 − n with a0 = 4.
(b) an = 2an−1 − an−2 + n with a0 = 0 and a1 = 35 .
(c) an = 4an−1 − 4an−2 + (n + 1)2n .
(d) a2n − 2a2(n−1) = 1 for n ≥ 1, where a0 = 1.
20. A string of decimal digits is said to be valid if it contains an even number of 0 digits. For
example, 1230405060 is a valid string (of length 10) whereas 1264509007 is not. Let an be
the number of valid strings of length n. Find a recurrence relation for an and find an explicit
formula for an .
3
Download