SlideShare une entreprise Scribd logo
1  sur  26
Rushdi Shams, Dept of CSE, KUET, Bangladesh 1
Knowledge Representation
Propositional Logic
Artificial Intelligence
Version 2.0
There are 10 types of people in this world- who understand binary
and who do not understand binary
Rushdi Shams, Dept of CSE, KUET, Bangladesh 2
Propositional Logic
Rushdi Shams, Dept of CSE, KUET, Bangladesh 3
Introduction
 Need formal notation to represent knowledge,
allowing automated inference and problem solving.
 One popular choice is use of logic.
 Propositional logic is the simplest.
 Symbols represent facts: P, Q, etc..
 These are joined by logical connectives (and, or,
implication) e.g., P Λ Q; Q R
 Given some statements in the logic we can deduce new
facts (e.g., from above deduce R)
Rushdi Shams, Dept of CSE, KUET, Bangladesh 4
Syntactic Properties of
Propositional Logic
 If S is a sentence, S is a sentence (negation)
 If S1 and S2 are sentences, S1 S2 is a sentence
(conjunction)
 If S1 and S2 are sentences, S1 S2 is a sentence
(disjunction)
 If S1 and S2 are sentences, S1 S2 is a sentence
(implication)
 If S1 and S2 are sentences, S1 S2 is a sentence
(bi-conditional)
Rushdi Shams, Dept of CSE, KUET, Bangladesh 5
Semantic Properties of
Propositional Logic
S is true iff S is false
S1 S2 is true iff S1 is true and S2 is true
S1 S2 is true iff S1is true or S2 is true
S1 S2 is true iff S1 is false or S2 is true
i.e., is false iff S1 is true and S2 is false
S1 S2 is true iff S1 S2 is true and
S2 S1 is true
Rushdi Shams, Dept of CSE, KUET, Bangladesh 6
Truth Table for Connectives
Rushdi Shams, Dept of CSE, KUET, Bangladesh 7
Model of a Formula
 If the value of the formula X holds 1 for the
assignment A, then the assignment A is called model
for formula X.
 That means, all assignments for which the formula X
is true are models of it.
Rushdi Shams, Dept of CSE, KUET, Bangladesh 8
Model of a Formula
Rushdi Shams, Dept of CSE, KUET, Bangladesh 9
Model of a Formula:
Can you do it?
Rushdi Shams, Dept of CSE, KUET, Bangladesh 10
Satisfiable Formulas
 If there exist at least one model of a formula then the
formula is called satisfiable.
 The value of the formula is true for at least one
assignment. It plays no rule how many models the
formula has.
Rushdi Shams, Dept of CSE, KUET, Bangladesh 11
Satisfiable Formulas
Rushdi Shams, Dept of CSE, KUET, Bangladesh 12
Valid Formulas
 A formula is called valid (or tautology) if all
assignments are models of this formula.
 The value of the formula is true for all assignments. If
a tautology is part of a more complex formula then
you could replace it by the value 1.
Rushdi Shams, Dept of CSE, KUET, Bangladesh 13
Valid Formulas
Rushdi Shams, Dept of CSE, KUET, Bangladesh 14
Unsatisfiable Formulas
 A formula is unsatisfiable if none of its
assignment is true in no models
Rushdi Shams, Dept of CSE, KUET, Bangladesh 15
Logical equivalence
 Two sentences are logically equivalent iff true in same models: α ≡ ß
iff α╞ β and β╞ α
Rushdi Shams, Dept of CSE, KUET, Bangladesh 16
Deduction: Rule of Inference
1. Either cat fur was found at the scene of the crime, or dog fur was
found at the scene of the crime. (Premise)
 C v D
Rushdi Shams, Dept of CSE, KUET, Bangladesh 17
Deduction: Rule of Inference
2. If dog fur was found at the scene of the crime, then officer
Thompson had an allergy attack. (Premise)
 D → A
Rushdi Shams, Dept of CSE, KUET, Bangladesh 18
Deduction: Rule of Inference
3. If cat fur was found at the scene of the crime, then Macavity is
responsible for the crime. (Premise)
 C → M
Rushdi Shams, Dept of CSE, KUET, Bangladesh 19
Deduction: Rule of Inference
4. Officer Thompson did not have an allergy attack. (Premise)
 ¬ A
Rushdi Shams, Dept of CSE, KUET, Bangladesh 20
Deduction: Rule of Inference
5. Dog fur was not found at the scene of the crime. (Follows from 2
D → A and 4. ¬ A). When is ¬ A true? When A is false- right?
Now, take a look at the implication truth table. Find what is the
value of D when A is false and D → A is true
 ¬ D
Rushdi Shams, Dept of CSE, KUET, Bangladesh 21
Rules for Inference:
Modus Tollens
 If given α → β
and we know ¬β
Then ¬α
Rushdi Shams, Dept of CSE, KUET, Bangladesh 22
Deduction: Rule of Inference
6. Cat fur was found at the scene of the crime. (Follows from 1
C v D and 5 ¬ D). When is ¬ D true? When D is false- right?
Now, take a look at the OR truth table. Find what is the value of
C when D is false and C V D is true
 C
Rushdi Shams, Dept of CSE, KUET, Bangladesh 23
Rules for Inference:
Disjunctive Syllogism
 If given α v β
and we know ¬α
then β
 If given α v β
and we know ¬β
then α
Rushdi Shams, Dept of CSE, KUET, Bangladesh 24
Deduction: Rule of Inference
7. Macavity is responsible for the crime. (Conclusion. Follows from
3 C → M and 6 C). When is C → M true given that C is true?
Take a look at the Implication truth table.
 M
Rushdi Shams, Dept of CSE, KUET, Bangladesh 25
Rules for Inference:
Modus Ponens
 If given α → β
and we know α
Then β
Rushdi Shams, Dept of CSE, KUET, Bangladesh 26
References
 Artificial Intelligence: A Modern Approach (2nd
Edition)
by Russell and Norvig
Chapter 7
 http://www.iep.utm.edu/p/prop-log.htm#H5

Contenu connexe

Tendances

knowledge representation using rules
knowledge representation using rulesknowledge representation using rules
knowledge representation using rulesHarini Balamurugan
 
Artificial intelligence and knowledge representation
Artificial intelligence and knowledge representationArtificial intelligence and knowledge representation
Artificial intelligence and knowledge representationSajan Sahu
 
Knowledge representation in AI
Knowledge representation in AIKnowledge representation in AI
Knowledge representation in AIVishal Singh
 
Knowledge representation and reasoning
Knowledge representation and reasoningKnowledge representation and reasoning
Knowledge representation and reasoningMaryam Maleki
 
I. AO* SEARCH ALGORITHM
I. AO* SEARCH ALGORITHMI. AO* SEARCH ALGORITHM
I. AO* SEARCH ALGORITHMvikas dhakane
 
Control Strategies in AI
Control Strategies in AI Control Strategies in AI
Control Strategies in AI Bharat Bhushan
 
Control Strategies in AI
Control Strategies in AIControl Strategies in AI
Control Strategies in AIAmey Kerkar
 
Knowledge Representation in Artificial intelligence
Knowledge Representation in Artificial intelligence Knowledge Representation in Artificial intelligence
Knowledge Representation in Artificial intelligence Yasir Khan
 
L03 ai - knowledge representation using logic
L03 ai - knowledge representation using logicL03 ai - knowledge representation using logic
L03 ai - knowledge representation using logicManjula V
 
Inference in First-Order Logic
Inference in First-Order Logic Inference in First-Order Logic
Inference in First-Order Logic Junya Tanaka
 

Tendances (20)

Uncertainty in AI
Uncertainty in AIUncertainty in AI
Uncertainty in AI
 
knowledge representation using rules
knowledge representation using rulesknowledge representation using rules
knowledge representation using rules
 
AI Lecture 7 (uncertainty)
AI Lecture 7 (uncertainty)AI Lecture 7 (uncertainty)
AI Lecture 7 (uncertainty)
 
Artificial intelligence and knowledge representation
Artificial intelligence and knowledge representationArtificial intelligence and knowledge representation
Artificial intelligence and knowledge representation
 
First order logic
First order logicFirst order logic
First order logic
 
Knowledge representation in AI
Knowledge representation in AIKnowledge representation in AI
Knowledge representation in AI
 
Knowledge representation and reasoning
Knowledge representation and reasoningKnowledge representation and reasoning
Knowledge representation and reasoning
 
AI: Logic in AI
AI: Logic in AIAI: Logic in AI
AI: Logic in AI
 
Rule Based System
Rule Based SystemRule Based System
Rule Based System
 
I. AO* SEARCH ALGORITHM
I. AO* SEARCH ALGORITHMI. AO* SEARCH ALGORITHM
I. AO* SEARCH ALGORITHM
 
AI: Planning and AI
AI: Planning and AIAI: Planning and AI
AI: Planning and AI
 
First order logic
First order logicFirst order logic
First order logic
 
Control Strategies in AI
Control Strategies in AI Control Strategies in AI
Control Strategies in AI
 
Control Strategies in AI
Control Strategies in AIControl Strategies in AI
Control Strategies in AI
 
Knowledge Representation in Artificial intelligence
Knowledge Representation in Artificial intelligence Knowledge Representation in Artificial intelligence
Knowledge Representation in Artificial intelligence
 
Predicate logic
 Predicate logic Predicate logic
Predicate logic
 
L03 ai - knowledge representation using logic
L03 ai - knowledge representation using logicL03 ai - knowledge representation using logic
L03 ai - knowledge representation using logic
 
Dempster shafer theory
Dempster shafer theoryDempster shafer theory
Dempster shafer theory
 
Reasoning in AI
Reasoning in AIReasoning in AI
Reasoning in AI
 
Inference in First-Order Logic
Inference in First-Order Logic Inference in First-Order Logic
Inference in First-Order Logic
 

En vedette

Propositional logic & inference
Propositional logic & inferencePropositional logic & inference
Propositional logic & inferenceSlideshare
 
Syntax and semantics of propositional logic
Syntax and semantics of propositional logicSyntax and semantics of propositional logic
Syntax and semantics of propositional logicJanet Stemwedel
 
Propositional logic sneha-mam
Propositional logic sneha-mam Propositional logic sneha-mam
Propositional logic sneha-mam nitesh9353
 
Propositional And First-Order Logic
Propositional And First-Order LogicPropositional And First-Order Logic
Propositional And First-Order Logicankush_kumar
 
Logic (slides)
Logic (slides)Logic (slides)
Logic (slides)IIUM
 
Predicate Logic
Predicate LogicPredicate Logic
Predicate Logicgiki67
 
03 - Predicate logic
03 - Predicate logic03 - Predicate logic
03 - Predicate logicTudor Girba
 
Propositional logic for Beginners
Propositional logic for BeginnersPropositional logic for Beginners
Propositional logic for Beginnerskianryan
 
#3 formal methods – propositional logic
#3 formal methods – propositional logic#3 formal methods – propositional logic
#3 formal methods – propositional logicSharif Omar Salem
 
L1 l2 l3 introduction to machine translation
L1 l2 l3  introduction to machine translationL1 l2 l3  introduction to machine translation
L1 l2 l3 introduction to machine translationRushdi Shams
 
Probabilistic logic
Probabilistic logicProbabilistic logic
Probabilistic logicRushdi Shams
 
L13 why software fails
L13  why software failsL13  why software fails
L13 why software failsRushdi Shams
 
Knowledge representation
Knowledge representationKnowledge representation
Knowledge representationRushdi Shams
 
Lecture 5, 6 and 7 cpu scheduling
Lecture 5, 6 and 7  cpu schedulingLecture 5, 6 and 7  cpu scheduling
Lecture 5, 6 and 7 cpu schedulingRushdi Shams
 

En vedette (20)

Propositional logic & inference
Propositional logic & inferencePropositional logic & inference
Propositional logic & inference
 
Syntax and semantics of propositional logic
Syntax and semantics of propositional logicSyntax and semantics of propositional logic
Syntax and semantics of propositional logic
 
Propositional logic
Propositional logicPropositional logic
Propositional logic
 
Propositional logic sneha-mam
Propositional logic sneha-mam Propositional logic sneha-mam
Propositional logic sneha-mam
 
Propositional And First-Order Logic
Propositional And First-Order LogicPropositional And First-Order Logic
Propositional And First-Order Logic
 
Logic (slides)
Logic (slides)Logic (slides)
Logic (slides)
 
Predicate Logic
Predicate LogicPredicate Logic
Predicate Logic
 
03 - Predicate logic
03 - Predicate logic03 - Predicate logic
03 - Predicate logic
 
Propositional logic for Beginners
Propositional logic for BeginnersPropositional logic for Beginners
Propositional logic for Beginners
 
Propositional logic
Propositional logicPropositional logic
Propositional logic
 
Logic part1
Logic part1Logic part1
Logic part1
 
#3 formal methods – propositional logic
#3 formal methods – propositional logic#3 formal methods – propositional logic
#3 formal methods – propositional logic
 
L1 l2 l3 introduction to machine translation
L1 l2 l3  introduction to machine translationL1 l2 l3  introduction to machine translation
L1 l2 l3 introduction to machine translation
 
Probabilistic logic
Probabilistic logicProbabilistic logic
Probabilistic logic
 
L13 why software fails
L13  why software failsL13  why software fails
L13 why software fails
 
L15 fuzzy logic
L15  fuzzy logicL15  fuzzy logic
L15 fuzzy logic
 
Knowledge representation
Knowledge representationKnowledge representation
Knowledge representation
 
Propositional logic
Propositional logicPropositional logic
Propositional logic
 
Lecture 5, 6 and 7 cpu scheduling
Lecture 5, 6 and 7  cpu schedulingLecture 5, 6 and 7  cpu scheduling
Lecture 5, 6 and 7 cpu scheduling
 
Hum 200 w7
Hum 200 w7 Hum 200 w7
Hum 200 w7
 

Plus de Rushdi Shams

Research Methodology and Tips on Better Research
Research Methodology and Tips on Better ResearchResearch Methodology and Tips on Better Research
Research Methodology and Tips on Better ResearchRushdi Shams
 
Common evaluation measures in NLP and IR
Common evaluation measures in NLP and IRCommon evaluation measures in NLP and IR
Common evaluation measures in NLP and IRRushdi Shams
 
Machine learning with nlp 101
Machine learning with nlp 101Machine learning with nlp 101
Machine learning with nlp 101Rushdi Shams
 
Semi-supervised classification for natural language processing
Semi-supervised classification for natural language processingSemi-supervised classification for natural language processing
Semi-supervised classification for natural language processingRushdi Shams
 
Natural Language Processing: Parsing
Natural Language Processing: ParsingNatural Language Processing: Parsing
Natural Language Processing: ParsingRushdi Shams
 
Types of machine translation
Types of machine translationTypes of machine translation
Types of machine translationRushdi Shams
 
Syntax and semantics
Syntax and semanticsSyntax and semantics
Syntax and semanticsRushdi Shams
 
Knowledge structure
Knowledge structureKnowledge structure
Knowledge structureRushdi Shams
 
L5 understanding hacking
L5  understanding hackingL5  understanding hacking
L5 understanding hackingRushdi Shams
 
L2 Intrusion Detection System (IDS)
L2  Intrusion Detection System (IDS)L2  Intrusion Detection System (IDS)
L2 Intrusion Detection System (IDS)Rushdi Shams
 
L2 l3 l4 software process models
L2 l3 l4  software process modelsL2 l3 l4  software process models
L2 l3 l4 software process modelsRushdi Shams
 
L1 overview of software engineering
L1  overview of software engineeringL1  overview of software engineering
L1 overview of software engineeringRushdi Shams
 
Lecture 14,15 and 16 file systems
Lecture 14,15 and 16  file systemsLecture 14,15 and 16  file systems
Lecture 14,15 and 16 file systemsRushdi Shams
 
Lecture 11,12 and 13 deadlocks
Lecture 11,12 and 13  deadlocksLecture 11,12 and 13  deadlocks
Lecture 11,12 and 13 deadlocksRushdi Shams
 
Lecture 7, 8, 9 and 10 Inter Process Communication (IPC) in Operating Systems
Lecture 7, 8, 9 and 10  Inter Process Communication (IPC) in Operating SystemsLecture 7, 8, 9 and 10  Inter Process Communication (IPC) in Operating Systems
Lecture 7, 8, 9 and 10 Inter Process Communication (IPC) in Operating SystemsRushdi Shams
 
Lecture 1 and 2 processes
Lecture 1 and 2  processesLecture 1 and 2  processes
Lecture 1 and 2 processesRushdi Shams
 

Plus de Rushdi Shams (20)

Research Methodology and Tips on Better Research
Research Methodology and Tips on Better ResearchResearch Methodology and Tips on Better Research
Research Methodology and Tips on Better Research
 
Common evaluation measures in NLP and IR
Common evaluation measures in NLP and IRCommon evaluation measures in NLP and IR
Common evaluation measures in NLP and IR
 
Machine learning with nlp 101
Machine learning with nlp 101Machine learning with nlp 101
Machine learning with nlp 101
 
Semi-supervised classification for natural language processing
Semi-supervised classification for natural language processingSemi-supervised classification for natural language processing
Semi-supervised classification for natural language processing
 
Natural Language Processing: Parsing
Natural Language Processing: ParsingNatural Language Processing: Parsing
Natural Language Processing: Parsing
 
Types of machine translation
Types of machine translationTypes of machine translation
Types of machine translation
 
Syntax and semantics
Syntax and semanticsSyntax and semantics
Syntax and semantics
 
Knowledge structure
Knowledge structureKnowledge structure
Knowledge structure
 
Belief function
Belief functionBelief function
Belief function
 
L5 understanding hacking
L5  understanding hackingL5  understanding hacking
L5 understanding hacking
 
L4 vpn
L4  vpnL4  vpn
L4 vpn
 
L3 defense
L3  defenseL3  defense
L3 defense
 
L2 Intrusion Detection System (IDS)
L2  Intrusion Detection System (IDS)L2  Intrusion Detection System (IDS)
L2 Intrusion Detection System (IDS)
 
L1 phishing
L1  phishingL1  phishing
L1 phishing
 
L2 l3 l4 software process models
L2 l3 l4  software process modelsL2 l3 l4  software process models
L2 l3 l4 software process models
 
L1 overview of software engineering
L1  overview of software engineeringL1  overview of software engineering
L1 overview of software engineering
 
Lecture 14,15 and 16 file systems
Lecture 14,15 and 16  file systemsLecture 14,15 and 16  file systems
Lecture 14,15 and 16 file systems
 
Lecture 11,12 and 13 deadlocks
Lecture 11,12 and 13  deadlocksLecture 11,12 and 13  deadlocks
Lecture 11,12 and 13 deadlocks
 
Lecture 7, 8, 9 and 10 Inter Process Communication (IPC) in Operating Systems
Lecture 7, 8, 9 and 10  Inter Process Communication (IPC) in Operating SystemsLecture 7, 8, 9 and 10  Inter Process Communication (IPC) in Operating Systems
Lecture 7, 8, 9 and 10 Inter Process Communication (IPC) in Operating Systems
 
Lecture 1 and 2 processes
Lecture 1 and 2  processesLecture 1 and 2  processes
Lecture 1 and 2 processes
 

Dernier

Introduction to ArtificiaI Intelligence in Higher Education
Introduction to ArtificiaI Intelligence in Higher EducationIntroduction to ArtificiaI Intelligence in Higher Education
Introduction to ArtificiaI Intelligence in Higher Educationpboyjonauth
 
microwave assisted reaction. General introduction
microwave assisted reaction. General introductionmicrowave assisted reaction. General introduction
microwave assisted reaction. General introductionMaksud Ahmed
 
Measures of Central Tendency: Mean, Median and Mode
Measures of Central Tendency: Mean, Median and ModeMeasures of Central Tendency: Mean, Median and Mode
Measures of Central Tendency: Mean, Median and ModeThiyagu K
 
Mastering the Unannounced Regulatory Inspection
Mastering the Unannounced Regulatory InspectionMastering the Unannounced Regulatory Inspection
Mastering the Unannounced Regulatory InspectionSafetyChain Software
 
Arihant handbook biology for class 11 .pdf
Arihant handbook biology for class 11 .pdfArihant handbook biology for class 11 .pdf
Arihant handbook biology for class 11 .pdfchloefrazer622
 
Hybridoma Technology ( Production , Purification , and Application )
Hybridoma Technology  ( Production , Purification , and Application  ) Hybridoma Technology  ( Production , Purification , and Application  )
Hybridoma Technology ( Production , Purification , and Application ) Sakshi Ghasle
 
“Oh GOSH! Reflecting on Hackteria's Collaborative Practices in a Global Do-It...
“Oh GOSH! Reflecting on Hackteria's Collaborative Practices in a Global Do-It...“Oh GOSH! Reflecting on Hackteria's Collaborative Practices in a Global Do-It...
“Oh GOSH! Reflecting on Hackteria's Collaborative Practices in a Global Do-It...Marc Dusseiller Dusjagr
 
_Math 4-Q4 Week 5.pptx Steps in Collecting Data
_Math 4-Q4 Week 5.pptx Steps in Collecting Data_Math 4-Q4 Week 5.pptx Steps in Collecting Data
_Math 4-Q4 Week 5.pptx Steps in Collecting DataJhengPantaleon
 
BASLIQ CURRENT LOOKBOOK LOOKBOOK(1) (1).pdf
BASLIQ CURRENT LOOKBOOK  LOOKBOOK(1) (1).pdfBASLIQ CURRENT LOOKBOOK  LOOKBOOK(1) (1).pdf
BASLIQ CURRENT LOOKBOOK LOOKBOOK(1) (1).pdfSoniaTolstoy
 
POINT- BIOCHEMISTRY SEM 2 ENZYMES UNIT 5.pptx
POINT- BIOCHEMISTRY SEM 2 ENZYMES UNIT 5.pptxPOINT- BIOCHEMISTRY SEM 2 ENZYMES UNIT 5.pptx
POINT- BIOCHEMISTRY SEM 2 ENZYMES UNIT 5.pptxSayali Powar
 
Call Girls in Dwarka Mor Delhi Contact Us 9654467111
Call Girls in Dwarka Mor Delhi Contact Us 9654467111Call Girls in Dwarka Mor Delhi Contact Us 9654467111
Call Girls in Dwarka Mor Delhi Contact Us 9654467111Sapana Sha
 
CARE OF CHILD IN INCUBATOR..........pptx
CARE OF CHILD IN INCUBATOR..........pptxCARE OF CHILD IN INCUBATOR..........pptx
CARE OF CHILD IN INCUBATOR..........pptxGaneshChakor2
 
Software Engineering Methodologies (overview)
Software Engineering Methodologies (overview)Software Engineering Methodologies (overview)
Software Engineering Methodologies (overview)eniolaolutunde
 
Grant Readiness 101 TechSoup and Remy Consulting
Grant Readiness 101 TechSoup and Remy ConsultingGrant Readiness 101 TechSoup and Remy Consulting
Grant Readiness 101 TechSoup and Remy ConsultingTechSoup
 
Q4-W6-Restating Informational Text Grade 3
Q4-W6-Restating Informational Text Grade 3Q4-W6-Restating Informational Text Grade 3
Q4-W6-Restating Informational Text Grade 3JemimahLaneBuaron
 
Organic Name Reactions for the students and aspirants of Chemistry12th.pptx
Organic Name Reactions  for the students and aspirants of Chemistry12th.pptxOrganic Name Reactions  for the students and aspirants of Chemistry12th.pptx
Organic Name Reactions for the students and aspirants of Chemistry12th.pptxVS Mahajan Coaching Centre
 
The basics of sentences session 2pptx copy.pptx
The basics of sentences session 2pptx copy.pptxThe basics of sentences session 2pptx copy.pptx
The basics of sentences session 2pptx copy.pptxheathfieldcps1
 
Concept of Vouching. B.Com(Hons) /B.Compdf
Concept of Vouching. B.Com(Hons) /B.CompdfConcept of Vouching. B.Com(Hons) /B.Compdf
Concept of Vouching. B.Com(Hons) /B.CompdfUmakantAnnand
 
Industrial Policy - 1948, 1956, 1973, 1977, 1980, 1991
Industrial Policy - 1948, 1956, 1973, 1977, 1980, 1991Industrial Policy - 1948, 1956, 1973, 1977, 1980, 1991
Industrial Policy - 1948, 1956, 1973, 1977, 1980, 1991RKavithamani
 

Dernier (20)

Introduction to ArtificiaI Intelligence in Higher Education
Introduction to ArtificiaI Intelligence in Higher EducationIntroduction to ArtificiaI Intelligence in Higher Education
Introduction to ArtificiaI Intelligence in Higher Education
 
microwave assisted reaction. General introduction
microwave assisted reaction. General introductionmicrowave assisted reaction. General introduction
microwave assisted reaction. General introduction
 
Measures of Central Tendency: Mean, Median and Mode
Measures of Central Tendency: Mean, Median and ModeMeasures of Central Tendency: Mean, Median and Mode
Measures of Central Tendency: Mean, Median and Mode
 
Mastering the Unannounced Regulatory Inspection
Mastering the Unannounced Regulatory InspectionMastering the Unannounced Regulatory Inspection
Mastering the Unannounced Regulatory Inspection
 
Arihant handbook biology for class 11 .pdf
Arihant handbook biology for class 11 .pdfArihant handbook biology for class 11 .pdf
Arihant handbook biology for class 11 .pdf
 
Hybridoma Technology ( Production , Purification , and Application )
Hybridoma Technology  ( Production , Purification , and Application  ) Hybridoma Technology  ( Production , Purification , and Application  )
Hybridoma Technology ( Production , Purification , and Application )
 
“Oh GOSH! Reflecting on Hackteria's Collaborative Practices in a Global Do-It...
“Oh GOSH! Reflecting on Hackteria's Collaborative Practices in a Global Do-It...“Oh GOSH! Reflecting on Hackteria's Collaborative Practices in a Global Do-It...
“Oh GOSH! Reflecting on Hackteria's Collaborative Practices in a Global Do-It...
 
_Math 4-Q4 Week 5.pptx Steps in Collecting Data
_Math 4-Q4 Week 5.pptx Steps in Collecting Data_Math 4-Q4 Week 5.pptx Steps in Collecting Data
_Math 4-Q4 Week 5.pptx Steps in Collecting Data
 
BASLIQ CURRENT LOOKBOOK LOOKBOOK(1) (1).pdf
BASLIQ CURRENT LOOKBOOK  LOOKBOOK(1) (1).pdfBASLIQ CURRENT LOOKBOOK  LOOKBOOK(1) (1).pdf
BASLIQ CURRENT LOOKBOOK LOOKBOOK(1) (1).pdf
 
TataKelola dan KamSiber Kecerdasan Buatan v022.pdf
TataKelola dan KamSiber Kecerdasan Buatan v022.pdfTataKelola dan KamSiber Kecerdasan Buatan v022.pdf
TataKelola dan KamSiber Kecerdasan Buatan v022.pdf
 
POINT- BIOCHEMISTRY SEM 2 ENZYMES UNIT 5.pptx
POINT- BIOCHEMISTRY SEM 2 ENZYMES UNIT 5.pptxPOINT- BIOCHEMISTRY SEM 2 ENZYMES UNIT 5.pptx
POINT- BIOCHEMISTRY SEM 2 ENZYMES UNIT 5.pptx
 
Call Girls in Dwarka Mor Delhi Contact Us 9654467111
Call Girls in Dwarka Mor Delhi Contact Us 9654467111Call Girls in Dwarka Mor Delhi Contact Us 9654467111
Call Girls in Dwarka Mor Delhi Contact Us 9654467111
 
CARE OF CHILD IN INCUBATOR..........pptx
CARE OF CHILD IN INCUBATOR..........pptxCARE OF CHILD IN INCUBATOR..........pptx
CARE OF CHILD IN INCUBATOR..........pptx
 
Software Engineering Methodologies (overview)
Software Engineering Methodologies (overview)Software Engineering Methodologies (overview)
Software Engineering Methodologies (overview)
 
Grant Readiness 101 TechSoup and Remy Consulting
Grant Readiness 101 TechSoup and Remy ConsultingGrant Readiness 101 TechSoup and Remy Consulting
Grant Readiness 101 TechSoup and Remy Consulting
 
Q4-W6-Restating Informational Text Grade 3
Q4-W6-Restating Informational Text Grade 3Q4-W6-Restating Informational Text Grade 3
Q4-W6-Restating Informational Text Grade 3
 
Organic Name Reactions for the students and aspirants of Chemistry12th.pptx
Organic Name Reactions  for the students and aspirants of Chemistry12th.pptxOrganic Name Reactions  for the students and aspirants of Chemistry12th.pptx
Organic Name Reactions for the students and aspirants of Chemistry12th.pptx
 
The basics of sentences session 2pptx copy.pptx
The basics of sentences session 2pptx copy.pptxThe basics of sentences session 2pptx copy.pptx
The basics of sentences session 2pptx copy.pptx
 
Concept of Vouching. B.Com(Hons) /B.Compdf
Concept of Vouching. B.Com(Hons) /B.CompdfConcept of Vouching. B.Com(Hons) /B.Compdf
Concept of Vouching. B.Com(Hons) /B.Compdf
 
Industrial Policy - 1948, 1956, 1973, 1977, 1980, 1991
Industrial Policy - 1948, 1956, 1973, 1977, 1980, 1991Industrial Policy - 1948, 1956, 1973, 1977, 1980, 1991
Industrial Policy - 1948, 1956, 1973, 1977, 1980, 1991
 

Propositional logic

  • 1. Rushdi Shams, Dept of CSE, KUET, Bangladesh 1 Knowledge Representation Propositional Logic Artificial Intelligence Version 2.0 There are 10 types of people in this world- who understand binary and who do not understand binary
  • 2. Rushdi Shams, Dept of CSE, KUET, Bangladesh 2 Propositional Logic
  • 3. Rushdi Shams, Dept of CSE, KUET, Bangladesh 3 Introduction  Need formal notation to represent knowledge, allowing automated inference and problem solving.  One popular choice is use of logic.  Propositional logic is the simplest.  Symbols represent facts: P, Q, etc..  These are joined by logical connectives (and, or, implication) e.g., P Λ Q; Q R  Given some statements in the logic we can deduce new facts (e.g., from above deduce R)
  • 4. Rushdi Shams, Dept of CSE, KUET, Bangladesh 4 Syntactic Properties of Propositional Logic  If S is a sentence, S is a sentence (negation)  If S1 and S2 are sentences, S1 S2 is a sentence (conjunction)  If S1 and S2 are sentences, S1 S2 is a sentence (disjunction)  If S1 and S2 are sentences, S1 S2 is a sentence (implication)  If S1 and S2 are sentences, S1 S2 is a sentence (bi-conditional)
  • 5. Rushdi Shams, Dept of CSE, KUET, Bangladesh 5 Semantic Properties of Propositional Logic S is true iff S is false S1 S2 is true iff S1 is true and S2 is true S1 S2 is true iff S1is true or S2 is true S1 S2 is true iff S1 is false or S2 is true i.e., is false iff S1 is true and S2 is false S1 S2 is true iff S1 S2 is true and S2 S1 is true
  • 6. Rushdi Shams, Dept of CSE, KUET, Bangladesh 6 Truth Table for Connectives
  • 7. Rushdi Shams, Dept of CSE, KUET, Bangladesh 7 Model of a Formula  If the value of the formula X holds 1 for the assignment A, then the assignment A is called model for formula X.  That means, all assignments for which the formula X is true are models of it.
  • 8. Rushdi Shams, Dept of CSE, KUET, Bangladesh 8 Model of a Formula
  • 9. Rushdi Shams, Dept of CSE, KUET, Bangladesh 9 Model of a Formula: Can you do it?
  • 10. Rushdi Shams, Dept of CSE, KUET, Bangladesh 10 Satisfiable Formulas  If there exist at least one model of a formula then the formula is called satisfiable.  The value of the formula is true for at least one assignment. It plays no rule how many models the formula has.
  • 11. Rushdi Shams, Dept of CSE, KUET, Bangladesh 11 Satisfiable Formulas
  • 12. Rushdi Shams, Dept of CSE, KUET, Bangladesh 12 Valid Formulas  A formula is called valid (or tautology) if all assignments are models of this formula.  The value of the formula is true for all assignments. If a tautology is part of a more complex formula then you could replace it by the value 1.
  • 13. Rushdi Shams, Dept of CSE, KUET, Bangladesh 13 Valid Formulas
  • 14. Rushdi Shams, Dept of CSE, KUET, Bangladesh 14 Unsatisfiable Formulas  A formula is unsatisfiable if none of its assignment is true in no models
  • 15. Rushdi Shams, Dept of CSE, KUET, Bangladesh 15 Logical equivalence  Two sentences are logically equivalent iff true in same models: α ≡ ß iff α╞ β and β╞ α
  • 16. Rushdi Shams, Dept of CSE, KUET, Bangladesh 16 Deduction: Rule of Inference 1. Either cat fur was found at the scene of the crime, or dog fur was found at the scene of the crime. (Premise)  C v D
  • 17. Rushdi Shams, Dept of CSE, KUET, Bangladesh 17 Deduction: Rule of Inference 2. If dog fur was found at the scene of the crime, then officer Thompson had an allergy attack. (Premise)  D → A
  • 18. Rushdi Shams, Dept of CSE, KUET, Bangladesh 18 Deduction: Rule of Inference 3. If cat fur was found at the scene of the crime, then Macavity is responsible for the crime. (Premise)  C → M
  • 19. Rushdi Shams, Dept of CSE, KUET, Bangladesh 19 Deduction: Rule of Inference 4. Officer Thompson did not have an allergy attack. (Premise)  ¬ A
  • 20. Rushdi Shams, Dept of CSE, KUET, Bangladesh 20 Deduction: Rule of Inference 5. Dog fur was not found at the scene of the crime. (Follows from 2 D → A and 4. ¬ A). When is ¬ A true? When A is false- right? Now, take a look at the implication truth table. Find what is the value of D when A is false and D → A is true  ¬ D
  • 21. Rushdi Shams, Dept of CSE, KUET, Bangladesh 21 Rules for Inference: Modus Tollens  If given α → β and we know ¬β Then ¬α
  • 22. Rushdi Shams, Dept of CSE, KUET, Bangladesh 22 Deduction: Rule of Inference 6. Cat fur was found at the scene of the crime. (Follows from 1 C v D and 5 ¬ D). When is ¬ D true? When D is false- right? Now, take a look at the OR truth table. Find what is the value of C when D is false and C V D is true  C
  • 23. Rushdi Shams, Dept of CSE, KUET, Bangladesh 23 Rules for Inference: Disjunctive Syllogism  If given α v β and we know ¬α then β  If given α v β and we know ¬β then α
  • 24. Rushdi Shams, Dept of CSE, KUET, Bangladesh 24 Deduction: Rule of Inference 7. Macavity is responsible for the crime. (Conclusion. Follows from 3 C → M and 6 C). When is C → M true given that C is true? Take a look at the Implication truth table.  M
  • 25. Rushdi Shams, Dept of CSE, KUET, Bangladesh 25 Rules for Inference: Modus Ponens  If given α → β and we know α Then β
  • 26. Rushdi Shams, Dept of CSE, KUET, Bangladesh 26 References  Artificial Intelligence: A Modern Approach (2nd Edition) by Russell and Norvig Chapter 7  http://www.iep.utm.edu/p/prop-log.htm#H5