SlideShare a Scribd company logo
1 of 25
T O P I C : L O G I C A N D C O M P O U N D S T A T E M E N T
B Y : S A M E E R M U N I R
L E C T U R E R , D C S
N T U , F A I S A L A B D
Discrete Structures
Course Objectives
sameerahmadch@gmail.com
2
1.Express statements with the precision of formal logic
2.Analyze arguments to test their validity
3.Apply the basic properties and operations related to sets
4.Apply to sets the basic properties and operations related to
relations and function
5.Define terms recursively
6.Prove a formula using mathematical induction
7.Prove statements using direct and indirect methods
8.Compute probability of simple and conditional events
Course Objectives
sameerahmadch@gmail.com
3
9.Identify and use the formulas of combinatorics in different
problems
10.Illustrate the basic definitions of graph theory and
properties of graphs
11.Relate each major topic in Discrete Mathematics to an
application area in computing
sameerahmadch@gmail.com
4
 What is Discrete Mathematics?:
 Discrete Mathematics concerns processes that
consist of a sequence of individual steps.
Continuous
Discrete
Logic
sameerahmadch@gmail.com
5
LOGIC:
 Logic is the study of the principles and methods that
distinguishes between a valid and an invalid argument.
SIMPLE STATEMENT:
 A statement is a declarative sentence that is either true or
false but not both.
 A statement is also referred to as a proposition
Example: 2+2 = 4, It is Sunday today
 If a proposition is true, we say that it has a truth value of
"true”.
 If a proposition is false, its truth value is "false".
 The truth values “true” and “false” are, respectively,
denoted by the letters T and F.
Logic
sameerahmadch@gmail.com
6
 EXAMPLES :
 Grass is green.
 4 + 2 = 6
 4 + 2 = 7
 There are four fingers in a hand.
are propositions
Logic
sameerahmadch@gmail.com
7
 Not Propositions
 Close the door.
 x is greater than 2.
 He is very rich
are not propositions.
Logic
sameerahmadch@gmail.com
8
Rule:
 If the sentence is preceded by other sentences that make
the pronoun or variable reference clear, then the sentence
is a Statement.
Example
 Bill Gates is an American
 He is very rich
 He is very rich is a statement with truth-value TRUE.
Example
 x = 1
 x > 2
 x > 2 is a statement with truth-value FALSE.
Logic
sameerahmadch@gmail.com
9
 UNDERSTANDING STATEMENTS:
 x + 2 is positive. Not a statement
 May I come in? Not a statement
 Logic is interesting. A statement
 It is hot today. A statement
 -1 > 0 A statement
 x + y = 12 Not a statement
Logic
sameerahmadch@gmail.com
10
COMPOUND STATEMENT :
 Simple statements could be used to build a
compound statement.
EXAMPLES:
 1. “3 + 2 = 5” and “Lahore is a city in Pakistan”
 2. “The grass is green” or “ It is hot today”
 3. “Discrete Mathematics is not difficult to me”
 AND, OR, NOT are called LOGICAL
CONNECTIVES.
Logic
CONNECTIVE MEANING SYMBOL CALLED
Negation not ~ Tilde
Conjunction and  Hat
Disjunction or  Vel
Conditional if…then…  Arrow
Biconditional if and only if  Double arrow
sameerahmadch@gmail.com
11
Logic
sameerahmadch@gmail.com
12
SYMBOLIC REPRESENTATION:
 Statements are symbolically represented by letters such as p, q,
r,...
EXAMPLES:
 p = “Islamabad is the capital of Pakistan”
 q = “17 is divisible by 3”
Logic
sameerahmadch@gmail.com
13
EXAMPLES:
 p = “Islamabad is the capital of Pakistan”
 q = “17 is divisible by 3”
 p  q = “Islamabad is the capital of Pakistan and
17 is divisible by 3”
 p  q = “Islamabad is the capital of Pakistan or 17
is divisible by 3”
 ~p = “It is not the case that Islamabad is the
capital of Pakistan” or simply “Islamabad is not
the capital of Pakistan”
Logic
sameerahmadch@gmail.com
14
TRANSLATING FROM ENGLISH TO
SYMBOLS:
 Let p = “It is hot”, and q = “It is sunny”
SENTENCE SYMBOLIC FORM
1. It is not hot. ~ p
2. It is hot and sunny. p q
3. It is hot or sunny. p  q
4. It is not hot but sunny. ~ p q
5. It is neither hot nor sunny. ~ p  ~ q
Logic
sameerahmadch@gmail.com
15
EXAMPLE:
Let h = “Zia is healthy”
w = “Zia is wealthy”
s = “Zia is wise”
Translate the compound statements to symbolic form:
1. Zia is healthy and wealthy but not wise. (h  w)  (~s)
2. Zia is not wealthy but he is healthy and wise. ~w  (h  s)
3. Zia is neither healthy, wealthy nor wise. ~h  ~w  ~s
Logic
sameerahmadch@gmail.com
16
TRANSLATING FROM SYMBOLS TO ENGLISH:
Let m = “Ali is good in Mathematics”
c = “Ali is a Computer Science student”
Translate the following statement forms into plain English:
~ c Ali is not a Computer Science student
c m Ali is a Computer Science student or good in Maths.
m  ~c Ali is good in Maths but not a Computer Science student
 A convenient method for analyzing a compound statement is to make a
truth table for it.
 A truth table specifies the truth value of a compound proposition for
all possible truth values of its constituent propositions.
Logic
sameerahmadch@gmail.com
17
 NEGATION (~):
 If p is a statement variable, then negation of p, “not
p”, is denoted as “~p”
 It has opposite truth value from p i.e., if p is true, ~p
is false; if p is false, ~p is true.
Logic
 TRUTH TABLE FOR ~ p
p ~ p
T F
F T
sameerahmadch@gmail.com
18
Logic
sameerahmadch@gmail.com
19
 CONJUNCTION ():
 If p and q are statements, then the conjunction of p
and q is “p and q”, denoted as “p  q”.
 It is true when, and only when, both p and q are true.
If either p or q is false, or if both are false, pq is
false.
Logic
 TRUTH TABLE FOR p  q
p q p  q
T T T
T F F
F T F
F F F
sameerahmadch@gmail.com
20
Logic
sameerahmadch@gmail.com
21
 DISJUNCTION () or INCLUSIVE OR
 If p & q are statements, then the disjunction of p
and q is “p or q”, denoted as “p  q”.It is true
when at least one of p or q is true and is false only
when both p and q are false.
Logic
 TRUTH TABLE FOR p  q
p q p  q
T T T
T F T
F T T
F F F
sameerahmadch@gmail.com
22
Logic
sameerahmadch@gmail.com
23
 Note that in the table F is only in that row where both p
and q have F and all other values are T. Thus for finding out
the truth values for the disjunction of two statements we
will only first search out where the both statements are
false and write down the F in the corresponding row in the
column of p  q and in all other rows we will write T in the
column of p  q.
 Remark: Note that for Conjunction of two statements we
find the T in both the statements, but in disjunction we find
F in both the statements. In other words we will fill T first
in the column of conjunction and F in the column of
disjunction.
Logic
sameerahmadch@gmail.com
24
 Draw Truth Tables for:
 ~ p  q
 ~ p  (q  ~ r)
 (pq)  ~ (pq)
Summary
sameerahmadch@gmail.com
25
 What is a statement?
 How a compound statement is formed.
 Logical connectives (negation, conjunction,
disjunction).
 How to construct a truth table for a statement form.

More Related Content

Similar to Lecture # 1.ppt

Drinkfromme.pptx
Drinkfromme.pptxDrinkfromme.pptx
Drinkfromme.pptxRavind8
 
Logic in Computer Science Unit 2 (1).pptx
Logic in Computer Science Unit 2 (1).pptxLogic in Computer Science Unit 2 (1).pptx
Logic in Computer Science Unit 2 (1).pptxPriyalMayurManvar
 
Chapter 01 - p1.pdf
Chapter 01 - p1.pdfChapter 01 - p1.pdf
Chapter 01 - p1.pdfsmarwaneid
 
MFCS PPT.pdf
MFCS PPT.pdfMFCS PPT.pdf
MFCS PPT.pdfjayarao21
 
Discrete mathematics by sadat sumon
Discrete mathematics by sadat sumonDiscrete mathematics by sadat sumon
Discrete mathematics by sadat sumonsadatsumon
 
logicproof-141212042039-conversion-gate01.pdf
logicproof-141212042039-conversion-gate01.pdflogicproof-141212042039-conversion-gate01.pdf
logicproof-141212042039-conversion-gate01.pdfPradeeshSAI
 
Konjungsi materi kelompok dua
Konjungsi  materi kelompok duaKonjungsi  materi kelompok dua
Konjungsi materi kelompok duaLois Tulangow
 
Report in math (conjunctions and disjunctions)
Report in math (conjunctions and disjunctions)Report in math (conjunctions and disjunctions)
Report in math (conjunctions and disjunctions)Omegaxis26
 
Discrete Structure
Discrete StructureDiscrete Structure
Discrete StructureSyed Umair
 
Basic Connectives and Truth Tables.ppt
Basic Connectives and Truth Tables.pptBasic Connectives and Truth Tables.ppt
Basic Connectives and Truth Tables.pptsamalaramesh4
 
20220818151924_PPT01 - The Logic of Compound and Quantitative Statement.pptx
20220818151924_PPT01 - The Logic of Compound and Quantitative Statement.pptx20220818151924_PPT01 - The Logic of Compound and Quantitative Statement.pptx
20220818151924_PPT01 - The Logic of Compound and Quantitative Statement.pptxssuser92109d
 
Computer Organization and Assembly Language
Computer Organization and Assembly LanguageComputer Organization and Assembly Language
Computer Organization and Assembly LanguageRaquel Mulles
 
Guia periodo i_2021_-_matematicas_9deg_-_revisada_(1)
Guia periodo i_2021_-_matematicas_9deg_-_revisada_(1)Guia periodo i_2021_-_matematicas_9deg_-_revisada_(1)
Guia periodo i_2021_-_matematicas_9deg_-_revisada_(1)ximenazuluaga3
 

Similar to Lecture # 1.ppt (20)

Drinkfromme.pptx
Drinkfromme.pptxDrinkfromme.pptx
Drinkfromme.pptx
 
Logic in Computer Science Unit 2 (1).pptx
Logic in Computer Science Unit 2 (1).pptxLogic in Computer Science Unit 2 (1).pptx
Logic in Computer Science Unit 2 (1).pptx
 
Chapter 01 - p1.pdf
Chapter 01 - p1.pdfChapter 01 - p1.pdf
Chapter 01 - p1.pdf
 
MFCS PPT.pdf
MFCS PPT.pdfMFCS PPT.pdf
MFCS PPT.pdf
 
Discrete mathematics by sadat sumon
Discrete mathematics by sadat sumonDiscrete mathematics by sadat sumon
Discrete mathematics by sadat sumon
 
logicproof-141212042039-conversion-gate01.pdf
logicproof-141212042039-conversion-gate01.pdflogicproof-141212042039-conversion-gate01.pdf
logicproof-141212042039-conversion-gate01.pdf
 
Chapter1p1.pdf
Chapter1p1.pdfChapter1p1.pdf
Chapter1p1.pdf
 
Konjungsi materi kelompok dua
Konjungsi  materi kelompok duaKonjungsi  materi kelompok dua
Konjungsi materi kelompok dua
 
Report in math (conjunctions and disjunctions)
Report in math (conjunctions and disjunctions)Report in math (conjunctions and disjunctions)
Report in math (conjunctions and disjunctions)
 
Per3 logika&pembuktian
Per3 logika&pembuktianPer3 logika&pembuktian
Per3 logika&pembuktian
 
dms.pptx
dms.pptxdms.pptx
dms.pptx
 
Discrete Structure
Discrete StructureDiscrete Structure
Discrete Structure
 
Basic Connectives and Truth Tables.ppt
Basic Connectives and Truth Tables.pptBasic Connectives and Truth Tables.ppt
Basic Connectives and Truth Tables.ppt
 
mathematics chapter 10.pptx
mathematics chapter 10.pptxmathematics chapter 10.pptx
mathematics chapter 10.pptx
 
Tablas de Verdad
Tablas de VerdadTablas de Verdad
Tablas de Verdad
 
Logic.pdf
Logic.pdfLogic.pdf
Logic.pdf
 
Mathematical Logic
Mathematical LogicMathematical Logic
Mathematical Logic
 
20220818151924_PPT01 - The Logic of Compound and Quantitative Statement.pptx
20220818151924_PPT01 - The Logic of Compound and Quantitative Statement.pptx20220818151924_PPT01 - The Logic of Compound and Quantitative Statement.pptx
20220818151924_PPT01 - The Logic of Compound and Quantitative Statement.pptx
 
Computer Organization and Assembly Language
Computer Organization and Assembly LanguageComputer Organization and Assembly Language
Computer Organization and Assembly Language
 
Guia periodo i_2021_-_matematicas_9deg_-_revisada_(1)
Guia periodo i_2021_-_matematicas_9deg_-_revisada_(1)Guia periodo i_2021_-_matematicas_9deg_-_revisada_(1)
Guia periodo i_2021_-_matematicas_9deg_-_revisada_(1)
 

Recently uploaded

UNIT-IFLUID PROPERTIES & FLOW CHARACTERISTICS
UNIT-IFLUID PROPERTIES & FLOW CHARACTERISTICSUNIT-IFLUID PROPERTIES & FLOW CHARACTERISTICS
UNIT-IFLUID PROPERTIES & FLOW CHARACTERISTICSrknatarajan
 
University management System project report..pdf
University management System project report..pdfUniversity management System project report..pdf
University management System project report..pdfKamal Acharya
 
data_management_and _data_science_cheat_sheet.pdf
data_management_and _data_science_cheat_sheet.pdfdata_management_and _data_science_cheat_sheet.pdf
data_management_and _data_science_cheat_sheet.pdfJiananWang21
 
AKTU Computer Networks notes --- Unit 3.pdf
AKTU Computer Networks notes ---  Unit 3.pdfAKTU Computer Networks notes ---  Unit 3.pdf
AKTU Computer Networks notes --- Unit 3.pdfankushspencer015
 
Online banking management system project.pdf
Online banking management system project.pdfOnline banking management system project.pdf
Online banking management system project.pdfKamal Acharya
 
Call Girls Walvekar Nagar Call Me 7737669865 Budget Friendly No Advance Booking
Call Girls Walvekar Nagar Call Me 7737669865 Budget Friendly No Advance BookingCall Girls Walvekar Nagar Call Me 7737669865 Budget Friendly No Advance Booking
Call Girls Walvekar Nagar Call Me 7737669865 Budget Friendly No Advance Bookingroncy bisnoi
 
UNIT-II FMM-Flow Through Circular Conduits
UNIT-II FMM-Flow Through Circular ConduitsUNIT-II FMM-Flow Through Circular Conduits
UNIT-II FMM-Flow Through Circular Conduitsrknatarajan
 
Call for Papers - Educational Administration: Theory and Practice, E-ISSN: 21...
Call for Papers - Educational Administration: Theory and Practice, E-ISSN: 21...Call for Papers - Educational Administration: Theory and Practice, E-ISSN: 21...
Call for Papers - Educational Administration: Theory and Practice, E-ISSN: 21...Christo Ananth
 
Intze Overhead Water Tank Design by Working Stress - IS Method.pdf
Intze Overhead Water Tank  Design by Working Stress - IS Method.pdfIntze Overhead Water Tank  Design by Working Stress - IS Method.pdf
Intze Overhead Water Tank Design by Working Stress - IS Method.pdfSuman Jyoti
 
Call for Papers - African Journal of Biological Sciences, E-ISSN: 2663-2187, ...
Call for Papers - African Journal of Biological Sciences, E-ISSN: 2663-2187, ...Call for Papers - African Journal of Biological Sciences, E-ISSN: 2663-2187, ...
Call for Papers - African Journal of Biological Sciences, E-ISSN: 2663-2187, ...Christo Ananth
 
KubeKraft presentation @CloudNativeHooghly
KubeKraft presentation @CloudNativeHooghlyKubeKraft presentation @CloudNativeHooghly
KubeKraft presentation @CloudNativeHooghlysanyuktamishra911
 
Structural Analysis and Design of Foundations: A Comprehensive Handbook for S...
Structural Analysis and Design of Foundations: A Comprehensive Handbook for S...Structural Analysis and Design of Foundations: A Comprehensive Handbook for S...
Structural Analysis and Design of Foundations: A Comprehensive Handbook for S...Dr.Costas Sachpazis
 
BSides Seattle 2024 - Stopping Ethan Hunt From Taking Your Data.pptx
BSides Seattle 2024 - Stopping Ethan Hunt From Taking Your Data.pptxBSides Seattle 2024 - Stopping Ethan Hunt From Taking Your Data.pptx
BSides Seattle 2024 - Stopping Ethan Hunt From Taking Your Data.pptxfenichawla
 
VIP Model Call Girls Kothrud ( Pune ) Call ON 8005736733 Starting From 5K to ...
VIP Model Call Girls Kothrud ( Pune ) Call ON 8005736733 Starting From 5K to ...VIP Model Call Girls Kothrud ( Pune ) Call ON 8005736733 Starting From 5K to ...
VIP Model Call Girls Kothrud ( Pune ) Call ON 8005736733 Starting From 5K to ...SUHANI PANDEY
 
The Most Attractive Pune Call Girls Manchar 8250192130 Will You Miss This Cha...
The Most Attractive Pune Call Girls Manchar 8250192130 Will You Miss This Cha...The Most Attractive Pune Call Girls Manchar 8250192130 Will You Miss This Cha...
The Most Attractive Pune Call Girls Manchar 8250192130 Will You Miss This Cha...ranjana rawat
 
PVC VS. FIBERGLASS (FRP) GRAVITY SEWER - UNI BELL
PVC VS. FIBERGLASS (FRP) GRAVITY SEWER - UNI BELLPVC VS. FIBERGLASS (FRP) GRAVITY SEWER - UNI BELL
PVC VS. FIBERGLASS (FRP) GRAVITY SEWER - UNI BELLManishPatel169454
 
Double rodded leveling 1 pdf activity 01
Double rodded leveling 1 pdf activity 01Double rodded leveling 1 pdf activity 01
Double rodded leveling 1 pdf activity 01KreezheaRecto
 
Top Rated Pune Call Girls Budhwar Peth ⟟ 6297143586 ⟟ Call Me For Genuine Se...
Top Rated  Pune Call Girls Budhwar Peth ⟟ 6297143586 ⟟ Call Me For Genuine Se...Top Rated  Pune Call Girls Budhwar Peth ⟟ 6297143586 ⟟ Call Me For Genuine Se...
Top Rated Pune Call Girls Budhwar Peth ⟟ 6297143586 ⟟ Call Me For Genuine Se...Call Girls in Nagpur High Profile
 

Recently uploaded (20)

UNIT-IFLUID PROPERTIES & FLOW CHARACTERISTICS
UNIT-IFLUID PROPERTIES & FLOW CHARACTERISTICSUNIT-IFLUID PROPERTIES & FLOW CHARACTERISTICS
UNIT-IFLUID PROPERTIES & FLOW CHARACTERISTICS
 
NFPA 5000 2024 standard .
NFPA 5000 2024 standard                                  .NFPA 5000 2024 standard                                  .
NFPA 5000 2024 standard .
 
University management System project report..pdf
University management System project report..pdfUniversity management System project report..pdf
University management System project report..pdf
 
data_management_and _data_science_cheat_sheet.pdf
data_management_and _data_science_cheat_sheet.pdfdata_management_and _data_science_cheat_sheet.pdf
data_management_and _data_science_cheat_sheet.pdf
 
AKTU Computer Networks notes --- Unit 3.pdf
AKTU Computer Networks notes ---  Unit 3.pdfAKTU Computer Networks notes ---  Unit 3.pdf
AKTU Computer Networks notes --- Unit 3.pdf
 
Online banking management system project.pdf
Online banking management system project.pdfOnline banking management system project.pdf
Online banking management system project.pdf
 
Call Girls Walvekar Nagar Call Me 7737669865 Budget Friendly No Advance Booking
Call Girls Walvekar Nagar Call Me 7737669865 Budget Friendly No Advance BookingCall Girls Walvekar Nagar Call Me 7737669865 Budget Friendly No Advance Booking
Call Girls Walvekar Nagar Call Me 7737669865 Budget Friendly No Advance Booking
 
UNIT-II FMM-Flow Through Circular Conduits
UNIT-II FMM-Flow Through Circular ConduitsUNIT-II FMM-Flow Through Circular Conduits
UNIT-II FMM-Flow Through Circular Conduits
 
Call for Papers - Educational Administration: Theory and Practice, E-ISSN: 21...
Call for Papers - Educational Administration: Theory and Practice, E-ISSN: 21...Call for Papers - Educational Administration: Theory and Practice, E-ISSN: 21...
Call for Papers - Educational Administration: Theory and Practice, E-ISSN: 21...
 
Intze Overhead Water Tank Design by Working Stress - IS Method.pdf
Intze Overhead Water Tank  Design by Working Stress - IS Method.pdfIntze Overhead Water Tank  Design by Working Stress - IS Method.pdf
Intze Overhead Water Tank Design by Working Stress - IS Method.pdf
 
Call for Papers - African Journal of Biological Sciences, E-ISSN: 2663-2187, ...
Call for Papers - African Journal of Biological Sciences, E-ISSN: 2663-2187, ...Call for Papers - African Journal of Biological Sciences, E-ISSN: 2663-2187, ...
Call for Papers - African Journal of Biological Sciences, E-ISSN: 2663-2187, ...
 
KubeKraft presentation @CloudNativeHooghly
KubeKraft presentation @CloudNativeHooghlyKubeKraft presentation @CloudNativeHooghly
KubeKraft presentation @CloudNativeHooghly
 
(INDIRA) Call Girl Aurangabad Call Now 8617697112 Aurangabad Escorts 24x7
(INDIRA) Call Girl Aurangabad Call Now 8617697112 Aurangabad Escorts 24x7(INDIRA) Call Girl Aurangabad Call Now 8617697112 Aurangabad Escorts 24x7
(INDIRA) Call Girl Aurangabad Call Now 8617697112 Aurangabad Escorts 24x7
 
Structural Analysis and Design of Foundations: A Comprehensive Handbook for S...
Structural Analysis and Design of Foundations: A Comprehensive Handbook for S...Structural Analysis and Design of Foundations: A Comprehensive Handbook for S...
Structural Analysis and Design of Foundations: A Comprehensive Handbook for S...
 
BSides Seattle 2024 - Stopping Ethan Hunt From Taking Your Data.pptx
BSides Seattle 2024 - Stopping Ethan Hunt From Taking Your Data.pptxBSides Seattle 2024 - Stopping Ethan Hunt From Taking Your Data.pptx
BSides Seattle 2024 - Stopping Ethan Hunt From Taking Your Data.pptx
 
VIP Model Call Girls Kothrud ( Pune ) Call ON 8005736733 Starting From 5K to ...
VIP Model Call Girls Kothrud ( Pune ) Call ON 8005736733 Starting From 5K to ...VIP Model Call Girls Kothrud ( Pune ) Call ON 8005736733 Starting From 5K to ...
VIP Model Call Girls Kothrud ( Pune ) Call ON 8005736733 Starting From 5K to ...
 
The Most Attractive Pune Call Girls Manchar 8250192130 Will You Miss This Cha...
The Most Attractive Pune Call Girls Manchar 8250192130 Will You Miss This Cha...The Most Attractive Pune Call Girls Manchar 8250192130 Will You Miss This Cha...
The Most Attractive Pune Call Girls Manchar 8250192130 Will You Miss This Cha...
 
PVC VS. FIBERGLASS (FRP) GRAVITY SEWER - UNI BELL
PVC VS. FIBERGLASS (FRP) GRAVITY SEWER - UNI BELLPVC VS. FIBERGLASS (FRP) GRAVITY SEWER - UNI BELL
PVC VS. FIBERGLASS (FRP) GRAVITY SEWER - UNI BELL
 
Double rodded leveling 1 pdf activity 01
Double rodded leveling 1 pdf activity 01Double rodded leveling 1 pdf activity 01
Double rodded leveling 1 pdf activity 01
 
Top Rated Pune Call Girls Budhwar Peth ⟟ 6297143586 ⟟ Call Me For Genuine Se...
Top Rated  Pune Call Girls Budhwar Peth ⟟ 6297143586 ⟟ Call Me For Genuine Se...Top Rated  Pune Call Girls Budhwar Peth ⟟ 6297143586 ⟟ Call Me For Genuine Se...
Top Rated Pune Call Girls Budhwar Peth ⟟ 6297143586 ⟟ Call Me For Genuine Se...
 

Lecture # 1.ppt

  • 1. T O P I C : L O G I C A N D C O M P O U N D S T A T E M E N T B Y : S A M E E R M U N I R L E C T U R E R , D C S N T U , F A I S A L A B D Discrete Structures
  • 2. Course Objectives sameerahmadch@gmail.com 2 1.Express statements with the precision of formal logic 2.Analyze arguments to test their validity 3.Apply the basic properties and operations related to sets 4.Apply to sets the basic properties and operations related to relations and function 5.Define terms recursively 6.Prove a formula using mathematical induction 7.Prove statements using direct and indirect methods 8.Compute probability of simple and conditional events
  • 3. Course Objectives sameerahmadch@gmail.com 3 9.Identify and use the formulas of combinatorics in different problems 10.Illustrate the basic definitions of graph theory and properties of graphs 11.Relate each major topic in Discrete Mathematics to an application area in computing
  • 4. sameerahmadch@gmail.com 4  What is Discrete Mathematics?:  Discrete Mathematics concerns processes that consist of a sequence of individual steps. Continuous Discrete
  • 5. Logic sameerahmadch@gmail.com 5 LOGIC:  Logic is the study of the principles and methods that distinguishes between a valid and an invalid argument. SIMPLE STATEMENT:  A statement is a declarative sentence that is either true or false but not both.  A statement is also referred to as a proposition Example: 2+2 = 4, It is Sunday today  If a proposition is true, we say that it has a truth value of "true”.  If a proposition is false, its truth value is "false".  The truth values “true” and “false” are, respectively, denoted by the letters T and F.
  • 6. Logic sameerahmadch@gmail.com 6  EXAMPLES :  Grass is green.  4 + 2 = 6  4 + 2 = 7  There are four fingers in a hand. are propositions
  • 7. Logic sameerahmadch@gmail.com 7  Not Propositions  Close the door.  x is greater than 2.  He is very rich are not propositions.
  • 8. Logic sameerahmadch@gmail.com 8 Rule:  If the sentence is preceded by other sentences that make the pronoun or variable reference clear, then the sentence is a Statement. Example  Bill Gates is an American  He is very rich  He is very rich is a statement with truth-value TRUE. Example  x = 1  x > 2  x > 2 is a statement with truth-value FALSE.
  • 9. Logic sameerahmadch@gmail.com 9  UNDERSTANDING STATEMENTS:  x + 2 is positive. Not a statement  May I come in? Not a statement  Logic is interesting. A statement  It is hot today. A statement  -1 > 0 A statement  x + y = 12 Not a statement
  • 10. Logic sameerahmadch@gmail.com 10 COMPOUND STATEMENT :  Simple statements could be used to build a compound statement. EXAMPLES:  1. “3 + 2 = 5” and “Lahore is a city in Pakistan”  2. “The grass is green” or “ It is hot today”  3. “Discrete Mathematics is not difficult to me”  AND, OR, NOT are called LOGICAL CONNECTIVES.
  • 11. Logic CONNECTIVE MEANING SYMBOL CALLED Negation not ~ Tilde Conjunction and  Hat Disjunction or  Vel Conditional if…then…  Arrow Biconditional if and only if  Double arrow sameerahmadch@gmail.com 11
  • 12. Logic sameerahmadch@gmail.com 12 SYMBOLIC REPRESENTATION:  Statements are symbolically represented by letters such as p, q, r,... EXAMPLES:  p = “Islamabad is the capital of Pakistan”  q = “17 is divisible by 3”
  • 13. Logic sameerahmadch@gmail.com 13 EXAMPLES:  p = “Islamabad is the capital of Pakistan”  q = “17 is divisible by 3”  p  q = “Islamabad is the capital of Pakistan and 17 is divisible by 3”  p  q = “Islamabad is the capital of Pakistan or 17 is divisible by 3”  ~p = “It is not the case that Islamabad is the capital of Pakistan” or simply “Islamabad is not the capital of Pakistan”
  • 14. Logic sameerahmadch@gmail.com 14 TRANSLATING FROM ENGLISH TO SYMBOLS:  Let p = “It is hot”, and q = “It is sunny” SENTENCE SYMBOLIC FORM 1. It is not hot. ~ p 2. It is hot and sunny. p q 3. It is hot or sunny. p  q 4. It is not hot but sunny. ~ p q 5. It is neither hot nor sunny. ~ p  ~ q
  • 15. Logic sameerahmadch@gmail.com 15 EXAMPLE: Let h = “Zia is healthy” w = “Zia is wealthy” s = “Zia is wise” Translate the compound statements to symbolic form: 1. Zia is healthy and wealthy but not wise. (h  w)  (~s) 2. Zia is not wealthy but he is healthy and wise. ~w  (h  s) 3. Zia is neither healthy, wealthy nor wise. ~h  ~w  ~s
  • 16. Logic sameerahmadch@gmail.com 16 TRANSLATING FROM SYMBOLS TO ENGLISH: Let m = “Ali is good in Mathematics” c = “Ali is a Computer Science student” Translate the following statement forms into plain English: ~ c Ali is not a Computer Science student c m Ali is a Computer Science student or good in Maths. m  ~c Ali is good in Maths but not a Computer Science student  A convenient method for analyzing a compound statement is to make a truth table for it.  A truth table specifies the truth value of a compound proposition for all possible truth values of its constituent propositions.
  • 17. Logic sameerahmadch@gmail.com 17  NEGATION (~):  If p is a statement variable, then negation of p, “not p”, is denoted as “~p”  It has opposite truth value from p i.e., if p is true, ~p is false; if p is false, ~p is true.
  • 18. Logic  TRUTH TABLE FOR ~ p p ~ p T F F T sameerahmadch@gmail.com 18
  • 19. Logic sameerahmadch@gmail.com 19  CONJUNCTION ():  If p and q are statements, then the conjunction of p and q is “p and q”, denoted as “p  q”.  It is true when, and only when, both p and q are true. If either p or q is false, or if both are false, pq is false.
  • 20. Logic  TRUTH TABLE FOR p  q p q p  q T T T T F F F T F F F F sameerahmadch@gmail.com 20
  • 21. Logic sameerahmadch@gmail.com 21  DISJUNCTION () or INCLUSIVE OR  If p & q are statements, then the disjunction of p and q is “p or q”, denoted as “p  q”.It is true when at least one of p or q is true and is false only when both p and q are false.
  • 22. Logic  TRUTH TABLE FOR p  q p q p  q T T T T F T F T T F F F sameerahmadch@gmail.com 22
  • 23. Logic sameerahmadch@gmail.com 23  Note that in the table F is only in that row where both p and q have F and all other values are T. Thus for finding out the truth values for the disjunction of two statements we will only first search out where the both statements are false and write down the F in the corresponding row in the column of p  q and in all other rows we will write T in the column of p  q.  Remark: Note that for Conjunction of two statements we find the T in both the statements, but in disjunction we find F in both the statements. In other words we will fill T first in the column of conjunction and F in the column of disjunction.
  • 24. Logic sameerahmadch@gmail.com 24  Draw Truth Tables for:  ~ p  q  ~ p  (q  ~ r)  (pq)  ~ (pq)
  • 25. Summary sameerahmadch@gmail.com 25  What is a statement?  How a compound statement is formed.  Logical connectives (negation, conjunction, disjunction).  How to construct a truth table for a statement form.