0% found this document useful (0 votes)
45 views31 pages

Lecture-1 Discrete Structure

The document provides information about a discrete mathematics course. It outlines the course details including the instructor, credits, schedule, assessment details, topics to be covered, reference material, teaching methodology, and learning outcomes of the first lecture on introduction to discrete mathematics. Discrete mathematics finds applications in computer science and other fields involving discrete objects and processes.

Uploaded by

laiba.khan4520
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
45 views31 pages

Lecture-1 Discrete Structure

The document provides information about a discrete mathematics course. It outlines the course details including the instructor, credits, schedule, assessment details, topics to be covered, reference material, teaching methodology, and learning outcomes of the first lecture on introduction to discrete mathematics. Discrete mathematics finds applications in computer science and other fields involving discrete objects and processes.

Uploaded by

laiba.khan4520
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 31

Discrete

Dr. Mathematics
Shahid Munir Shah, Department
of Computer
Facilitator: Dr.Science, Salim
Shahid Munir Habib
shah, Spring
University, Karachi.2022

Dr. Shahid Munir Shah, CSC 210 - Discrete 1


Structures, Spring, 2022
Course particulars
Course Code: CSC – 210
Credit Hours: 3 (3 Th.).
Theory Class: Class Room # C22,
Mon (11:30 AM – 1:00 PM)
– Wed (8:30 AM – 10:00 AM)

Dr. Shahid Munir Shah, CSC 210 - Discrete 2


Structures, Spring, 2022
Marks distribution and
important dates

Mid Term Exam: 20 marks (after 7 weeks)


Final Term Exam: 50 marks (after 16
weeks)
Sessional: 30 marks
– Assignments, Quizzes (announced + surprise),
Presentations (20)
– Class participation/class performance, Attendance (10)

Dr. Shahid Munir Shah, CSC 210 - Discrete 3


Structures, Spring, 2022
Course Outline
Mathematical reasoning, propositional and predicate logic, rules
of inference.
Proof by induction, proof by contraposition, proof by
contradiction, proof by implication.
Set theory, relations, equivalence relations and partitions,
partial orderings, recurrence relations, functions, mappings,
function composition, inverse functions, recursive functions.
Number Theory, sequences, series, counting, inclusion and
exclusion principle, pigeonhole principle permutations and
combinations.
Elements of graph theory, planar graphs, graph coloring, euler
graph, Hamiltonian path, rooted trees, traversals.

Dr. Shahid Munir Shah, CSC 210 - Discrete 4


Structures, Spring, 2022
Reference Material
1. Discrete Mathematics and Its Applications,
SEVENTH EDITION, Kenneth H. Rosen (Text
Book)
2. Discrete Mathematics by Example by Andrew
Simpson
3. Discrete Mathematics with Applications, 4th
Edition by Susanna S. Epp
4. Discrete Mathematical Structures, 4th edition by
Kolman, Busby & Ross .
5. Discrete and Combinatorial Mathematics: An
Applied Introduction by Ralph P. Grimaldi
6. Logic and Discrete Mathematics: A Computer
Science Perspective by
Dr. Shahid Munir Winifred
Shah, Grassman
CSC 210 - Discrete
Structures, Spring, 2022
5
Teaching methodology
Teaching during semester will be
based on the following
components:
1. Multimedia lectures
2. White board lectures
3. Group discussions
4. At the spot individual presentations
5. Demonstrations

Dr. Shahid Munir Shah, CSC 210 - Discrete 6


Structures, Spring, 2022
Class rules and regulations
1. No late arrival
2. No use of mobile phones
3. No cheating in quizzes,tasks, exams etc. (be
honest)

Dr. Shahid Munir Shah, CSC 210 - Discrete 7


Structures, Spring, 2022
Lecture # 1

Introduction to Discrete
mathematics (DM)

Dr. Shahid Munir Shah, CSC 210 - Discrete 8


Structures, Spring, 2022
Class Learning outcomes
After completing this lecture, students should be
able to:
• Explain different branches of Mathematics
• Understand the definition of Discrete
Mathematics (DM)
• Explore different application areas of DM
especially in the field of Computer Science.
• Define set theory and its applications in CS
• Demonstrate different methods of representing
sets
• Define different well known sets
Dr. Shahid Munir Shah, CSC 210 - Discrete 9
Structures, Spring, 2022
Mathematics
There are four main branches of
Mathematics i.e.
• Geometry
• Calculus
• Numbers Theory
• Discrete Mathematics

Dr. Shahid Munir Shah, CSC 210 - Discrete 10


Structures, Spring, 2022
Geometry
It is the one of the oldest
mathematical branch (roughly 2
to 3000 years old)
A mathematical manual “ The sea
island” has been found in China.
This mathematical manual shows
that the ancient Chinese were Image source :
https://en.wikipedia.org/wiki/Haidao_S
using Geometry concepts to uanjing

measure distance on land, to


measure areas and to build
houses.
Dr. Shahid Munir Shah, CSC 210 - Discrete 11
Structures, Spring, 2022
Calculus
Deals with the continues data i.e. real
numbers
For example;
Functions with real numbers, calculus
(derivatives, integrals).
Newton and Leibniz invented it in 17th and
18th century.
They invented calculus to understand the
objects in motion (like the motion of
earth around sun
Dr. Shahid Muniretc.).
Shah, CSC 210 - Discrete 12
Structures, Spring, 2022
Numbers Theory
It is an oldest part of maths
but almost for 2000 years
it was just a game without
any application
During 17th century Diffie–
Hellman proposed public-
key protocols for securely Image source :

exchanging cryptographic https://en.wikipedia.org/wiki/Diffie%E


2%80%93Hellman_key_exchange

keys over a public channel.

Dr. Shahid Munir Shah, CSC 210 - Discrete 13


Structures, Spring, 2022
Dr. Shahid Munir Shah, Department
Discrete
of Computer Science, Salim Habib
Structures/Mathematics
University, Karachi.

Dr. Shahid Munir Shah, CSC 210 - Discrete 14


Structures, Spring, 2022
What is Discrete
Mathematics (DM)
DM is the part of mathematics devoted to
the study of discrete objects. (Here discrete means
consisting of distinct or unconnected
elements.) (Kneth. H. Rosen, 7th edition).

DM is the study of mathematical structures that are


fundamentally discrete rather than continuous.
(Wikipedia, accessed, April, 19, 2022).

Dr. Shahid Munir Shah, CSC 210 - Discrete 15


Structures, Spring, 2022
Why Discrete Mathematics
• To design logic and to create mathematical
arguments
• To develop problem solving capabilities
• Understanding of digital computers more easily
(computer understands 0’s and 1’s only)
• To understand different CS courses more in depth
(DM is a gateway for many Computer Science (CS)
courses like data structures, algorithms, database
theory, automata theory, formal languages,
compiler theory, computer security, and operating
systems)
Dr. Shahid Munir Shah, CSC 210 - Discrete 16
Structures, Spring, 2022
Applications of Discrete
Mathematics (1)
• Computer process only
Zero’s and 1’s (Why?).
• All software, music,
documents, images, text
and any other
information that is
processed by a computer,
is stored as binary
strings.
• Binary maths is discrete
Mathematics and to Image Taken from Internet Sources

understand binary we
need to understand DM
Dr. Shahid Munir Shah, CSC 210 - Discrete 17
Structures, Spring, 2022
Applications of Discrete
Mathematics (1)
• DM contains topics such as graph coloring and combinatorial
optimization which are used for scheduling.
• DM works with google maps to find the fastest routes and time.
• DM plays a role in secure internet usage by inscription and
decryption methods.
• DM is used in different encoding methods that are used for the
correct transformation of the digital information.
• DM is heavily used in digital image processing such as merging
images, applying filters etc.
• Hidden Markov Models use concepts of DM and are used in
different applications such as automatic speech and speaker
recognition systems.
• Linear algebra is a part od DM that deals with many daily life
applications such as web searching with multiple languages,
compressive sensing, medical imaging, Data compression, reduction
of noise in data, and automated recommendations of movies etc.
Dr. Shahid Munir Shah, CSC 210 - Discrete 18
Structures, Spring, 2022
Applications of Discrete
Mathematics (2)
How many ways are there to choose a valid password on a computer system?
How the matches of Pakistan Super League (PSL) can be scheduled
(combinatorial optimization)
What is the probability of winning a lottery? (discrete probability )
Is there a link between two computers in a network?
How can I identify spam e-mail messages? (linear algebra)
How can I encrypt a message so that no unintended recipient can read it?
(cryptography)
What is the shortest path between two cities using a transportation system?
(searching, graph theory)
How can a list of integers be sorted so that the integers are in increasing
order? (sorting methods)
How many steps are required to do such a sorting?
How can it be proved that a sorting algorithm correctly sorts a list? (
How can a circuit that adds two integers be designed? (Propositional Logic)
How many valid Internet addresses are there? (graph theory)
For more applications please visit: http://www.mathily.org/dm-rw.html
Dr. Shahid Munir Shah, CSC 210 - Discrete 19
Structures, Spring, 2022
Let’s get started with...

Logic! And Proofs

Dr. Shahid Munir Shah, CSC 210 - Discrete 20


Structures, Spring, 2022
Logic and Argument
Logic: Logic is a science of the necessary laws of thought,
without which no employment of the understanding and the
reason takes place. —Immanuel Kant, 1785

In simple Words: Logic is the study of the principles and


methods that distinguish between a
valid and an invalid argument.

Argument: In mathematics, an argument is a sequence of


propositions (called premises) followed by a proposition
(called conclusion) • A valid argument is one that, if all its
premises. are true, then the conclusion is true (Wikipedia)

Dr. Shahid Munir Shah, CSC 210 - Discrete 21


Structures, Spring, 2022
Example-1 (Argument)
Argument-1: Arument-2:
If the program syntax is
faulty or if program If x is a real number
such that x < −2 or x > 2,
execution results in then x 2 > 4 (premises)..
division by zero then the
computer will generate an Therefore, if x 2 ≯ 4,

error message (premises). then x ≮ −2 and x ≯ 2


(conclusion).
Therefore, if the computer
does not generate an error
message, then the program
syntax is correct and
program execution does
not result in Dr.division
Shahid Munirby
Shah, CSC 210 - Discrete 22
zero(conclusion). Structures, Spring, 2022
Representing Arguments
To illustrate the logical form of the arguments listed
on previous slide, letters of the alphabet (such as
p, q, and r) are used to represent the component
sentences and the expression “not p” to refer to
the sentence “It is not the case that p.”
Then the common logical form of both the previous
arguments is as follows:
If p or q, then r. Therefore, if not r, then not p
and not q.

Dr. Shahid Munir Shah, CSC 210 - Discrete 23


Structures, Spring, 2022
Logic
• Propositional Logic is a system based on
propositions.
• A proposition is a (declarative) statement
that is either true or false (not both).
• We say that the truth value of a proposition
is either true (T) or false (F).
• Corresponds to 1 and 0 in digital circuits

Dr. Shahid Munir Shah, CSC 210 - Discrete 24


Structures, Spring, 2022
The Statement/Proposition Game

“Elephants are bigger than mice.”

Is this a statement? yes

Is this a proposition? yes

What is the truth value


of the proposition? true

Dr. Shahid Munir Shah, CSC 210 - Discrete 25


Structures, Spring, 2022
The Statement/Proposition Game

“520 < 111”

Is this a statement? yes

Is this a proposition? yes

What is the truth value


of the proposition? false

Dr. Shahid Munir Shah, CSC 210 - Discrete 26


Structures, Spring, 2022
The Statement/Proposition Game

“y > 5”

Is this a statement? yes


Is this a proposition? no

Its truth value depends on the value of y,


but this value is not specified.
We call this type of statement a
propositional function or open sentence.
Dr. Shahid Munir Shah, CSC 210 - Discrete 27
Structures, Spring, 2022
The Statement/Proposition Game

“Today is January 27 and 99 < 5.”

Is this a statement? yes

Is this a proposition? yes

What is the truth value


of the proposition? false

Dr. Shahid Munir Shah, CSC 210 - Discrete 28


Structures, Spring, 2022
The Statement/Proposition Game

“Please do not fall asleep.”

Is this a statement? no
It’s a request.

Is this a proposition? no

Only statements can be propositions.

Dr. Shahid Munir Shah, CSC 210 - Discrete 29


Structures, Spring, 2022
The Statement/Proposition Game
“If the moon is made of cheese,
then I will be rich.”

Is this a statement? yes

Is this a proposition? yes

What is the truth value


of the proposition? probably true

Dr. Shahid Munir Shah, CSC 210 - Discrete 30


Structures, Spring, 2022
The Statement/Proposition Game
“x < y if and only if y > x.”
Is this a statement? yes
Is this a proposition? yes
… because its truth value
does not depend on
specific values of x and y.
What is the truth value
of the proposition? true
Dr. Shahid Munir Shah, CSC 210 - Discrete 31
Structures, Spring, 2022

You might also like