Vous êtes sur la page 1sur 87

Discrete Mathematical

Structures
CLICK TO VIEW

>>Syllabus

>>Solved Questions

>>Question Paper Set

Click & Download VTU CAMPUS APP


Get VTU Notifications, Notes, Question Papers
Events, Circulars and a lot more!
~ SJBIT
DISCRETE MATHEMATICAL STRUCTURES
[As per Choice Based Credit System (CBCS) scheme]
(Effective from the academic year 2015 -2016)
SEMESTER III
Subject Code 15CS36 IA Marks 20

Number of Lecture Hours/Week 04 Exam Marks 80

Total Number of Lecture Hours 50 Exam Hours 03

CREDITS 04

Course objectives: This course will enable students to

Prepare for a background in abstraction, notation, and critical thinking for the mathematics most
directly related to computer science.
Understand and apply logic, relations, functions, basic set theory, countability and counting arguments,
proof techniques,
Understand and apply mathematical induction, combinatorics, discrete probability, recursion, sequence
and recurrence, elementary number theory
Understand and apply graph theory and mathematical proof techniques.

Module -1 Teaching
Hours

Fundamentals of Logic: Basic Connectives and Truth Tables, Logic Equivalence The 10Hours
Laws of Logic, Logical Implication Rules of Inference. The Use of Quantifiers,
Quantifiers, Definitions and the Proofs of Theorems,
Textbook 1: Ch 2
Module -2

Properties of the Integers: Mathematical Induction, The Well Ordering Principle 10 Hours
Mathematical Induction, Recursive Definitions. Fundamental Principles of Counting:
The Rules of Sum and Product, Permutations, Combinations The Binomial Theorem,
Combinations with Repetition,
Textbook 1: Ch 4: 4.1, 4.2 Ch 1.
Module 3

Relations and Functions: Cartesian Products and Relations, Functions Plain and One-to- 10 Hours
One, Onto Functions. The Pigeon-hole Principle, Function Composition and Inverse
Functions. Properties of Relations, Computer Recognition Zero-One Matrices and
Directed Graphs, Partial Orders Hasse Diagrams, Equivalence Relations and Partitions.
Textbook 1: Ch 5:5.1 to 5.3, 5.5, 5.6, Ch 7:7.1 to 7.4
Module-4

12 | P a g e
The Principle of Inclusion and Exclusion: The Principle of Inclusion and Exclusion, 10 Hours
Generalizations of the Principle, Derangements Nothing is in its Right Place, Rook
Polynomials. Recurrence Relations: First Order Linear Recurrence Relation, The Second
Order Linear Homogeneous Recurrence Relation with Constant Coefficients.
Textbook 1: Ch 8: 8.1 to 8.4, Ch 10:10.1 to 10.2
Module-5

Introduction to Graph Theory: Definitions and Examples, Sub graphs, Complements, 10


and Graph Isomorphism, Vertex Degree, Euler Trails and Circuits , Trees: Definitions, Hours
Properties, and Examples, Routed Trees, Trees and Sorting, Weighted Trees and Prefix
Codes
Textbook 1: Ch 11: 11.1 to 11.3, Ch 12: 12.1 to 12.4
Course outcomes:
After studying this course, students will be able to:
1. Verify the correctness of an argument using propositional and predicate logic and truth tables.
2. Demonstrate the ability to solve problems using counting techniques and combinatorics in the context
of discrete probability.
3. Solve problems involving recurrence relations and generating functions.
4. Construct proofs using direct proof, proof by contraposition, proof by contradiction, proof by cases, and
mathematical induction.
5. Explain and differentiate graphs and trees
Graduate Attributes (as per NBA)
1. Engineering Knowledge
2. Problem Analysis
3. Conduct Investigations of Complex Problems
Question paper pattern:
The question paper will have ten questions.
There will be 2 questions from each module.
Each question will have questions covering all the topics under a module.
The students will have to answer 5 full questions, selecting one full question from each module.

Text Books:

1. Ralph P. Grimaldi: Discrete and Combinatorial Mathematics, , 5th Edition, Pearson Education. 2004.
Reference Books:
1. Basavaraj S Anami and Venakanna S Madalli: Discrete Mathematics A Concept based approach,
Universities Press, 2016
2. Kenneth H. Rosen: Discrete Mathematics and its Applications, 6th Edition, McGraw Hill, 2007.
3. Jayant Ganguly: A Treatise on Discrete Mathematical Structures, Sanguine-Pearson, 2010.
4. D.S. Malik and M.K. Sen: Discrete Mathematical Structures: Theory and Applications, Thomson,
2004.
5. Thomas Koshy: Discrete Mathematics with Applications, Elsevier, 2005, Reprint 2008.

13 | P a g e
DISCRETE MATHEMATICAL STRUCTURES 15CS35

QUESTION PAPERS SOLUTION


MODULE-1
Set Theory
1. Define power set of a set. Determine power sets of the following sets. (4m)

Jun 2015 / Jan 2016

Sol: Power Set: The collection of all subsets of a set A is called the power set
of A, and is represented P(A).
For instance, if A = {1, 2, 3,4}, then
P(A) = {, {1}, {2}, {3}, {1, 2}, {1, 3}, {2, 3},{1,2,3},{2,3,4},
{1,3,4},{1,2,4}. A}.
2. Using laws of set theory show that A (A B) = A (A B) - (5m)
Jun 2015/Jan 2016
Sol:A (A B) = A (A B1) [i.e A B = A B1]
= A ( A B 1 )1 [i . e A B = A B 1 ]
= A (A1 U B) [Demorgans Law]
= (A A1) U (A B) [Distributive Law]
= U (A B) [i.e. A A1 = ]
= A B
3. In a survey of 260 college students, the following data were obtained: 64
had taken a mathematics course, 94 had taken a computer science course,
58 had taken a business course, 28 had taken both a mathematics and a
business course, 26 had taken both a mathematics and a computer science
course, 22 had taken both a computer science and a business course, and 14
had taken all three types
i. How many of these students had taken none of the three courses?
ii. How many had taken only a computer science courses ? - ( 1 1 m)
Jun 2015 / Jan 2016
Solution:
Given: U=260 |A|=64 |B|=94 |C|=58 |A C| = 28 |A B| = 26 |B C| = 22 |A B C |
= 14

|A U B U C| =? |B1| =?
|A U B U C| = A + B + C |A B| |B C| |A C| + |A B C|
= 64 + 94 + 58 26 22 28 + 14
= 154
i. |A U B U C| = U |A U B U C|
= 260 154
= 106
ii.|B1| = |B| - |B C| - |B A| + |A B C|
= 94 22 26 + 14 = 60

Dept. of CSE, SJBIT Page 1


DISCRETE MATHEMATICAL STRUCTURES 15CS35

4. For any two sets A and B, prove the following ( 4 m)


June 2016
Sol:
A (A B ) = A B
Solution: A (A B) = A (A B1) [i.e A B = A B1]
= A ( A B 1 )1 [i . e A B = A B 1 ]
= A (A1 U B) [Demorgans Law]
= (A A1) U (A B) [Distributive Law]
=U (A B) [i.e. A A1 = ]
= A B
5. State and prove De Morgans law of set theory. (6m) June 2016
Solution:
The complement of union of 2 sets is equal to the intersection of complement of
the sets.

AUB=AB
Consider RHS, A B = { x / x A and x B }
= { x / x A and x B }
={x/x (A U B) }
=AUB
The union of compliment of 2 sets is equal to the compliment of intersection of the
2 sets.

AUB=A B
Consider LHS, A U B = { x / { x / x A or x B }
= { x / x A or x B }
={x/x (A B) }

6. In a survey of 260 college students, the following data were obtained: 64 had
taken a mathematics course, 94 had taken a computer science course, 58 had
taken a business course, 28 had taken both a mathematics and a business course,
26 had taken both a mathematics and a computer science course, 22 had taken
both a computer science and a business course, and 14 had taken all three types
of courses.
i. How many of these students had taken none of the three courses?
ii. How many had taken only a computer science courses (8m) june 2016
Solution:
Given: U=260 |A|=64 |B|=94 |C|=58 |A C| = 28 |A B| = 26 |B C| = 22 |A B C |
= 14

Dept. of CSE, SJBIT Page 2


DISCRETE MATHEMATICAL STRUCTURES 15CS35

|A U B U C| =? |B1| =?
|A U B U C| = A + B + C |A B| |B C| |A C| + |A B C|
= 64 + 94 + 58 26 22 28 + 14
= 154
iii. |A U B U C| = U |A U B U C|
= 260 154
= 106
iv. |B1| = |B| - |B C| - |B A| + |A B C|
= 94 22 26 + 14
= 60

7. For any two sets A and B, prove the following (2m) june 2016
A (A B ) = A B
Solution: A (A B) = A (A B1) [i.e A B = A B1]
= A ( A B 1 )1 [i . e A B = A B 1 ]
= A (A1 U B) [Demorgans Law]
= (A A1) U (A B) [Distributive Law]
=U (A B) [i.e. A A1 = ]
= A B

8. Determine the sets A and B given that A B = {1, 2, 4}, B A = {7, 8} and
AUB = {1, 2, 4, 5, 7, 8, 9} (4m) jan 2015
Solution: set A
A = (A U B) (B A)
= [{1,2,4,5,7,8,9}] [{7,8}]
= {1, 2, 4, 5, 9}
Set B
B = (A U B ) (A B )
= [{1,2,4,5,7,8,9}] [{1,2,4}]
= {5, 7, 8, 9}

9. Let M, P and C be the sets of students taking Mathematics courses, Physics


courses and Computer Science courses respectively in a university. Assume |M| =
300, |P| = 350, |C| = 450, |M \ P| = 100, |M \ C| = 150, |P \ C| = 75, |M \ P \ C| = 10.
How many students are taking exactly one of those courses? (7m) Jan 2015
Solution:

Dept. of CSE, SJBIT Page 3


DISCRETE MATHEMATICAL STRUCTURES 15CS35

We see that |(M\P)-(M\P\C)| = 100-10 = 90, |(M\C)-(M\ P \C)| = 150-10 = 140 and |(P
\C)-(M \P \C)| = 75-10 = 65.
Then the region corresponding to students taking Mathematics courses only has
cardinality 300-(90+10+140) = 60. Analogously we compute the number of students
taking Ph ysics courses only (185) and taking Computer Science courses only (235). The
sum 60 + 185 + 235 = 480 is the number of students taking exactly one of those courses.

10. For any three sets A,B and C prove that (A-B)-C =A (BUC) = (A-C) (B-C) -6M
jan 2015
Solution: (A-B) C = (AB) C
= A (B C )
= A (B C )
= A (BC)
(A C) (B C) = (A C) (B C)
= (A C) (B C1)
= (A C) (BU C)
= [(A C) B)] U [(A C) C]
= [(A (CB)] U [A (CC)]
= [A (CUB) ] U (A)
= [A (BUC) ] U
= [A (B U C ) ]
= [A - (BUC)]

11. Explain the laws of set theory: ( 8 m) jun 2014

Dept. of CSE, SJBIT Page 4


DISCRETE MATHEMATICAL STRUCTURES 15CS35

12. Determine the sets A and B given that A B = {1, 3, 7, 11}, B A = {2, 6,
8} and AB = {4, 9} (5m) june 2014
Solution: set A
A = (A B) + (AB)
= [{1, 3, 7, 11}] + [{4, 9}]
= {1, 3, 4, 7, 9, 11}
Set B
B = (B-A) + (AB)
= [{2, 6, 8}] [{4, 9}]
= {2, 4, 6, 8, 9}

1 1
13. Prove that: AB= (BA ) U (AB ) = (B-A) U (A-B). ( 4 m) june 2014
1 1
Solution: AB= (BA ) U (AB ) = (B-A) U (A-B).
Let A=P1 U P2 B=P2 U P3

AB = (AUB)-(AB) = (P1 U P2 UP3) (P2) = P1 U P3 (1)

Dept. of CSE, SJBIT Page 5


DISCRETE MATHEMATICAL STRUCTURES 15CS35

B A = P3, A B = P1
Therefore (B A) U (A B) = P3 U P1 (2)
A=U - A = P3 U P4, AND B=U B = P1U P4
B A= P3, A B = P1 Therefore (B A1) U (A B1) = P3 U P1
(3)
From (1), (2) and (3), AB= (BA) U (AB) = (B-A) U (A-B).

14. Using Venn diagram, prove the following property of the symmetric difference:
A ( B C) = ( A B ) C ( 4 m) jan 2015
Solution: By using Venn diagram,

Where, A = P1 U P2 U P3 U P4 B = P2 U P3 U P5 U P6 C = P3 U P4 U P6 U P7
L.H.S (BC) = (B U C) (BC) = P2 U P4 U P5 U P7
A U (BC) = P1 U P3 U P2 U P4 U P5 U P7 A (BC) = P2 U P4
A (BC) = A U (BC) - A (BC) = P1 U P3 U P5 U P7.
R.H.S (AB) = (A U B) (B A) = P1 U P4 U P5 U P7
(A B) U C) = P1 U P4 U P5 U P6 U P3 U P7
(A B) C) = P4 U P6
(A B)C) = (A B) U C) - (A B) C) = P1 U P5 U P3 U P7
So that L.H.S = R.H.S Hence proved

15. Thirty cars are assembled in a factory. The options available are a transistor, an
air conditioner and power windows. It is known that 15 of the cars have
transistor, 8 of them have conditioners and 6 of them have power windows.
Moreover, 3 of them have all three options. Determine at least how many cars do
not have any options at all. ( 5 m) Jan 2016
Solution: Given data:
|U| = 30 Total cars |A| = 15 Transistors |B| =8 Air conditioners
|C|= 6 Power windows |A B C| = 3 All options
i) |A U B U C| = |A| + |B| + |C| - |A B| - |B C| - |C A|
+ |A B C|
Here A B, B C, C A is a subset of A B C
So
|A U B U C| |A| + |B| + |C| - 2|A B C| 15 + 8 + 6 -2(3) 29 6 = 23

Dept. of CSE, SJBIT Page 6


DISCRETE MATHEMATICAL STRUCTURES 15CS35

1
(A U B U C) is the set of cars that do not have any option.
1
|A U B U C| |U|- |A U B U C|
30 23 = 7
Therefore a minimum of 7 cars has none of the options.

16. A survey on a sample of 25 new cars showed that the cars had the following
15 cars had air conditioners
12 cars had radios
11 cars had power windows
5 cars had air conditioners and power windows
9 cars had air conditioners and radios
4 cars had radios and power windows
3 cars had all the three options
Find the number of cars that had
i) only power windows
ii) at least one option ( 7 m) Jan 2016
Solution: Given data:
|U| = 25 Total cars
|A| = 15 Air conditioners
|R| = 12 Radios
|W|= 11 Power windows
|A R| = 9 Air conditioners and Radios
|A W| = 5 Air conditioners and Power windows
|R W| = 4 Radios and Power windows

|A R W| = 3 All options
i) only power windows:
|W| = |W A R |
= |W| - |A W| - |R W| + |A R W|
= 11 5 4 + 3
=5
5 CARS HAVE ONLY POWER WINDOWS
ii) At least one option:
|W U A U R| = |W| + |A| + |R| - |A R| - |A W| - |R W|
+ |A R W|
= 11 + 15 + 12 5 9 4 + 3
= 23

17. A survey of 500 television viewers of sports channel produced the following
information: 285 watch cricket, 195 watch hockey, 115 watch foot ball, 45 watch

Dept. of CSE, SJBIT Page 7


DISCRETE MATHEMATICAL STRUCTURES 15CS35

cricket and foot ball, 70 watch cricket and hockey, 50 watch hockey and foot ball
and 50 do not watch any of the three kinds of games
i) How many viewers in survey watch all three kinds of games?
ii) How many viewers watch exactly one sport? (8m) Jan 2016
Solution: At least one:
|CU H U F| = |U| - |C U F U H|1
=500 50 = 450 do watch any of the games
|C U H U F| = |C| + |F| +|F| -|CF|-|CH|-|HF|+|CFH|
But |CFH| means those viewers who watch all the 3 games.
So, |CFH|= |C U H U F| -|C| - |H| -|F| +|CF|+|CH|+|HF|
= 4 5 0 2 8 5 1 9 5 1 1 5 +4 5 +7 0 +5 0
= 20
Therefore 20 viewers watch all the 3 games.
2) Only cricket viewers:
|C1| = |C H - F|
= |C|-|CF|-|CH|+|CFH|
= 285 -70 -45 +20
=190
3) only hockey viewers:
|H1| = | H - C - F|
= |H|-|HF|-|CH|+|CFH|
= 195 -50 -70 +20
= 95

4) only football viewers:


|F1| = | F- C - H|
= |F|-|HF|-|CF|+|CFH|
= 1 1 5 4 5 -5 0 + 2 0
= 40
Therefore number of viewers those who watch exactly 1 game is
|C1| + |H1| + |F1|
= 190 + 95 + 40
= 325.

18. The freshman class of a private engineering college has 300 students. It is known
that 180 can program in PASCAL, 120 in FORTRAN, 30 in c++, 12 in PASCAL
and c++, 18 in FORTRAN and c++, 12 in PASCAL and FORTRAN, and 6 in all
three languages If two students are selected at random, what is the probability
that they can
i) Both program in PASCAL?
ii) Both program only in PASCAL? ( 6 m) Jan 2016

Dept. of CSE, SJBIT Page 8


DISCRETE MATHEMATICAL STRUCTURES 15CS35

300
Solution: the number of ways of selecting 2 students from 300 is c
2.
180
The number of ways of selecting 2 students from those who can program Pascal is c.
2
162
The number of ways of selecting 2 students who can program only in Pascal is c.
2
The probability of selecting two students both of whom can program in Pascal is
180 300
c / c
2 2
= 0 .3 5 9 O R 3 5 .9 %
The probability of selecting two students both of whom can program in Pascal only is
162 300
c / c
2 2

=0.291 OR 29.1%.
19. In a survey of 120 passengers, an airline found that 48 enjoyed wine with their
meals, 78 enjoyed mixed drinks, 66 enjoyed iced tea. In addition, 36 enjoyed any
given pair of these beverages and 24 enjoyed them all. If two passengers are
selected at random from thee survey sample of 120, what is the probability that
they both want only iced tea with their meals? ( 7 m) Jan 2016
Solution: from the information provided, we construct the Venn diagram .The sample
space constants of the pairs of passengers we can select from the sample of 120.
120
So |S| = c =7140
2
A) Only iced tea = T = | T W C |
1
= |T| -|TW| - |TC| - |TWC|
= 66 36 36 + 24 = 18

Dept. of CSE, SJBIT Page 9


DISCRETE MATHEMATICAL STRUCTURES 15CS35

The Venn diagram indicates that there are 18 passengers who drink only ice tea.
18
So |A| = c = 153
2
Therefore p (A) = |A| / |S|
= 153 / 7140
= 51 / 2380.
B) Exactly 2 of the 3 type
Only T and C = |TC| - |TWC| .i
36 24 = 12
Only C and W = |WC| - |TWC| ..ii
36 24 = 12
Only W and T =|WT| - |TWC| iii
36 24 = 12
Adding i, ii, iii we get = 12 + 12 + 12
= 36 = |B|
36 120
Therefore p (B) = c / c
2 2
=3/4.

20. Find the probability of getting a sum different from 10 or 12 after rolling two
dice. (5m) Jan 2015
Solution : We can get 10 in 3 different ways:
4 + 6, 5 + 5, 6 + 4, so P (10) 3/36. Similarly we get that P (12) 1/36. Since they are
mutually exclusive events, the probability of getting 10 or 12 is P (10) + P (12) 3/36
+ 1/36 4/36 1/9. So the probability of not getting 10 or 12 is 1 1/9 8/9.

21. Explain set operations: ( 6 m) Jan 2015


Solution:
1. Intersection : The common elements of two sets:
A B = {x | (x e A) (x e B)} .
If A B = , the sets are said to be disjoint.

2. Union : The set of elements that belong to either of two sets:


A B = {x | (x e A) (x e B)} .

3. Complement : The set of elements (in the universal set) that do not b elong to a
g i v e n s et :
A = {x e U | x / e A } .

Dept. of CSE, SJBIT Page 10


DISCRETE MATHEMATICAL STRUCTURES 15CS35

4. Difference or Relative Complement : The set of elements that b elong to a set but
not to another:
A - B = {x | (x e A) (x /e B)} = A B .

5. Symmetric Difference : Given two sets, their symmetric differ- ence is the set of
elements that b elong to either one or the other set but not both.
A B = {x | (x e A) (x e B)} .

22. A compuer services company has 300 programmers. It is known that 180 of these
can program pascal, 120 in FORTRAN, 30 in c++, 12 in pascal and c++, 18 in
FORTRAN and c++, 12 in pascal and FORTRAN and 6 in all the three.
a) If a programmer is selected at random what is the probability that she
can program in exactly two languages?

b) If two programmers are selected at random what is the probability


that they can both program in pascal?
(10m) Jan 2016
Solution:
a) We note that the number of programmers who can program in
1) pascal and FORTRAN only is 6
2) pascal and C++ only is 6
3) FORTRAN and c++ only is 12
Thus 6+6+12=24 can program in exactly two languages.
Pr(A)=24/300=8%
b) the number of ways of selecting 2 programmers
from 300 is 300 c 2. Same way selecting 2 in pascal is 180 c 2.
Same way selecting 2 programmers who can program in pascal is 162 c 2.
The probability of selecting two who can program in pascal is
Pr(B)=180 c 2/300 c 2= 36%
The probability of selecting 2 who can program in both is
Pr=162 c 2/300 c 2=29%
23. Define power set of a set. Obtain all the power sets of A={1,2,3,4}. (3m)
Jan 2016
Sol: Power Set: The collection of all subsets of a set A is called the
power set of A, and is represented P(A).
For instance, if A = {1, 2, 3,4}, then
P(A) = {, {1}, {2}, {3}, {1, 2}, {1, 3}, {2, 3},{1,2,3},{2,3,4},
{1,3,4},{1,2,4}. A} .

24. Simplify the following expression: (4m) Jan 2016

Dept. of CSE, SJBIT Page 11


DISCRETE MATHEMATICAL STRUCTURES 15CS35

Sol:

25. Let p, q be primitives statements for which implication p q is false. Determine the
truth values of the following. Jun 2015 / Jan 2016
Sol: 5 marks
p q pv q qv p (p v q) (q v p)
T T T T T
T F T T T
F T T T T
F F F F T

26. By constructing the truth table. Show that the compound propositions pAND(~q V r)
Jun 2015 / Jan 2016
Sol: 5 marks

27. Prove the following logical statement is a tautology: Jun 2015 / Jan 2016 .

sol: 5 marks

Dept. of CSE, SJBIT Page 12


DISCRETE MATHEMATICAL STRUCTURES 15CS35

28. Let p, q be primitives statements for which implication .June 2015 / Jan 2016

Sol: 5 marks

29. Discuss the basic connectives that are used in logic. (6m) Jun 2016
Solution: new proposition are often formed by starting with given propositions with the
aid of words or phrases like not, and, ifthen, and if and only if such words or
phrases w=are called connectives
a) Negation: a proposition obtained by inserting the word not
at an appropriate places in a given propositions called negation of given proposition and is
denoted by ~p ( p is any proposition).
b) Conjunction: a compound proposition obtained by combining two given propositions
by inserting the word and in between them is called conjunction (denoted by p ^ q)
c) Disjunction: a compound proposition obtained by inserting the word or in between
them is called disjunction (denoted by p v q)
d) Conditional: a compound proposition obtained by combining two given proposition
by using the word if and then at appropriate place is called a conditional proposition
and is denoted by p q

30. Given p and q statements, explain the following terms (7m) Jun 2016
a) Conjunction b) disjunction c) logically Equivalence d) tautology
Solution:
a) conjunction: a compound proposition obtained by combining two given propositions
by inserting the word and in between them is called conjunction (denoted by p ^ q)
b) Disjunction: a compound proposition obtained by inserting the word or in between
them is called disjunction (denoted by p v q)
c) Logical equivalence : Two propositions p and q are said to be logical equivalent where
p and q have the same truth value or equivalently the biconditional p q is tautology.
Then we denote p q.

Dept. of CSE, SJBIT Page 13


DISCRETE MATHEMATICAL STRUCTURES 15CS35

d) Tautology: a compound proposition which is always true regardless of the truth values
of its components is called a Tautology.

31. show that (p v q) (q v p) is a tautology. (3m) Jun 2016


Solution: we have to show that (p v q) (q v p) is Tautology we can write the
truth table as follows.

p q pv q qv p (p v q) (q v p)
T T T T T
T F T T T
F T T T T
F F F F T

32. Define converse, inverse and contra positive of a statement: (4m) Jun 2016
Solution:
Consider a conditional (pq) , Then :
1) qp is called the converse of pq
2) pq is called the inverse of pq
3) qp is called the contrapositive of pq
4) The converse of a conditional prop osition p q is the prop osition q
p. As we have seen, the bi- conditional prop osition is equivalent
to the conjunction of a conditional prop osition an its converse.

p q (p q) (q p)

So, for instance, saying that John is married if and only if he has a
sp ouse is the same as saying if John is married then he has a sp ouse
and if he has a sp ouse then he is married.

Note that the converse is not equivalent to the given conditional


prop osition, for instance if John is from Chicago then John is from
Illinois is true, but the converse if John is from Illinois then John is
from Chicago may be false.

33. Find the truth value of p,q,r for the following using truth tables:
(5m) Jun 2016
Sol:

Dept. of CSE, SJBIT Page 14


DISCRETE MATHEMATICAL STRUCTURES 15CS35

34. Prove the following tautologies: (5m) Jan 2015


Sol:

35. Prove the following: ( 6 m) Jan 2015


Sol:

36. Find the truth values for the following logical expressions: (4m) Jan 2015

Dept. of CSE, SJBIT Page 15


DISCRETE MATHEMATICAL STRUCTURES 15CS35

Sol:

37. Write the truth table for the following: ( 8 m) jun 2014
Sol:

Dept. of CSE, SJBIT Page 16


DISCRETE MATHEMATICAL STRUCTURES 15CS35

38. Simplify the following compound statements: ( 6 m) jun 2014


Sol:

39. Verify whether the following logical expressions are tautology or contradiction
using truth tables: ( 6 m) jun 2014
Sol:

Dept. of CSE, SJBIT Page 17


DISCRETE MATHEMATICAL STRUCTURES 15CS35

40. Prove the following logical statement is a tautology: ( 5 m) jun 2 0 1 4


So l :

41. Prove the following logical statement is a tautology: ( 5 m) jun 2014


Sol:

42. Prove the following logical statement is a tautology: ( 5 m) Jan 2016


Sol:

Dept. of CSE, SJBIT Page 18


DISCRETE MATHEMATICAL STRUCTURES 15CS35

43. Prove the following logical statement is a tautology. (5m) Jan 2016
Sol:

MODULE-2

Fundamentals of Logic contd


1. Find inverse, converse and contra positive of the following (6m) Jan 2016

Sol:

2. Find inverse, converse and contra positive of the following:


Sol: (6m) Jan 2016

3. Simplify the following with reasons: ( 4 m) Jan 2016


Sol:

Dept. of CSE, SJBIT Page 19


DISCRETE MATHEMATICAL STRUCTURES 15CS35

4. Prove below open statements: (4m) Jun 2016


sol:

Dept. of CSE, SJBIT Page 20


DISCRETE MATHEMATICAL STRUCTURES 15CS35

5. Prove below quantifiers: ( 6 m) Jun 2016


Sol:

6. Write inverse, converse and contra-positive: ( 5 m) Jun 2016


Sol:

Dept. of CSE, SJBIT Page 21


DISCRETE MATHEMATICAL STRUCTURES 15CS35

7. Prove the below open statements: ( 7 m) jan 2015


Sol:

8. Check the validity of the following arguments: ( 3 m) jan 2015


Sol:

Dept. of CSE, SJBIT Page 22


DISCRETE MATHEMATICAL STRUCTURES 15CS35

9. Prove the following quantifiers: ( 3 m) jan 2015

10. Prove the following rules of inferences: ( 4 m) jan 2015

11. Prove the following rules of inferences (6m) j un 2 0 1 4


Sol:

12. Prove the following rules of inferences ( 4 m) jun 2014


Sol:

13. Verify the rules of inference from the following truth tables: (6m) jun 2015

Dept. of CSE, SJBIT Page 23


DISCRETE MATHEMATICAL STRUCTURES 15CS35

Sol:

14. Prove the following open statements: ( 4 m) jun 2015


Sol:

15. Find converse inverse and contra positive of the logical expressions given
below: (4m) jun 2015

Dept. of CSE, SJBIT Page 24


DISCRETE MATHEMATICAL STRUCTURES 15CS35

Sol:

Properties of the Integers

16. (6m) Jan 2016

Sol: basic step n=6


24<(36-7) = 29 is true
Induction step suppose s(n) is true
4n<(n2-7)
Consider 4(n+1)= 4n+4
< (n 2 -7 )+ 4
< (n 2 -3 ) t ru e
17 (8m) Jan 2016

Sol:

Dept. of CSE, SJBIT Page 25


DISCRETE MATHEMATICAL STRUCTURES 15CS35

18. (6m) Jan 2015

Sol:

19. For all positive integers n, prove that if n>=24, then n can be written as a sum
of 5s and 7s. (6m) Jun 2016
Sol:
i ) Basic Step:
24= (5+5) + (7+7)
This shows that s (24) is true
ii) Induction step: suppose s(n) is true
m = (5 + 5 + . )+ (7 + 7 + . )
if suppose m has r numbers of 5 and s numbers of 7.then we represent this as follows.
M + 1 = [(5 + 5 + . ) + (7 + 7 + . ) + 1 ]
r s
= [(5 + 5 + . ) + (7 + 7 + ) + (7 + 7 ) + 1 ]

Dept. of CSE, SJBIT Page 26


DISCRETE MATHEMATICAL STRUCTURES 15CS35

r s-2
= [(5+5+.) + (7+7+)]
r+ 3 s-2
This shows that Q (m+1) is a sum of 7 and5.Thus s (m+1) is true.

20. Prove by induction:1 2 + 32 +..+ (2n-1)2=n (2n-1) (2n+1) 3


(6m) Jun 2016
Sol:
Let s (n) =given statement,
i) Basic Step: Putting s (1) in the statement
2
1 = 1 (2 (1 )-1 ) (2 (1 ) + 1 ) 3
1 =33
1 =1True
ii) Induction step:
S (n) is true for n=k where k1.substitute n=k in the statement.
2 2 2
1 +3 +..+ (2k-1) = k (2k-1) (2k+1) 3
2
Add (2k+1) on both sides
2 2 2 2 2
1 +3 +..+ (2k-1) + (2k+1) = k(2k-1)(2k+1)(2k+1) 3
= (2 k + 1 )[k (2 k -1 )+ 3 (2 k + 1 )]/ 3
2
= (2k+1) (2k +5k+1)/3
= (2k+1) (k+1) (2k+3)/3
This statement of s (k+1) is true whenever the statement s (k) is true.

n-1
21. By induction prove that !n 2 for all integers n1. ( 7 m) Jan 2015
n-1
Solution: Let p (n) be the predicate !n 2 where n0 =1.

i) Basic Step: We have p (1) is the statement !1 21-1 is clearly true.


ii) Induction step: Where k1, if p(k) is true, then p(k+1), must also be true.
Assume that for some forced k1,
!k 2k-1
Then p (1+1) is, by the recursive definition, the left side of p(k+1) is
!k+1 = (K+1)! k (k+1)2k-1
Using p (k)
2*2k-1 k+1 2 since k 1
2k right hand side of p (k+1)

Dept. of CSE, SJBIT Page 27


DISCRETE MATHEMATICAL STRUCTURES 15CS35

Therefore p (n+1) and p (n) are true for all n, n1.

22. Prove by mathematical induction. ( 5 m) Jan 2015


Sol:

23. Prove by induction: ( 6 m) Jun 2014


1 2 +22 +32 +..+n2 =n (2n+1) (n+1) 2
Solution: Let s (n) denote the given statement
i) Basic Step: S (1) is the statement
12 = (1*2*3)/6 1 which is true?
ii) Induction step: If n=k
Then s (k) for any k1
= 12 +22 +32 ...+k2 = (k) (2k+1) (k+1)/6
Using this we shall find
12 +22 +32 ++k2 + (k+1)2 =k (2k+1) (k+1)/6 + (k+1)2
= (k+1) [k (2k+1)/6 + (k+1)]
= (k+1) (k+2) (2k+3)/6
S (k+1) Hence S (k+1) is true whenever s (k) is true for k1
Hence it is proved.

24. Prove by mathematical induction 1.3+2.4+3.5+n(n+2)= n (n +1) (2n + 7) / 6


(6m) Jun 2014
Solution:
Basis Step: S (1): 1 (1 + 2) = 1 (2) (9) / 6 3 = 18 / 6 3 = 3 S (1) = True.
Induction Step: Assume S (k) is true 1.3 + 2.4 + 3.5 +.k (k+2) = k (k+1) (2k+7) / 6
Now, Replace k by (k + 1)
(k + 1)(k + 1 + 2) = (k + 1) (k + 3) Add this on both sides.
1.3 + 2.4 + 3.5+..k (k + 2) + (k + 1) (k + 3) = k (k + 1) (2k + 3) / 6 + (k + 1) (k + 3)
= (k + 1) [k (2k + 7) / 6 + k + 3]
= (k + 1) [k (2k + 7) / 6 + k + 3]
= (k + 1) [(2k^2 + 7k +6k +18) / 6]
= (k + 1) / 6 * (4(k + 2) + 9(k + 2))

Dept. of CSE, SJBIT Page 28


DISCRETE MATHEMATICAL STRUCTURES 15CS35

= (k + 1) / 6 * (2k + 9) (K + 2)
25. A sequence an is defined by a1=3, an=an-1+an+1, for n>=2, find an explicit form:
Sol: (4m) Jun 2015

26. For n>=0 let fn denote the nth Fibonacci number. Prove that (4m) Jun 2015
F0+f1+f2+.+fn= Summation Fi= fn+2 -1
Sol:

Dept. of CSE, SJBIT Page 29


DISCRETE MATHEMATICAL STRUCTURES 15CS35

MODULE-3

Relations and Functions

1. Let A= {1,2,3,4} and let R be the relation defined by R = {(x,y)| x,y belongs to
A, X<=y}. Determine whether R is reflexive, symmetric, Anti symmetric or
transitive. (5m) Jan 2016
Sol:
Reflexive if for all x e A, x R x. For instance on Z the relation equal to (=) is
reflexive.
2. Transitive if for all x, y , z e A, x R y and y R z implies x R z. For instance
equality (=) and inequality (<) on Z are transitive relations.
3. Symmetric if for all x, y e A, x R y = y R x. For instance on Z, equality (=) is
s ymmetric, but strict inequality (<) is not.
4. Antisymmetric if for all x, y e A, x R y and y R x implies x = y.
For instance, non-strict inequality () on Z is antisymmetric.

2. What is the partition of a set? If R = {(1,1),(1,2),(2,1),(2,2),(3,4)(4,3),(3,3),(4,4)}


defined on the set A = {1,2,3,4}. Determine the partition induced.
(5m) Jan 2016
Sol:
Defn: A partition of a set X is a set of nonempty subsets of X such that every
element x in X is in exactly one of these subsets (i.e., X is a disjoint union of the
subsets).
Equivalently, a family of sets P is a partition of X if and only if all of the following
conditions hold:
1. P does not contain the empty set.
2. The union of the sets in P is equal to X. (The sets in P are said to cover X.)
3. The intersection of any two distinct sets in P is empty. (We say the
elements of P are pairwCSE disjoint.)

3. Define partial order. If R is a relation on A ={1,2,3,4} defined by X R Y if x|y.


prove that (A,R) is a POSET. Draw its Hasse diagram. (6m) Jan 2016
Sol:

Dept. of CSE, SJBIT Page 30


DISCRETE MATHEMATICAL STRUCTURES 15CS35

4. Let A={2,3,4,6,8,12,24} and let<= denotes the partial order of divisibility that
is x<=y means x|y. Let B = {4,6,12}. Determine: (4m) Jan 2016
a) All upper bounds of B
b) All lower bounds of B
c) Least upper bound of B
d) Greatest lower bound of B
Sol:

5. Let A= {1,2,3,4,5} . Define a relation R on AXA by (x1,y1)R(x2,y2) if and only


if x1+y1=x2+y2 (7m) Jun 2016
Solution: 1) Verify that R is an equivalence relation on A
For all (x,y) belongs to AXA . We have x+y=x+y that is
(x,y)R(x,y) There R is symmetric.
Next take any (x1,y1),(x2,y2) belongs to AXA. So x1+y1=x2+y2
Therefore R is symmetric.
Next take any (x1,y1),(x2,y2),(x3,y3) belongs to AXA. So
x1+y1=x2+y2 and x2+y2=x3+y3.
Therefore R is transitive.
2) We note that [(1,3}]= {(x,y) belongs to AXA | (x,y) R (1,3)}
= {(x,y) belongs to AXA | x+y=1+3}
={(1,3),(2,2),(3,1)},

Similarly [(2,4)]={(1,5),(2,4),(3,3),(4,2),(5,1)}
[(1 , 1 )]= { (1 , 1 )}
6. Let A= {1,2,3,4,6} and r be the relation on A defined by(a,b) belongs to R if
and only if a is a multiple of b. write down R as a set of ordered pairs.
(4m) Jun 2016
So l u t i o n : From the way R has been defined
R= {(a,b) | a,b belongs to A and a is a multiple of b}
= {(1,1), (2,1), (2,2), (3,1),

Dept. of CSE, SJBIT Page 31


DISCRETE MATHEMATICAL STRUCTURES 15CS35

(3,3),(4,1),(4,2),(4,4),(6,1),(6,2),(6,3),(6,6)}

7. Define 1) reflexive 2) symmetric 3) Irreflexive 4) Anti symmetric 5) transitive


relations: (5m) Jun 2016
Sol:
1. Reflexive if for all x e A, x R x. For instance on Z the relation
e q u a l t o ( = ) i s re fl e x i v e .
2. Transitive if for all x, y, z e A, x R y and y R z implies x R z.
For instance equality (=) and inequality (<) on Z are transitive
relations.
3. Symmetric if for all x, y e A, x R y = y R x. For instance on Z, equality
(=) is symmetric, but strict inequality (<) is not.
4. Antisymmetric if for all x, y e A, x R y and y R x implies x = y.
For instance, non-strict inequality () on Z is antisymmetric.
8. A set of 3 members is (A, B, C). Brotherhood is the relation among them.
Discuss whether the relation is equivalence. (4m) Jun 2016
Sol: Reflexive: a R a V a A
=> a is brother of himself, which is not true
Hence, not reflexive
Symmetric: Let a R b => a is brother of b
=>b is brother of a
=>b R a
Hence, R is symmetric
Transitive: Let a R b and b R c
=>a is brother of b and b is brother of c
=>a is brother of c
=>a R c.
Hence R is transitive.

Conclusion: Since R is not reflexive it is not an equivalence relation.

9. Define a relation R on B as (a, b) R (c, d) if a + b = c + d. show that R is an


equivalence relations. ( 6 m) Jan 2015
Sol:
a. Let (a, b) R (a, b)
=>a + b = a + b, which is true
Therefore, R is reflexive.
b. Let (a, b) R (c, d)
=>a + b = c + d
=>c + d = a + b (since, addition is commutative)
=> (c, d) R (a, b)

Dept. of CSE, SJBIT Page 32


DISCRETE MATHEMATICAL STRUCTURES 15CS35

Therefore, is symmetric
c. Let, (a, b) R (c, d) and (c, d) R (e, f)
=> a + b = c + d and c + d = e + f.
=>a + b = e + f
=> (a, b) R (e, f)
Therefore, R is transitive and
Therefore, R is an equivalence Relation.
10. A = {1, 2, 3} find
a. R1 = {(1, 1) (2, 2) (3, 3)}
b. R2 = {(1, 2) (2, 1) (1, 3) (3, 1) (2, 3), (3, 2)}
c. R3 = A x A ( 7 m) Jan 2015
Sol:
We have, A= {1, 2, 3}
a. R1 = {1, 1) (2, 2), (3, 3)}
Reflexive: a R a, V a A.
(1, 1) (2, 2) (3, 3) R
Hence, R is reflexive.
Symmetric: Let a R b
=> 1R2
2 is not Related to 1 and also b is not Related to a
Hence, R is not symmetric
Transitive: Let a R b and b R c
=> 1 R 2 and 2 R 3 but, 1 is not Related to 3 and
also a is not Related to c
Hence, R is not transitive.
Therefore, R is not an equivalence Relation.
b. R = {(1, 2), (2, 1) (1, 3) (3, 1) (2, 3) (3, 2)}
Reflexive: a R a V a A

=> 1 R1, 2 R 2, 3 R 3 not true,


Hence, R is not reflexive
Symmetric: Let a R b
=> 1 R 3
=> 3 R 1
=> b R a
Hence, R is symmetric.
Transitive: Let a R b and b R c
=> 1 R 2 and 2 R 3
=> 1 R 3
=> a R c
Hence, R is transitive

Dept. of CSE, SJBIT Page 33


DISCRETE MATHEMATICAL STRUCTURES 15CS35

Therefore, R is not an equivalence Relation.


c. A = {1, 2, 3}
R = A x A = {(1, 1)(1, 2)(1, 3)(2, 1)(2, 2)(2, 3)(3, 1)(3, 2)(3, 3)}
It is reflexive, symmetric and transitive and hence R is an equivalence
Relation.
11. If R is a relation on I, set of integers such that, x R y holds true if (x - y) is
divisible by 5, show that R is an equivalence relation. (6m) Jan 2015
Sol:
a. Let x R x
=> x x = 0 which is divisible by 5
Hence, R is reflexive.
b. Let x R y
=> x - y is divisible by 5
=> y - x is divisible by 5
=> y R x
Hence, R is symmetric.
c. Let x R y and y R z.
=> x - y is divisible by 5 and
=> y - z is divisible by 5
=> x - z also divisible by 5 => x R z
So, R is transitive.
Therefore, R is an equivalence relation.
12. If R1 and R2 are equivalence relations defined on the same set A. prove that R1
n R2 is an equivalence relation. (7m) Jun 2015
Sol:

Prove: R1 n R2 is also equivalence relations.


(a). Since Rl and R2 are reflexive, [since R1 and R2 are equivalence relations]
=> (a, a) R1 and (a, a) R2, V a A
=> (a, a) R1 n R2, V a A
=> Rl n R2 is reflexive.
(b). Let (a, b) R1 n R2
=> (a, b) R1 and (a, b) R2
=> (b, a) R1 and (b, a) R2, (since R1 and R2 are symmetric)
=> (b, a) R1 n R2
=> Rl n R2 is symmetric.
(c). Let (a, b) Rl n R2 and (b, c) Rl n R2.
=> (a, b) R1 and (a, b) R2 and (b, c) R1 and (b, c) R2
=> [(a, b) R1 and (b, c) R1] and [(a, b) R2 and (b, c) R2]
=> (a, c) R1 and (a, c) R2 (since Rl and R2 are transitive)
=> (a, c) Rl n R2

Dept. of CSE, SJBIT Page 34


DISCRETE MATHEMATICAL STRUCTURES 15CS35

Hence, R1 n R2 is transitive.
Therefore, R1 n R2 is an equivalence Relation.
13. Let A = {I, 2, 3, 4} and B = (A x A). Define a Relation R on B as (a, b) R (c, d)
if a + b = c +d. S.T. R is an equivalence relation and compute B/R.
Sol: (4m) Jun 2015
R {(1, 1)} = {(1, 1)} and B = {(1, 1) (1, 2) (1, 3) (1, 4)
R {(1, 2)} = {(1, 2), (2, 1)}
R { (1 , 3 )} = { (1 , 3 ), (3 , 1 ), (2 , 2 )}
R { (1 , 4 )} = { (1 , 4 ), (4 , 1 ), (2 , 3 ), (3 , 2 )}
R { (2 , 4 )} = { (2 , 4 ), (4 , 2 ), (3 , 3 )}
R {(3, 4)} = {(3, 4), (4, 3)}
R {(4, 4)} = {(4, 4)}
P = B/R = {R {(1, 1)}, R {(1, 2)}, R {(1, 3)}, R {(1, 4)}, R {(2, 4)}, R {(3, 4)}, R {4, 4)}

14. Let, A = {a, b, c}, B = {1, 2, 3}, R = {(a, 1) (b, 1) (c, 2) (c, 3)} S = {(a, 1), (a, 2)
(b, 1) (b, 2)} Compute R~, S~, R U S, R n S, R-1, S-1 where(R~ is R compliment)
sol: (6m) Jun 2015
A x B = { (a , l ) (a , 2 ) (a , 3 ) (b , 1 ) (b , 2 ) (b , 3 ) (c , l ) (c , 2 ) (c , 3 )}
R = {(a, 2) (a, 3) (b, 2) (b, 3) (c, 1)}
S = {(a, 3) (b, 3) (c, 1) (c, 2) (c, 3)}
R U S = {(a, 1) (b, 1) (c, 2) (c, 3) (a, 2) (b, 2)}
R n S = {a, 1) (b, 1)}

R-l = {(1, a) (1, b) (2, c) (3, c)}


S-1 = {(1, a) (2, a) (l, b) (2, b)}

15. Let A = {1, 2, 3} Rand S be relations on A whose matrices are, (8m) Jun 2014
Sol:

101 011

MR = 011 and Ms = 110

000 000
Determine relations R, R U S, R n Sand S-l and their matrix representation.
R = { (1 , 1 ) (1 , 3 ) (2 , 2 ) ( 2 , 3 )}
S = {(1, 2) (1, 3) (2, 1) (2, 2) (3, 2)}
R = { (1 , 2 ) (2 , 1 ) (3 , 1 ) ( 3 , 2 ) (3 , 3 )}
010
MR~ = 100

111
S~ = {(1, 1) (2, 3) (3, 1) (3, 3)} (s compliment)

Dept. of CSE, SJBIT Page 35


DISCRETE MATHEMATICAL STRUCTURES 15CS35

100

~
Ms = 001

101

R U S = { (1 , 1 )(1 , 2 )(1 , 3 ) (2 , 1 )(2 , 2 )(2 , 3 )(3 , 2 )}

111
MRUS = 111

010

R n S = { (1 , 3 ) (2 , 2 )}

001

MRnS = 010
000
S-1 = {(2, 1) (3, 1) (1, 2) (2, 2) (2, 3)}

010

MS-1 = 111

100
16. Let A = {a, b, c} and Rand S be relations on A whose matrices are given
below. Find the composite relation S o R, R o R, R o S, S o S and their
matrices. (8m) Jun 2014
Sol:
010
MR = 111

010

100
MS = 011

101

R = { (a , a ) (a , c ) (b , a ) (b , b ) (b , c ) (c , b )}
S = { (a , a ) (b , b ) (b , c ) (c , a ) (c , c )}
S o R = { (a , a ), (a , c ) (b , a ) (b , b ) (b , c ) (c , b ) (c , c ) }

Dept. of CSE, SJBIT Page 36


DISCRETE MATHEMATICAL STRUCTURES 15CS35

R o S = {(a, a) (a, c) (b, a) (b, b) (b, c) (c, a) (c, c) (c, b)}


R 2 = R o R = { (a , a ), (a , c ) (a , b ) (b , a ) (b , c ) (b , b ) (c , a ) (c , b ) (c , c )}
S2 = S o S = {(a, a) (b, b) (b, c) (b, a) (c, a) (c, c)}
17. Let R = {(1, 2) (3, 4) (2, 2)} and S = {(4, 2) (2, 5) (3, 1) (1, 3)} be relations on
the set A {2, 3, 4, 5} find S o R, R o S, Ro(S o R), So(R o S), Ro(R o R),
So(R o R), S(S o S) (5m) Jun 2014
Sol:
R = { (1 , 2 ) (3 , 4 ) (2 , 2 )}
S = {(4, 2) (2, 5) (3, 1) (1, 3)}
a. S o R= {(1, 5) (3, 2) (2, 5)}
b. R o S= {(4, 2) (3, 2) (1, 4)}
c. Ro(S o R) = {(3, 2)}
d. So(R o S) = {(4, 5), (3, 5), (1, 2)}
e. R o R = {(1, 2), (2, 2)}
f. S o S= {(4, 5) (3, 3) (1, 1)}
g. Ro(R o R) = {(1, 2) {2, 2)}

i. So(S o S) = {(3, 1) (1, 3)}

18. If A= {1,2,3,4} B={2,5} C= {3,4,7} Determine:


1) AXB 2) BXA 3) AU (BXC) 4) (AUB)XC 5) (AXC)U(BXC) (5m) Jun 2014
Sol:

19. Define reflexive transitive and symmetric relations with respect to quantifiers.
(5m) Jan 2014
Sol:

Dept. of CSE, SJBIT Page 37


DISCRETE MATHEMATICAL STRUCTURES 15CS35

20. Draw the hasse diagram for the poset (p(u)) where u={1,2,3,4} (5m) Jan 2016
Sol:

21. Let A={1,2,3,6,9,18} and define R on A by xRy if x|y. Draw hasse diagram of
the poset. (5m) Jan 2016
Sol:

22. Prove any R is a partial order. ( 5 m) Jan 2016


Sol:

Dept. of CSE, SJBIT Page 38


DISCRETE MATHEMATICAL STRUCTURES 15CS35

MODULE-4

Relations contd
1. Define the Cartesian product of two sets. For any non-empty sets A,B,C prove
that A X (B U C) = (A X B) U (A X C) (5m) Jan 2016
Sol:
Defn: In mathematics, a Cartesian product is a mathematical operation which
returns aset (or product set) from multiple sets. That is, for sets A and B, the
Cartesian product A B is the set of all ordered pairs (a, b) where a A and b B.
Assume (x,y) is an element of A X (B U C). This means x is an element of A and y
is an element of B or y is an element of C. Since (x,y) can be x as an element of A
and y as an element of B, (x,y) is an element of A X B. Since (x,y) can also have x
as an element of A and y as an element of C, (x,y) is an element of A X C.
A X (B intersect C)= (A X B) intersect (A X C)

2. Define the following with one example for each i) Function ii) one-to one
function iii) onto function. (6m) Jan 2016
Sol: function def: a function is a relation between a set of inputs and a set of
permissible outputs with the property that each input is related to exactly one
output.
Or
Definition (function): A function, denote it by f, from a set A to a set B is a
relation from A to B that satisfies
1. for each element a in A, there is an element b in B such that <a, b> is in the
relation, and
2. if <a, b> and <a, c> are in the relation, then b = c .
The set A in the above definition is called the domain of the function
and B its codomain.
Thus, f is a function if it covers the domain (maps every element of the domain)
and it is single valued.
(i) O ne -o ne de fn: one-to-one function is afunction that
preserves distinctness: it never maps distinct elements of its domain to the
same element of its codomain.

Dept. of CSE, SJBIT Page 39


DISCRETE MATHEMATICAL STRUCTURES 15CS35

(ii) Onto function defn: onto or a surjection, if every element y in Y has a


corresponding element x in X such that f(x) = y. The function f may map
more than one element of X to the same element of Y.

3. State the pigeonhole principle. An office employs 13 clerks. Show that at least
2 of them will have birthdays during the same month of the year.
(4m) Jan 2016
Sol: If m pigeons are put into m pigeonholes, there is an empty hole iff there's a
hole with more than one pigeon

Proof.
The number of friends of a person x is an integer k with 0 k n 1. If there is a
person y whose number of friends is n 1, then ever yone is a friend of y, that is,
no one has 0 friend. This means that 0 and n 1 cannot be simultaneously the
numbers of friends of some people in the group. The pigeonhole principle tells us
that there are at least two people having the same number of friends.

4. Let f: R R g: R R be defined by f(x) = X2 and g(x) = x+5. Determine fog


and gof show that he composition of two function is not commutative.
(5m) Jan 2016
Sol:
gof(-2)= g[f(-2)] = g[-2+1] = g[-1] = (-1) 2 + 2 = 1 + 2 =3
fog(-2) = f[g(-2)] = f[4+2] = f(6) = 7
gof(x) = g[f(x)] = g(x+1) = =(x + 1) 2 + 2 = x2 + 2x + 3
gog(x) = g[g(x)]
= g(x2 + 2)
= (x2 + 2) 2 + 2
= x4 + 4x2 + 6

5. Find the nature of each of the function. (5m) Jun 2016


Sol:

Dept. of CSE, SJBIT Page 40


DISCRETE MATHEMATICAL STRUCTURES 15CS35

6. In each of the following cases sets A and B and a function f: A B are given.
Determine (in each case) whether f is oneto-one or onto (or both) (or
neither) (5m) Jun 2016

Sol:1. A =B= {1, 2, 3, 4}


f = { (1 , 1 ), (2 , 3 ), (3 , 4 ), ( 4 , 2 )}
f is onto and one-one

1 1

2 2

3 3

Dept. of CSE, SJBIT Page 41


DISCRETE MATHEMATICAL STRUCTURES 15CS35

2. A = {a, b, c} B= {1, 2, 3, 4}
f = {(a, 1), (b, 1), (c, 3)}
neither onto nor one-one

3. A = {I, 2, 3, 4} B = {a, b, c, d}
f = {(1, a), (2, a), (3, d), (4, c)}

4. let A = {1,2,3,4} B = {a, b, c, d} f: A ( B is given as { (1 , a), (2 , b)}


f -1: B ( A = {( a , 1) , (b , 2 )}
f -1 is a function and hence f is invertible

7. let A,B,C be any three non-empty sets and A=B=C={set of real numbers} f: A
( B , g: f: B ( C be function defined by f(a) = a+1 and g(b) = b2 + 2, find
a. gof (-2), b. fog (-2), c. gof(x) , d. gog(x) (8m) Jun 2016
sol:
a. gof(-2)= g[f(-2)] = g[-2+1] = g[-1] = (-1) 2 + 2 = 1 + 2 =3

b. fog(-2) = f[g(-2)] = f[4+2] = f(6) = 7


c. gof(x) = g[f(x)] = g(x+1) = =(x + 1) 2 + 2 = x2 + 2x + 3
d. gog(x) = g[g(x)]
= g(x2 + 2)
= (x 2 + 2 ) 2 + 2
= x4 + 4x2 + 6
8. Let X = {1, 2, 3} and f, g, h and s be function from X to x given by
f = {(1, 2), (2, 3), (3, 1)},
g = {(1, 2), (2, 1), (3, 3)},
h = {(1, 1), (2, 2), (3, 1)}
Dept. of CSE, SJBIT Page 42
DISCRETE MATHEMATICAL STRUCTURES 15CS35

s = {(1, 1), (2, 2), (3, 3)} (6m) Jun 2016


Solution:
a. fog = f[g] = {(1 , 3), (2 , 2), (3 , 1)}
b. gof = g[f] = {(1 , 1), (2 , 3), (3 ,2)}
c. fohog
d. hog = {(1, 2), (2, 1), (3, 1)}
e. fohog = {(1, 3), (2, 2), (3, 2)}
f. sog = {(1 , 2), (2 , 1), (3 , 3)}
g. gos = {(1 , 2), (2 , 1), (3 , 3)}
h. sos = {(1 , 1), (2 , 2), (3 , 3)}
fos = {(1, 2), (2 , 3), (3 , 1)}

9. Let R denote the set of all real numbers. ( 5 m) Jan 2015


Sol:
Let f: R ( R be a function defined by f(x) = x 2
Is f an invertible function?
Solution:
Given f(x) = =x 2 x R
f = {(1 , 1), (2 , 4), (3 , 9),(-1 , 1), (-2 , 4), (-3 , 9),..}
Here f(2) = 4 and f(-2) = 4
Both 2 and -2 are related to 4 under f.
i.e. (2, 4) f and (-2, 4) f
Similarly, (4, 2) f -1 and (4, -2) f -1
(i.e.) 4 is related to two distinct elements 2 and -2 under f -1
The relation f -1 is not a function
Hence f is not invertible.

10. Find the inverse function f -1, of f: AB given by (6m) Jan 2015
Sol:
A = B = {1, 2, 3, 4, 5}
f = {(1, 3), (2, 2), (3, 4), (4, 5), (5, 1)}
Solution:
Given f = {( 1 , 3), (2 , 2), (4 , 3) ,(5 , 4) , (1 , 5)}
f -1 = {(3 , 1), (2 , 2), (4 , 3) ,(5 , 4),(1 , 5 )}
Here, f -1 s relation from B to A and a function as well.

11. Let A = {1, 2, 3, 4} and B = {a, b, c, d}. Determine whether the following
functions from A to B are invertible or not

a. f = {(1 , a), (2 , a), (3 , c), (4 , d)}

Dept. of CSE, SJBIT Page 43


DISCRETE MATHEMATICAL STRUCTURES 15CS35

ii. g = {(1 , a), (2 , c), (3 , d), ( 4 , d)} (8m) Jun 2014


Solution:
i. Given f = {(1, a), (2 , a), (3 , c), (4 , d)}
f -1 = {(a , 1), (a , 2), (c , 3), (d , 4)}
Here, f -1 is a relation from B to A but it is not a function because the element a has two
images 1 and 2 under f -1
(i.e.) f -1 is not a function
ii. Given g = {(1, a), (2, c), (3, d), (4, d)}
g -1 = {(a , 1), (c , 2), (d , 3), ( d , 4)}
Here, g -1 is a relation from B to A, but not a function because the element d has two
images 3 and 4 under g-1 . Hence g-1 is not a function.
g is not invertible.

12. Prove that the symmetric difference is associative on sets. (5m) Jun 2014
Solution:
To prove, (A B) C = A (B C) we have to prove,
f A(B C) (x) = f (AB) C (x)
Now, f (AB) C(x) = fD C where D = A B
= fD + fC - 2 fD fC (by property 3 of characteristic function)
= fC + fD (1- 2 fC )
= fC + (fA + fB - 2 fA fB ) (1 - 2 fC ) (b y property 3)
= f C+ f A+ f B- 2 f Af B - 2 f Af C -2 f Bf C+ 4 f Af Bf C
= f A + (f B+ f C 2 f Bf C) -2 f A(f B+ f C 2 f Bf )C
= fA + (f B+ f C 2 f Bf C) (1-2fA)
=f A + fB C (1-2fA)
= f A + f BC -2fA f BC
= f A(B C)
R.H.S = f A(B C) (x) = f (AB) C (x)
(A B) C = A (B C)

13. Suppose the addresses of customers of a bank are recorded in 101 files on the
basis of hashing function .With the account number. As keys, determine the
file in which the address of the customer with the account no. 2473876 is
recorded ( 6 m) Jun 2014
Solution:
Given No of files = 101 n
The keys whose file is being searched is a = 2473876
r =?
We know that, h n (a ) = r

Dept. of CSE, SJBIT Page 44


DISCRETE MATHEMATICAL STRUCTURES 15CS35

r = a o n = 2473876 / 101 =83


r = 8 3 (a % n )
The address of the customer with account no. 2473876 is recorded
in file 83.

14. Determine whether f(a,b)=[a+b) is commutative or assosiative. (5m) Jun 2015


Sol:

15. Prove that 151 integers are selected from {1,2,3,.3000} then the selection
must include two integers x,y where x|y or y|x. (4m) Jun 2015

Dept. of CSE, SJBIT Page 45


DISCRETE MATHEMATICAL STRUCTURES 15CS35

Sol:

16. Let f,g:Z+->Z+ where for all x belongs to Z+ f(x)=x+1 and g(x)=max{1,x-1}
the maximum of 1 and x-1. State few properties. (8m) Jun 2015
Sol:

17. Let f: Z->N be defined by f(x)= 2x-1 if x>0 and -2x for x<=0 Prove that f is one
one and onto determine f-1 ( 6 m) Jun 2015
Sol:

Dept. of CSE, SJBIT Page 46


DISCRETE MATHEMATICAL STRUCTURES 15CS35

18. Let f,g,h:Z->Z be defined by f(x)=x-1 and g(x)=3x h(x)= 0 even and 1 odd .
Determine the following: ( 6 m) Jan 2015
Sol:

Dept. of CSE, SJBIT Page 47


DISCRETE MATHEMATICAL STRUCTURES 15CS35

MODULE-5

G ro up s
1. Define abelian group. For any group G pT G is abelian if and only if
(ab)2=a2b2 ( 8 m) Jan 2016
Sol:

2. Define homomorphism and isomorphism in group. Let f be homomorphism


from a group G1 to group G2. Prove that i) If e1 is the identity in G1 and e2 is
the identity in G2, then f(e1) =e2 ii) f(a-1)= [f(a)]-1 for all a belongs to G1.
(4m) Jan 2016
Sol:

3. State and prove lagranges theorem. ( 8 m) Jan 2016


Solution: Lagrange's theorem
Lagrange's theorem, in the mathematics of group theory, states that for any finite group
G, the order (number of elements) of every subgroup H of G divides the order of G. The
theorem is named after Joseph Lagrange.

Proof of Lagrange's Theorem:

Dept. of CSE, SJBIT Page 48


DISCRETE MATHEMATICAL STRUCTURES 15CS35

This can be shown using the concept of left cosets of H in G. The left cosets are the
equivalence classes of a certain equivalence relation on G and therefore form a partition of
G. Specifically, x and y in G are related if and only if there exists h in H such that x = yh.
If we can show that all cosets of H have the same number of elements, then each coset of
H has precCSEly |H| elements. We are then done since the order of H times the number
of
cosets is equal to the number of elements in G, thereby proving that the order H divides
the order of G. Now, if aH and bH are two left cosets of H, we can define a map f : aH
bH by setting f(x) = ba-1x. This map is bijective because its inverse is given by f -1(y) =
ab-1y.
This proof also shows that the quotient of the orders |G| / |H| is equal to the index [G : H]
(the number of left cosets of H in G). If we write this statement as
|G| = [G : H] |H|,
then, seen as a statement about cardinal numbers, it is equivalent to the Axiom of choice.

4. Define abelian group. P T a group is abelian if and only if f or all a,b belongs
to G (a,b)-1=a-1b-1 ( 5 m) Jun 2016

Solution: A group G is said to be commutative or abelian if ab=ba for all a,be G.


We have (ab)(b-1a-1)=a(bb-1)a-1
=a(e)a-1=(ae)a-1=aa-1=e
Hence (a,b)-1=a-1b-1

5. Define a cyclic group. P T every cyclic group is abelian but converse is not
true. (6m) Jun 2016
Sol:
A cyclic group is a group that can be generated by a single element, in the sense that the
group has an element g (called a "generator" of the group) such that, when written
multiplicatively, every element of the group is a power of g (a multiple of g when the
notation is additive).
Let G be a cyclic group and g be a generator of G. for some integers m and m
Ab=gm=gn=gm+n=gn+m=gngm=ba
This shows G is abelian. Hence proved.

6. Let f:G->H be a homomorphism from G to H. If G is abelian P T H is also

Dept. of CSE, SJBIT Page 49


DISCRETE MATHEMATICAL STRUCTURES 15CS35

abelian. ( 4 m) Jun 2016

7. P T every subgroup is a cyclic group of itself. ( 5 m) Jun 2016


Solution:

8. Define homomorphism and isomorphism. (5 m ) Jan 2015


Sol:
Group homomorphism:

Image of a Group homomorphism(h) from G(left) to H(right). The smaller oval inside H
is the image of h. N is the kernel of h and aN is a coset of h.
In mathematics, given two groups (G, *) and (H, ), a group homomorphism from (G, *)
to (H, ) is a function h : G H such that for all u and v in G it holds that

where the group operation on the left hand side of the equation is that of G and on the
right hand side that of H.
From this property, one can deduce that h maps the identity element eG of G to the identity
element eH of H, and it also maps inverses to inverses in the sense that
h(u - 1) = h(u) - 1.
Hence one can say that h "is compatible with the group structure".

Dept. of CSE, SJBIT Page 50


DISCRETE MATHEMATICAL STRUCTURES 15CS35

Isomorphism:

If the homomorphism h is a bijection, then one can show that its inverse is also a group
homomorphism, and h is called a group isomorphism

9. Define the binary operation on o on Z by x o y=x+y+1. Verify that (Z,o) is an


abelian group. ( 4 m) Jan 2015
Solution:

10. For any group G pT G is abelian if and only if (ab)2=a2b2 (5m) J un 2 0 1 5


Sol:

11. If a group G P T (a-1)-1=a and (ab)-1=b-1a-1 (4m) Jun 2015


Sol:

12. P T for all groups (ab)-1=a-1b-1 ( 4 m) Jun 2014


Sol:

Dept. of CSE, SJBIT Page 51


DISCRETE MATHEMATICAL STRUCTURES 15CS35

13. Find every subgroup of S5 for all 2<=n<=5. ( 4 m) Jun 2014


Sol:

14. Let g= S4 for a=[ 12 3 4][2 3 4 1] Find a subgroup and all the left cosets.
(8m) Jun 2014
Sol:

Dept. of CSE, SJBIT Page 52


DISCRETE MATHEMATICAL STRUCTURES 15CS35

Groups Codes
15. Define a ring and integral domain. (6m) Jan 2016
Solution: A ring is an Abelian group (R, +), together with a second binary operation *
such that for all a, b and c in R,
a * (b * c) = (a * b) * c
a * (b + c) = (a * b) + (a * c)
(a + b) * c = (a * c) + (b * c)
A ring is said to be an integral domain if R is a commutative ring with unity.

16. Let r be a commutative ring with unity. Prove that if and only if for all
a,b,c
belongs to r where a=/ 0 1b=ac=b=c. (8m) Jan 2016
Sol: R is an integral domain
Ab=ac=(ab-ac)=0
= a (b -c )= 0
= b -c = 0
=b=c
C o n v e rs e l y
Xy=0=xy=x.0
=y =0
This proves that R is an integral domain.

17. Prove that every field is an integral domain. ( 6 m) Jan 2016


Sol: Let f be a field. Then f is a commutative ring with unity. Take any a,b belongs to F
such that ab=0. If a=/0 a-1 exists in f and we get
B=1b=(a-1a)b=a-1(ab)=a-10=0
Similarly if b=/=0 then a=0
Thus ab=0 in f implies a=0 or b=0. Hence F is an integral domain.
18. Show that Z5 is an integral domain. ( 5 m) Jun 2016
Solution: We note that Z5 is a commutative ring with unity. The multiplicative table for
Z5 is given below.
. 0 1 2 3 4
0 0 0 0 0 0
1 0 1 2 3 4
2 0 4 1 4 3
3 0 1 4 1 2
4 0 3 2 3 1

Z5 has no proper zero divisors. Therefore Z5 is an integral domain.

19. Prove that Zn is a field if and only if n is prime. (3m) Jun 2016
Solution: Suppose n is prime then for any integer a such that 0<a<n we have gcd (a,n)=1.
Dept. of CSE, SJBIT Page 53
DISCRETE MATHEMATICAL STRUCTURES 15CS35

Accordingly [a] is a unit of Zn. This means that every non zero element of Zn has a
multiplicative inverse. Therefore Zn is a field.

20. Define ring with an example: (4m) Jun 2016


Sol: A ring is an Abelian group (R, +), together with a second binary operation * such that
fo r a l l a , b a n d c i n R ,
a * (b * c) = (a * b) * c
a * (b + c) = (a * b) + (a * c)
(a + b) * c = (a * c) + (b * c)

21. Define hamming metric with example: ( 8 m) Jan 2015


Sol: Hamming codes can be computed in linear algebra terms through matrices because
Hamming codes are linear codes. For the purposes of Hamming codes, two Hamming
matrices can be defined: the code generator matrix and the parity-check matrix :

and

22. Explain decoding with coset leaders. ( 8 m) Jan 2015


Sol:
In the field of coding theory, a coset leader is defined as a word of minimum weight in
any particular coset - that is, a word with the lowest amount of non-zero entries.
Sometimes there are several words of equal minimum weight in a coset, and in that case,
any one of those words may be chosen to be the coset leader.
Coset leaders are used in the construction of a standard array for a linear code, which can
then be used to decode received vectors. For a received vector y, the decoded message is y
- e, where e is the coset leader of y. Coset leaders can also be used to construct a fast
decoding strategy. For each coset leader u we calculate the syndrome uH. When we
receive v we evaluate vH and find the matching syndrome. The corresponding coset
leader is the most likely error pattern and we assume that v+u was the codeword sent.
Example:A standard array for an [n,k]-code is a qn - k by qk array where:
1. The first row lists all codewords (with the 0 codeword on the extreme left)
2. Each row is a coset with the coset leader in the first column
3. The entry in the i-th row and j-th column is the sum of the i-th coset leader and the

Dept. of CSE, SJBIT Page 54


DISCRETE MATHEMATICAL STRUCTURES 15CS35

j-th codeword.
For example, the [n,k]-code C3 = {0, 01101, 10110, 11011} has a standard array as
follows:
0 01101 10110 11011
10000 11101 00110 01011
01000 00101 11110 10011
00100 01001 10010 11111
00010 01111 10100 11001
00001 01100 10111 11010
11000 10101 01110 00011
10001 11100 00111 01010
23. Define ring with unity and ring with zero divisor: (6m) Jan 2015
Sol:
Formally, a ring is an Abelian group (R, +), together with a second binary operation *
such that for all a, b and c in R,
a * (b * c) = (a * b) * c
a * (b + c) = (a * b) + (a * c)
(a + b) * c = (a * c) + (b * c)
also, if there exists a multiplicative identity in the ring, that is, an element e such that for
all a in R,
a*e=e*a=a
then it is said to be a ring with unity. The number 1 is a common example of a unity.

24. S is a subring of R if and only if for all a,b belongs to S we have a+b belongs to
S and ab belongs to S ( 6 m) Jun 2015
Solution:

25. If R is a ring wiyh unity and a,b are units of R, P T ab is a unit of R and
(ab)-1=b-1a-1 (6m) Jun 2015
Sol:

Dept. of CSE, SJBIT Page 55


DISCRETE MATHEMATICAL STRUCTURES 15CS35

26. Prove that a unit in a ring R cannot be a proper divisor of zero.


(5m) Jun 2014
Sol:

27. If a is a unit of ring R P T a is also a unit of ring R. (6m) Jun 2014


Sol:
A set S is an associative ring if there are two operators + and such that:
1. S is an abelian group under +.
2. S is closed under .
3. For any a, b, c S, (a b) c = a (b c). In other words, multiplication in S is
associative.
4. For any a, b, c S, a (b + c) = a b + a c and (b + c) a = b a + c a. In other words,
multiplication distributes over addition in S.

(-1) a = -a if (-1) a + a = 0. Because 1 is the unit element, a = 1 a and so

(-1) a + a = (-1) a + 1 a = (-1 + 1) a = 0 a = 0.


Theorem: If R is a ring with unit element 1, then (-1) (-1) = 1.
Proof. This follows from the previous theorem for a = -1.

28. Let S and T be subrings of a ring R. P T S intersection T is a subring of R.


(3m) Jun 2014
Sol:

Dept. of CSE, SJBIT Page 56


DISCRETE MATHEMATICAL STRUCTURES 15CS35

ASSIGNMENT QUESTIONS

MODULE 1: Set Theory

1) For any three sets A,B and C prove that (A-B)-C =A (BUC) = (A-C) (B-C)
2) Determine the sets A and B given that A B = {1, 2, 4}, B A = {7, 8} and AUB =
{1, 2, 4, 5, 7, 8, 9}
3) Determine the sets A and B given that A B = {1, 3, 7, 11}, B A = {2, 6, 8} and
AB = {4, 9}
4) Prove that: AB= (BA1) U (AB1) = (B-A) U (A-B).
5) Determine the sets A and B given that A B = {1, 2, 4}, B A = {7, 8} and AUB =
{1, 2, 4, 5, 7, 8, 9}
6) Using Venn diagram, prove the following property of the symmetric difference:
7) Thirty cars are assembled in a factory. The options available are a transistor, an air
conditioner and power windows. It is known that 15 of the cars have transistor, 8 of
them have conditioners and 6 of them have power windows. Moreover, 3 of them have
all three options. Determine at least how many cars do not have any options at all.
8) Explain what you mean by a probability of an event E and then solve the following
problem. If one tosses a fair coin four times, what is the probability of getting two
heads and two tails?
9) The freshman class of a private engineering college has 300 students. It is known that
180 can program in PASCAL, 120 in FORTRAN, 30 in c++, 12 in PASCAL and c++,
18 in FORTRAN and c++, 12 in PASCAL and FORTRAN, and 6 in all three
languages If two students are selected at random, what is the probability that they can
i) Both program in PASCAL?
ii) Both program only in PASCAL?
10) In a survey of 120 passengers, an airline found that 48 enjoyed wine with their meals,
78 enjoyed mixed drinks, 66 enjoyed iced tea. In addition, 36 enjoyed any given pair of
these beverages and 24 enjoyed them all. If two passengers are selected at random from
the survey sample of 120, what is the probability that they both want only iced tea with
their meals?
11) The Ackermanns numbers A m, n are defined recursively for m, n N as follows.
A0,n = n+1 for n 0, A m,0 = A m-1,1 fo r m 1
Am,n = Am-1,p where p = Am,n-1, for m,n1
Prove that A1, n = n + 2 for all n 0.
12) Show that (p v q) (q v p) is a tautology.

Dept. of CSE, SJBIT Page 1


DISCRETE MATHEMATICAL STRUCTURES 15CS35

13) Out of 30 students in a dormitory, 15 take an art course, 8 take a biology course, and 6
take a chemistry course. It is known that 3 students take all three courses. Show that 7
or more students take none of the course.
14) If N is the set of positive integers and R is the set of real numbers, examine which of the
following sets is empty :

{x | xN, 2x + 7 = 3}
{x | x R, x2 + 4 = 6}
{x | x R, x2 + 3x + 3 = 0}.
15) Using Venn diagrams, investigate the truth or falsity of :
i) A (B C) = (A B) (A C)
ii) A (B C) = (A B) (A C) for any three sets A, B, C.
16) Simplify the following :
i) A (BA)
-
ii) (A B) (A B) (A B C D).
17) A fair coin is tossed five times. What is the probability that the number of heads always
exceeds the number of tails as each outcome is observed.

18) If statement q has the truth value 1, determine all truth value assignments for the
primitive statements p, r, and s for which the truth value of the statement
19) Establish the validity or provide a counter example to show the invalidity of the
following arguments :
i) pq
p r
r
q
ii) p
pr
p (q r)
q s
s
20) Verify that [p(qr)][(pq)(pr)] is a tautology.
21) Write dual, negation, converse, inverse and contrapositive of the statement given below :
22) If Kabir wears brown pant, then he will wear white shirt. Test whether the following
argument is valid:
If Rams computer program is correct then he will be able to complete his computer
science assignment in at most two hours.
It takes Ram over two hours to complete his computer science assignment.
Therefore Rams computer program is incorrect.
23) Test whether the following argument is valid:
If Rams computer program is correct then he will be able to complete his computer
Dept. of CSE, SJBIT Page 2
DISCRETE MATHEMATICAL STRUCTURES 15CS35

science assignment in at most two hours.


It takes Ram over two hours to complete his computer science assignment.
Therefore Rams computer program is incorrect.
24) Write down the following proposition in symbolic form, and find its negation,
(i) For all integers n, if n is not divisible by 2, then n is odd.
(ii) All integers are rational numbers and some rational numbers are not integers.
(iii) For the universe of integers, if r(x): 2x +1 = 5; s(x): x2 =9 are open sentences.
Obtain the negation of a quantified statement x [r(x) s(x)].
25)Write the following in symbolic form and establish if the argument is valid : If A gets the
supervisors position and works hard, then he will get a raCSE. If he gets a raCSE, then
he
will buy a new car. He has not bought a new car. Therefore A did not get the
supervisors position or he did not work hard.

26) Verify the following without, using truth tables :

[(p q) ( r s) (p r)] q s.

27) Define tautology. Show that [(p q) (p r) (q r)] r is a tautology, b y


constructing a truth table.

28) Show that the following argument is invalid by giving a counter example :

29) [(p q) {p (q r)}] r.

30) Define (pq) (pq). Represent pq and pq using only .

MODULE 2: Fundamentals of Logic contd

1) For the universe of all people, find whether the following is a valid statement:
All mathematics professors have studied calculus
Ramanujan is a mathematics professor
Therefore Ramanujan has studied calculus.
2) Define the Rule of Universal specification and the Rule of Universal Generalization.

3) Verify if the following is valid :

x[p(x) q(x)] ; x p(x)

x[ g(x) r(x)]

x[s(x) r(x)] x s(x).


4) Prove that for all real numbers x and y, if x + y > 100, then x > 50 or y > 50.

Dept. of CSE, SJBIT Page 3


DISCRETE MATHEMATICAL STRUCTURES 15CS35

5) Determine if the argument is valid or not. All people concerned about the environment,
recycle their plastic containers. B is not concerned about the environment. Therefore, B
does not recycle his plastic containers.

6) Negate and simplify :

i) x[p(x) q(x)]

ii) x [(p(x) q(x)) r(x)].


7) Prove that for every integer n, n2 is even if and only if n is even.
8) Let p(x, y) denote the open statement x divides where the universe consists of all
integers. Determine the truth values of the following statements. Justify your answers.
9) x y [p(x, y) p(y, x) (x = y)]
10) x y [p(x, y) p(y, x)]
11) State the following:
(i) Well-Ordering Principal
(ii) Principal of mathematical induction.
12) Prove by mathematical induction
For every positive integer n, 3 divides (n3 n).
For all positive integers n>=6, 4n < ( n2-7).
13) If nN, prove that 5Fn+2 =Ln+4 - Ln.
14) Define the following : i) Well ordering principle

15) ii) Principle of mathematical induction.

16) Establish the following by mathematical induction :


n
i (2i ) = 2 + (n - 1)2n+1 .
t=1

17) Find a unique solution for the recurrence relation : 4an 5an1 = 0, n 1, a0 = 1.

18) Let Fn denote the nth Fibonacci number :

n F(i-1) F(n+2)
Pro v e t h a t
i=1 2 i
= 1-
2n
.

19)
20)

21)

Dept. of CSE, SJBIT Page 4


DISCRETE MATHEMATICAL STRUCTURES 15CS35

MODULE 3: Relations and Functions

1) Let R and S are symmetric relations on the set A. Prove that intersection of these two is
also symmetric.
2) Define stirling number of the second kind . Let a={1,2,3,4,5,6,7} and B={w,x,y,z} find
the number of onto functions from A to B
3) Let T be the set of all triangles. Define a relation R on T by t1 R t2 if t1 and t2 have an
angle of same measure. Verify whether R is an equivalence relation.
4) Define Cartesian product of two sets. For nonempty sets A, B, C prove that,
A (B C) = (A B) (A C).

5) For each of the following functions, determine whether it is 1 1 :

6) i) f : Z Z, f(x) = 2x + 1 ii) f : Z Z, f(x) = x3 x.

7) Let A = B = C = R, f : A B, f(a) = 2a + 1 ; g : B C, g(b) = b/2. Compute gof and


show that it is invertible.

8) Let ABC be an equilateral triangle of side 1. Show that if we select 10 points in the
interior, there must be at least two points whose distance apart is less than 1/3.
9) Give an example of a relation from A to B B which is not a function.
10) How many onto functions are there from (i) A to B, (ii) B to A?
11) Write a function f : AC and a function g : CA. Find gof : AA.
12) Write an invertible function f : AC and find its inverse.

MODULE 4: Relations contd

1) Prove that a function f : AB is invertible iff it is one-one and onto.


2) Define the different properties of relation with examples.
3) Verify that (A, R) is a poset and draw its Hasse diagram where u= {1,2,3}, A = p(u)
and R is a subset relation on A.
4) Let A = {1,2,3,4,5}. Defi ne a relation r on A x A as (x1, y1)) R (x2, y2) if x1 + y1 = x2 + y2
5) Verify that R is an equivalence relation
6) Determine the equivalence classes {(1, 3)],[(2, 4)], and [(1,1)]
7) Determine the partition on A induced by R.
8) For each of the following relations, determine if the relation R is reflexive, symmetric,
antisymmetric or transitive :

9) On the set of all lines in the plane, l1Rl2 if line l1 is perpendicular to live l2
10) On Z, xRy if x y is even.
11) For A = {1, 2, 3, 4}, let R = {(1, 1), (1, 2), (2, 3), (3, 3), (3, 4)} be a relation on A. Draw
the digraph of R2 and find the matrix M(R2).

Dept. of CSE, SJBIT Page 5


DISCRETE MATHEMATICAL STRUCTURES 15CS35

12) Draw the Hasse diagram for all the positive integer division of 72.

13) Let A = {1, 2, 3, 4, 5, 6} {1, 2, 3, 4, 5, 6}. Define R on A by (x1, y1) R(x2, y2)
if x1y1 = x2y2. Verify that R is an equivalence relation on A.
14) Let A = {1, 2, 3, 4, 5} {1, 2, 3, 4, 5} and define R as
i) Verify that R is an equivalence relation on A.
ii) Determine the equivalence class [(1, 3)].
iii) Determine the partition induced by R.
15) Let A = {1, 2, 3, 6, 9, 12, 18} and define a relation R on A as xRy iff x|y. Draw the
Hasse diagram for the poset (A, R)
16) Let A = {1, 2, 3, 4}, B = {w, x, y, z} and C = {p, q, r, s}. Consider R 1= {(1, x), (2, w),
(3, z)}a relation from A to B, R2 = {(w, p), (z, q), (y, s), (x, p)} a relation from B to C.
What is the composite relation R1 R2 form A to C?

MODULE 5: Groups

1) Define acyclic group with an example. Prove that every cyclic group is abelian.6 marks
2) If (G, *) and (H,*) are groups with respective identities eG and eH , and f : G H is an
isomorphism, prove that f(eG) = eH.
3) Prove that in a group code the minimum distance between distinct code words is the
minimum of the weights of the nonzero elements of the code
4) For a group(G1), prove that it is abelian if (a, b)2 = a2,b2 for all a, bG.

0 1 2 3 4
5) Let A = . Verify that (A, A , A , A ) form an abelian group under matrix
-1 0
multiplication.

6) Define a cyclic group. Verify that (Z , ) is



5 cyclic. Find a generator of this group.
Examine if it has any subgroups.
7) Define a binary operation on Z as x y = x + y 1. Verify that (Z, ) is an abelian group.
8) Let f : G H be a group homomorphism onto H. If G is an abelian group, prove that H is
also abelian.

9) The encoding function is given by the generator matrix


10) Determine all the code words.
11) Find the associated parity-check matrix H
12) Define a group code. Consider the encoding function E: Z2 > Z2 6 of the triple
repetition code where E(00)=000000, E(10) = 101010, E(01) = 0210101, E(11)=111111.
Prove that C = E(Z2 2) is a group code.
13) Define a ring. If R is a ring with unity and a,b are units in R Prove that ab is a unit in R
and that (ab)-1=b-1a-1

Dept. of CSE, SJBIT Page 6


DISCRETE MATHEMATICAL STRUCTURES 15CS35

14) Determine whether (Z, ,) is a ring with the binary operations xy = x + y 7,


xy = x + y 3xy for all x,y Z.

15) The (5m, m) five times repetition code has encoding function E : Z2m Z25m.
Decoding with D : Z25m Z2m is done by majority rule. With p = 0.05, what is the
probability for the transmission and correct decoding of the signal 110.

16) What is the minimum distance of a code consisting of the following code words :

17) 001010, 011100, 010111, 011110, 101001? What kind of errors can be detected?

18) The encoding function E : Z22 Z25 is given by the generator matrix
1 0 1 1 0
G = . What is the error detection capacity of the code?

0 1 0 1 1

19) Let R be a ring with unity and a, b be units in R. Prove that ab is a unit of R and that

20) Find multiplicative inverse of each (non-zero) element of Z7

21)

Dept. of CSE, SJBIT Page 7


CBCS STUDENTS ARE ADVISED TO REFER THEIR
SYLLABUS
COMPARE & STUDY
THE FOLLOWING QUESTIONS PAPERS ARE FROM 2010
SCHEME
USN 10CS34

Third Semester B.E. Degree Examination, June 2012


Discrete Mathematical Structures

Time: 3 hrs. Max. Marks:100


Note: Answer FIVE full questions, selecting
2. Any revealing of identification, appeal to evaluator and /or equations written eg, 42+8 = 50, will be treated as malpractice.

at least TWO questions from each part.

PART A
1 a. Let S = {21, 22, 23, .., 39, 40}. Determine the number of subsets A of S such that :
i) |A| = 5
ii) |A| = 5 and the largest element in A is 30
iii) |A| = 5 and the largest element is at least 30
Important Note : 1. On completing your answers, compulsorily draw diagonal cross lines on the remaining blank pages.

iv) |A| = 5 and the largest element is at most 30


v) |A| = 5 and A consists only of odd integers. (10 Marks)
b. Prove or disprove: For non-empty sets A and B, P(AB) = P(A)P(B) where P denotes
power set. (05 Marks)
c. In a group of 30 people, it was found that 15 people like Rasagulla, 17 like Mysorepak, 15
like Champakali, 8 like Rasagulla and Mysorepak, 11 like Mysorepak and Champakali, 8
like Champakali and Rasagulla and 5 like all three. If a person is chosen from this group,
what is the probability that the person will like exactly 2 sweets? (05 Marks)

2 a. Verify that [p(qr)][(pq)(pr)] is a tautology. (05 Marks)


b. Write dual, negation, converse, inverse and contrapositive of the statement given below :
If Kabir wears brown pant, then he will wear white shirt. (05 Marks)
c. Define (pq) (pq). Represent pq and pq using only . (05 Marks)
d. Establish the validity or provide a counter example to show the invalidity of the following
arguments : (05 Marks)
i) pq ii) p
pr pr
r p(qr)
q qs
s
3 a. For the universe of all polygons with three or four sides, define the following open
statements:
i(x): all the interior angles of x are equal
h(x): all sides of x are equal
s(x): x is a square
t(x): x is a triangle
Translate each of the following statements into an English sentence and determine its truth
value:
i) x [s(x) (i(x) h(x))]
ii) x [t(x) (i(x) h(x))]
Write the following statements symbolically and determine their truth values.
iii) Any polygon with three or four sides is either a triangle or a square
iv) For any triangle if all the interior angles are not equal, then all its sides are not equal.
(08 Marks)
1 of 2
10CS34
3 b. Let p(x, y) denote the open statement x divides where the universe consists of all integers.
Determine the truth values of the following statements. Justify your answers.
i) x y [p(x, y) p(y, x) (x = y)] ii) x y [p(x, y) p(y, x)] (06 Marks)
c. Prove that for every integer n, n2 is even if and only if n is even. (06 Marks)

n
1 n
4 a. Prove i(i 1) n 1 nz+. (06 Marks)
i 1
b. Prove 2n < n! n > 3 and n z+. (06 Marks)
c. Define an integer sequence recursively by
a0 = a 1 = a 2 = 1
an = an1 + an3 n 3.
Prove that a n 2 ( 2 ) n n 0. (08 Marks)

PART B
5 Let A = {, , }, B = {, }, C = {, , }.
a. Find (AB)C, A(BC), (AB)C and A(BC). (08 Marks)
b. Give an example of a relation from A to B B which is not a function. (04 Marks)
c. How many onto functions are there from (i) A to B, (ii) B to A? (02 Marks)
d. i) Write a function f : AC and a function g : CA. Find gof : AA.
ii) Write an invertible function f : AC and find its inverse. (06 Marks)

6 a. Let A = {1, 2, 3, 4}, B = {w, x, y, z} and C = {p, q, r, s}. Consider R1 = {(1, x), (2, w), (3, z)}
a relation from A to B, R2 = {(w, p), (z, q), (y, s), (x, p)} a relation from B to C.
i) What is the composite relation R1 R 2 form A to C?
ii) Write relation matrices M(R1), M(R2) and M(R1 R2)
iii) Verify M(R1) M(R 2) = M(R1R2) (06 Marks)
b. Let A = {1, 2, 3, 6, 9, 12, 18} and define a relation R on A as xRy iff x|y. Draw the Hasse
diagram for the poset (A, R). (06 Marks)
c. Let A = {1, 2, 3, 4, 5} {1, 2, 3, 4, 5} and define R as (x1, y1)R(x2, y2) iff x1 + y1 = x2 + y2.
i) Verify that R is an equivalence relation on A.
ii) Determine the equivalence class [(1, 3)].
iii) Determine the partition induced by R. (08 Marks)

7 a. Define a binary operation on Z as x y = x + y 1. Verify that (Z, ) is an abelian group.


(07 Marks)
b. Let f : G H be a group homomorphism onto H. If G is an abelian group, prove that H is
also abelian. (07 Marks)
1 0 1 1 0
c. The encoding function E : Z 22 Z52 is given by the generator matrix G .
0 1 0 1 1
i) Determine all the code words.
ii) Find the associated parity-check matrix H. (06 Marks)

a b a b
8 a. If M 2 ( R ) , prove that c d is a unit of this ring if and only if ad bc 0.
c d
(08 Marks)
b. Let R be a ring with unity and a, b be units in R. Prove that ab is a unit of R and that
(ab)-1 = b-1a-1. (06 Marks)
c. Find multiplicative inverse of each (non-zero) element of Z7. (06 Marks)

*****
2 of 2

Click to Download VTU CAMPUS Android APP.


Get : VTU Alerts, Notes, Question Papers
Events, Circulars and a lot more!

Vous aimerez peut-être aussi