SlideShare a Scribd company logo
B. Sc. CSIT 5th Semester
By Bal Krishna Subedi1
Home Works for Logic
Propositional Logic
1. 7.4, 7.5, 7.7, 7.8 & 7.12 from Textbook (R&N)
2. The logical operator  is read “if and only if”. P Q is defined as being
equivalent to (P Q) ^ (Q  P). Based on this definition, show that (P Q) is
logically equivalent to (P  Q)  (Q ^ P).
a. By using truth table.
b. By a series of substitutions (use identities on page on Page 210)
3. Consider the knowledge base:
If it is raining out then Ann puts the top up on her convertible. Ann did not put
the top up on her convertible.
(a) Describe a set of propositional letters which can be used to represent the
knowledge base.
(b) Translate the KB into propositional logic using your propositional letters from
part a.
(c) Is it raining? Answer this question by using logical inference rules with the KB.
Predicate Logic
1. 8.2, 8.3, 8.4, 8.6, 8.7 & 8.9.
2. 9.2, 9.4, 9.9, 9.10, 9.11, 9.17, 9.18 & 9.19
3. Consider the following sentence in FOL:
3. Attempt to unify the following pair of expressions. Either show their most general
unifiers or explain why they will not unify.
a. P(X, Y) and p(a, Z)
b. p(X, X) and p(a, b)
B. Sc. CSIT 5th Semester
By Bal Krishna Subedi2
c. ancestor(X,Y) and ancestor (bill, father(bill))
d. ancestor (X, father(X)) and ancestor(david, george)
e. q(X) and q(a)
4. The following story is from N. Wirth’s (1976)
I married a widow (let’s call her W) who has a grown-up daughter (call her D).
My father (F), who visited us quite often, fell in love with my step daughter and
married her. Hence my father becomes my son-in-law and my step-daughter
becomes my mother. Some months later, my wife gave birth to a son (S1), who
becomes the brother-in-law of my father, as well as my uncle. The wife of my
father, that is, my step-daughter, also had a son (S2).
Using the predicate logic, create a set of expressions that represent the situation in
the above story. Add expressions defining basic family relationships such as the
definition of father-in-low and use modus ponen on this system to prove the
conclusion that “I am my own grandfather”.

More Related Content

More from Tribhuvan University

Lecture 4 m&ca
Lecture 4 m&caLecture 4 m&ca
Lecture 4 m&ca
Tribhuvan University
 
Lecture 3 m&ca
Lecture 3 m&caLecture 3 m&ca
Lecture 3 m&ca
Tribhuvan University
 
Lecture 2 m&ca
Lecture 2 m&caLecture 2 m&ca
Lecture 2 m&ca
Tribhuvan University
 
Lecture 1 m&ca
Lecture 1 m&caLecture 1 m&ca
Lecture 1 m&ca
Tribhuvan University
 
Neural network (csc372) lecture 2
Neural network (csc372) lecture 2Neural network (csc372) lecture 2
Neural network (csc372) lecture 2
Tribhuvan University
 
Neural network (csc372) lecture 1
Neural network (csc372) lecture 1Neural network (csc372) lecture 1
Neural network (csc372) lecture 1
Tribhuvan University
 
Ai unit-2
Ai unit-2Ai unit-2
Ai unit-3
Ai unit-3Ai unit-3
Ai unit-4
Ai unit-4Ai unit-4
Unit 4(nlp _neural_network)
Unit 4(nlp _neural_network)Unit 4(nlp _neural_network)
Unit 4(nlp _neural_network)
Tribhuvan University
 
Ai unit-6
Ai unit-6Ai unit-6
Ai unit-1
Ai unit-1Ai unit-1
Knowldge reprsentations
Knowldge reprsentationsKnowldge reprsentations
Knowldge reprsentations
Tribhuvan University
 
Search 1
Search 1Search 1
Ai introduction
Ai introductionAi introduction
Ai introduction
Tribhuvan University
 
Assignment 1
Assignment 1Assignment 1
Assignment 1
Tribhuvan University
 
Logic 2
Logic 2Logic 2
Artificial Intelligence Note
Artificial Intelligence NoteArtificial Intelligence Note
Artificial Intelligence Note
Tribhuvan University
 
Search 2
Search 2Search 2
Uncertainty
UncertaintyUncertainty

More from Tribhuvan University (20)

Lecture 4 m&ca
Lecture 4 m&caLecture 4 m&ca
Lecture 4 m&ca
 
Lecture 3 m&ca
Lecture 3 m&caLecture 3 m&ca
Lecture 3 m&ca
 
Lecture 2 m&ca
Lecture 2 m&caLecture 2 m&ca
Lecture 2 m&ca
 
Lecture 1 m&ca
Lecture 1 m&caLecture 1 m&ca
Lecture 1 m&ca
 
Neural network (csc372) lecture 2
Neural network (csc372) lecture 2Neural network (csc372) lecture 2
Neural network (csc372) lecture 2
 
Neural network (csc372) lecture 1
Neural network (csc372) lecture 1Neural network (csc372) lecture 1
Neural network (csc372) lecture 1
 
Ai unit-2
Ai unit-2Ai unit-2
Ai unit-2
 
Ai unit-3
Ai unit-3Ai unit-3
Ai unit-3
 
Ai unit-4
Ai unit-4Ai unit-4
Ai unit-4
 
Unit 4(nlp _neural_network)
Unit 4(nlp _neural_network)Unit 4(nlp _neural_network)
Unit 4(nlp _neural_network)
 
Ai unit-6
Ai unit-6Ai unit-6
Ai unit-6
 
Ai unit-1
Ai unit-1Ai unit-1
Ai unit-1
 
Knowldge reprsentations
Knowldge reprsentationsKnowldge reprsentations
Knowldge reprsentations
 
Search 1
Search 1Search 1
Search 1
 
Ai introduction
Ai introductionAi introduction
Ai introduction
 
Assignment 1
Assignment 1Assignment 1
Assignment 1
 
Logic 2
Logic 2Logic 2
Logic 2
 
Artificial Intelligence Note
Artificial Intelligence NoteArtificial Intelligence Note
Artificial Intelligence Note
 
Search 2
Search 2Search 2
Search 2
 
Uncertainty
UncertaintyUncertainty
Uncertainty
 

Recently uploaded

A Survey of Techniques for Maximizing LLM Performance.pptx
A Survey of Techniques for Maximizing LLM Performance.pptxA Survey of Techniques for Maximizing LLM Performance.pptx
A Survey of Techniques for Maximizing LLM Performance.pptx
thanhdowork
 
Digital Artefact 1 - Tiny Home Environmental Design
Digital Artefact 1 - Tiny Home Environmental DesignDigital Artefact 1 - Tiny Home Environmental Design
Digital Artefact 1 - Tiny Home Environmental Design
amberjdewit93
 
Chapter 4 - Islamic Financial Institutions in Malaysia.pptx
Chapter 4 - Islamic Financial Institutions in Malaysia.pptxChapter 4 - Islamic Financial Institutions in Malaysia.pptx
Chapter 4 - Islamic Financial Institutions in Malaysia.pptx
Mohd Adib Abd Muin, Senior Lecturer at Universiti Utara Malaysia
 
World environment day ppt For 5 June 2024
World environment day ppt For 5 June 2024World environment day ppt For 5 June 2024
World environment day ppt For 5 June 2024
ak6969907
 
Your Skill Boost Masterclass: Strategies for Effective Upskilling
Your Skill Boost Masterclass: Strategies for Effective UpskillingYour Skill Boost Masterclass: Strategies for Effective Upskilling
Your Skill Boost Masterclass: Strategies for Effective Upskilling
Excellence Foundation for South Sudan
 
How to Manage Your Lost Opportunities in Odoo 17 CRM
How to Manage Your Lost Opportunities in Odoo 17 CRMHow to Manage Your Lost Opportunities in Odoo 17 CRM
How to Manage Your Lost Opportunities in Odoo 17 CRM
Celine George
 
clinical examination of hip joint (1).pdf
clinical examination of hip joint (1).pdfclinical examination of hip joint (1).pdf
clinical examination of hip joint (1).pdf
Priyankaranawat4
 
S1-Introduction-Biopesticides in ICM.pptx
S1-Introduction-Biopesticides in ICM.pptxS1-Introduction-Biopesticides in ICM.pptx
S1-Introduction-Biopesticides in ICM.pptx
tarandeep35
 
How to Build a Module in Odoo 17 Using the Scaffold Method
How to Build a Module in Odoo 17 Using the Scaffold MethodHow to Build a Module in Odoo 17 Using the Scaffold Method
How to Build a Module in Odoo 17 Using the Scaffold Method
Celine George
 
BÀI TẬP BỔ TRỢ TIẾNG ANH 8 CẢ NĂM - GLOBAL SUCCESS - NĂM HỌC 2023-2024 (CÓ FI...
BÀI TẬP BỔ TRỢ TIẾNG ANH 8 CẢ NĂM - GLOBAL SUCCESS - NĂM HỌC 2023-2024 (CÓ FI...BÀI TẬP BỔ TRỢ TIẾNG ANH 8 CẢ NĂM - GLOBAL SUCCESS - NĂM HỌC 2023-2024 (CÓ FI...
BÀI TẬP BỔ TRỢ TIẾNG ANH 8 CẢ NĂM - GLOBAL SUCCESS - NĂM HỌC 2023-2024 (CÓ FI...
Nguyen Thanh Tu Collection
 
Natural birth techniques - Mrs.Akanksha Trivedi Rama University
Natural birth techniques - Mrs.Akanksha Trivedi Rama UniversityNatural birth techniques - Mrs.Akanksha Trivedi Rama University
Natural birth techniques - Mrs.Akanksha Trivedi Rama University
Akanksha trivedi rama nursing college kanpur.
 
Main Java[All of the Base Concepts}.docx
Main Java[All of the Base Concepts}.docxMain Java[All of the Base Concepts}.docx
Main Java[All of the Base Concepts}.docx
adhitya5119
 
Hindi varnamala | hindi alphabet PPT.pdf
Hindi varnamala | hindi alphabet PPT.pdfHindi varnamala | hindi alphabet PPT.pdf
Hindi varnamala | hindi alphabet PPT.pdf
Dr. Mulla Adam Ali
 
ISO/IEC 27001, ISO/IEC 42001, and GDPR: Best Practices for Implementation and...
ISO/IEC 27001, ISO/IEC 42001, and GDPR: Best Practices for Implementation and...ISO/IEC 27001, ISO/IEC 42001, and GDPR: Best Practices for Implementation and...
ISO/IEC 27001, ISO/IEC 42001, and GDPR: Best Practices for Implementation and...
PECB
 
Digital Artifact 1 - 10VCD Environments Unit
Digital Artifact 1 - 10VCD Environments UnitDigital Artifact 1 - 10VCD Environments Unit
Digital Artifact 1 - 10VCD Environments Unit
chanes7
 
CACJapan - GROUP Presentation 1- Wk 4.pdf
CACJapan - GROUP Presentation 1- Wk 4.pdfCACJapan - GROUP Presentation 1- Wk 4.pdf
CACJapan - GROUP Presentation 1- Wk 4.pdf
camakaiclarkmusic
 
Assessment and Planning in Educational technology.pptx
Assessment and Planning in Educational technology.pptxAssessment and Planning in Educational technology.pptx
Assessment and Planning in Educational technology.pptx
Kavitha Krishnan
 
DRUGS AND ITS classification slide share
DRUGS AND ITS classification slide shareDRUGS AND ITS classification slide share
DRUGS AND ITS classification slide share
taiba qazi
 
Pollock and Snow "DEIA in the Scholarly Landscape, Session One: Setting Expec...
Pollock and Snow "DEIA in the Scholarly Landscape, Session One: Setting Expec...Pollock and Snow "DEIA in the Scholarly Landscape, Session One: Setting Expec...
Pollock and Snow "DEIA in the Scholarly Landscape, Session One: Setting Expec...
National Information Standards Organization (NISO)
 
MARY JANE WILSON, A “BOA MÃE” .
MARY JANE WILSON, A “BOA MÃE”           .MARY JANE WILSON, A “BOA MÃE”           .
MARY JANE WILSON, A “BOA MÃE” .
Colégio Santa Teresinha
 

Recently uploaded (20)

A Survey of Techniques for Maximizing LLM Performance.pptx
A Survey of Techniques for Maximizing LLM Performance.pptxA Survey of Techniques for Maximizing LLM Performance.pptx
A Survey of Techniques for Maximizing LLM Performance.pptx
 
Digital Artefact 1 - Tiny Home Environmental Design
Digital Artefact 1 - Tiny Home Environmental DesignDigital Artefact 1 - Tiny Home Environmental Design
Digital Artefact 1 - Tiny Home Environmental Design
 
Chapter 4 - Islamic Financial Institutions in Malaysia.pptx
Chapter 4 - Islamic Financial Institutions in Malaysia.pptxChapter 4 - Islamic Financial Institutions in Malaysia.pptx
Chapter 4 - Islamic Financial Institutions in Malaysia.pptx
 
World environment day ppt For 5 June 2024
World environment day ppt For 5 June 2024World environment day ppt For 5 June 2024
World environment day ppt For 5 June 2024
 
Your Skill Boost Masterclass: Strategies for Effective Upskilling
Your Skill Boost Masterclass: Strategies for Effective UpskillingYour Skill Boost Masterclass: Strategies for Effective Upskilling
Your Skill Boost Masterclass: Strategies for Effective Upskilling
 
How to Manage Your Lost Opportunities in Odoo 17 CRM
How to Manage Your Lost Opportunities in Odoo 17 CRMHow to Manage Your Lost Opportunities in Odoo 17 CRM
How to Manage Your Lost Opportunities in Odoo 17 CRM
 
clinical examination of hip joint (1).pdf
clinical examination of hip joint (1).pdfclinical examination of hip joint (1).pdf
clinical examination of hip joint (1).pdf
 
S1-Introduction-Biopesticides in ICM.pptx
S1-Introduction-Biopesticides in ICM.pptxS1-Introduction-Biopesticides in ICM.pptx
S1-Introduction-Biopesticides in ICM.pptx
 
How to Build a Module in Odoo 17 Using the Scaffold Method
How to Build a Module in Odoo 17 Using the Scaffold MethodHow to Build a Module in Odoo 17 Using the Scaffold Method
How to Build a Module in Odoo 17 Using the Scaffold Method
 
BÀI TẬP BỔ TRỢ TIẾNG ANH 8 CẢ NĂM - GLOBAL SUCCESS - NĂM HỌC 2023-2024 (CÓ FI...
BÀI TẬP BỔ TRỢ TIẾNG ANH 8 CẢ NĂM - GLOBAL SUCCESS - NĂM HỌC 2023-2024 (CÓ FI...BÀI TẬP BỔ TRỢ TIẾNG ANH 8 CẢ NĂM - GLOBAL SUCCESS - NĂM HỌC 2023-2024 (CÓ FI...
BÀI TẬP BỔ TRỢ TIẾNG ANH 8 CẢ NĂM - GLOBAL SUCCESS - NĂM HỌC 2023-2024 (CÓ FI...
 
Natural birth techniques - Mrs.Akanksha Trivedi Rama University
Natural birth techniques - Mrs.Akanksha Trivedi Rama UniversityNatural birth techniques - Mrs.Akanksha Trivedi Rama University
Natural birth techniques - Mrs.Akanksha Trivedi Rama University
 
Main Java[All of the Base Concepts}.docx
Main Java[All of the Base Concepts}.docxMain Java[All of the Base Concepts}.docx
Main Java[All of the Base Concepts}.docx
 
Hindi varnamala | hindi alphabet PPT.pdf
Hindi varnamala | hindi alphabet PPT.pdfHindi varnamala | hindi alphabet PPT.pdf
Hindi varnamala | hindi alphabet PPT.pdf
 
ISO/IEC 27001, ISO/IEC 42001, and GDPR: Best Practices for Implementation and...
ISO/IEC 27001, ISO/IEC 42001, and GDPR: Best Practices for Implementation and...ISO/IEC 27001, ISO/IEC 42001, and GDPR: Best Practices for Implementation and...
ISO/IEC 27001, ISO/IEC 42001, and GDPR: Best Practices for Implementation and...
 
Digital Artifact 1 - 10VCD Environments Unit
Digital Artifact 1 - 10VCD Environments UnitDigital Artifact 1 - 10VCD Environments Unit
Digital Artifact 1 - 10VCD Environments Unit
 
CACJapan - GROUP Presentation 1- Wk 4.pdf
CACJapan - GROUP Presentation 1- Wk 4.pdfCACJapan - GROUP Presentation 1- Wk 4.pdf
CACJapan - GROUP Presentation 1- Wk 4.pdf
 
Assessment and Planning in Educational technology.pptx
Assessment and Planning in Educational technology.pptxAssessment and Planning in Educational technology.pptx
Assessment and Planning in Educational technology.pptx
 
DRUGS AND ITS classification slide share
DRUGS AND ITS classification slide shareDRUGS AND ITS classification slide share
DRUGS AND ITS classification slide share
 
Pollock and Snow "DEIA in the Scholarly Landscape, Session One: Setting Expec...
Pollock and Snow "DEIA in the Scholarly Landscape, Session One: Setting Expec...Pollock and Snow "DEIA in the Scholarly Landscape, Session One: Setting Expec...
Pollock and Snow "DEIA in the Scholarly Landscape, Session One: Setting Expec...
 
MARY JANE WILSON, A “BOA MÃE” .
MARY JANE WILSON, A “BOA MÃE”           .MARY JANE WILSON, A “BOA MÃE”           .
MARY JANE WILSON, A “BOA MÃE” .
 

Logic homework

  • 1. B. Sc. CSIT 5th Semester By Bal Krishna Subedi1 Home Works for Logic Propositional Logic 1. 7.4, 7.5, 7.7, 7.8 & 7.12 from Textbook (R&N) 2. The logical operator  is read “if and only if”. P Q is defined as being equivalent to (P Q) ^ (Q  P). Based on this definition, show that (P Q) is logically equivalent to (P  Q)  (Q ^ P). a. By using truth table. b. By a series of substitutions (use identities on page on Page 210) 3. Consider the knowledge base: If it is raining out then Ann puts the top up on her convertible. Ann did not put the top up on her convertible. (a) Describe a set of propositional letters which can be used to represent the knowledge base. (b) Translate the KB into propositional logic using your propositional letters from part a. (c) Is it raining? Answer this question by using logical inference rules with the KB. Predicate Logic 1. 8.2, 8.3, 8.4, 8.6, 8.7 & 8.9. 2. 9.2, 9.4, 9.9, 9.10, 9.11, 9.17, 9.18 & 9.19 3. Consider the following sentence in FOL: 3. Attempt to unify the following pair of expressions. Either show their most general unifiers or explain why they will not unify. a. P(X, Y) and p(a, Z) b. p(X, X) and p(a, b)
  • 2. B. Sc. CSIT 5th Semester By Bal Krishna Subedi2 c. ancestor(X,Y) and ancestor (bill, father(bill)) d. ancestor (X, father(X)) and ancestor(david, george) e. q(X) and q(a) 4. The following story is from N. Wirth’s (1976) I married a widow (let’s call her W) who has a grown-up daughter (call her D). My father (F), who visited us quite often, fell in love with my step daughter and married her. Hence my father becomes my son-in-law and my step-daughter becomes my mother. Some months later, my wife gave birth to a son (S1), who becomes the brother-in-law of my father, as well as my uncle. The wife of my father, that is, my step-daughter, also had a son (S2). Using the predicate logic, create a set of expressions that represent the situation in the above story. Add expressions defining basic family relationships such as the definition of father-in-low and use modus ponen on this system to prove the conclusion that “I am my own grandfather”.