Assignment 3
Written Assignment - Logic and Planning
Max points:
- CSE 4308: 100 (120 with EC)
- CSE 5360: 100 (110 with EC)
The
assignment should be submitted via Canvas.
Instructions
- The answers can be typed as a document or handwritten and
scanned.
- Name files as
assignment3_<net-id>.<format>
- Accepted document format is .pdf.
- If you are using Word, OpenOffice or LibreOffice, make
sure
to
save as .pdf.
- If you are using LaTEX, compile into a .pdf file.
- Please do not submit
.txt files.
- If
you are scanning handwritten documents make sure to scan it at a
minimum of 600dpi and save as a .pdf or .png file. Do not
insert images in word document and submit.
- If there are multiple files in your submission, zip them
together as assignment6_<net-id>.zip and submit the .zip
file.
Task 1 (CSE 4308: 10 Points; CSE 5360: 10 points)
A |
B |
C |
KB |
S1 |
True |
True |
True |
True |
True |
True |
True |
False |
False |
True |
True |
False |
True |
True |
True |
True |
False |
False |
False |
True |
False |
True |
True |
False |
False |
False |
True |
False |
False |
False |
False |
False |
True |
True |
True |
False |
False |
False |
False |
False |
KB and S1 are two propositional logic statements, that are constructed
using symbols A, B, C, and using various connectives. The above truth
table shows, for each combination of values of A, B, C, whether KB and
S1 are true or false.
Part a: Given the above
information, does KB entail S1? Justify your answer.
Part b: Given the above
information, does statement NOT(KB) entail statement NOT(S1)? Justify
your answer.
Task 2 (CSE 4308: 10 Points; CSE 5360: 10 points)
Suppose that some knowledge base contains various
propositional-logic sentences that utilize symbols A, B, C, D
(connected with various connectives). There are only two cases when the
knowledge base is false:
- First case: when A is true, B is false, C is false, D is true.
- Second case: when A is false, B is true, C is true, D is false.
In all other cases, the knowledge base is true. Write a conjunctive
normal form (CNF) for the knowledge base.
Task 3 (CSE 4308: 15 Points; CSE 5360: 15 points)
Consider the KB
A <=> B
A => C
D => E
C AND E => F
B
D
Show that this entails F by
i. Forward Chaining
ii. Backward Chaining
iii. Resolution
Task 4 (CSE 4308: 25 Points; CSE 5360: 20 points)
John and Mary sign the following contract:
- If it rains on May 1, 2020, then John must give Mary a check for
$10,000 on May 2, 2020
- Mary must mow
the lawn on May 3, 2020 if and only if John gives Mary a check for $10,000 on May 2, 2020.
What truly happened those days is the following:
- it did not rain on May 1, 2020
- John gave Mary a check for $10,000 on May 2, 2020
- Mary mowed the lawn on May 3, 2020.
Part a: Write a first order logic
statement to express the contract. Make sure that you clearly define
what constants and predicates that you use are. (NOTE: DO NOT use
functions)
Part b: Write a logical statement to
express what truly happened. When possible, use the same predicates and
constants as in
question 4a. If you need to define any new predicates or constants,
clearly define what
they stand for.
Part c: Define the
symbols required to convert any KB involved in the above
domanin from FOL to Propositional logic. Use this to convert the
answers to part a and b to Propositional Logic.
Part d:
Was the contract violated
or not, Justify your answer [Note: Contract is not violated if the sequence of events entails the contract]
Task 5 (CSE 4308: 20 Points (+10 Points EC); CSE 5360: 15 points (+10
Points EC))
Consider the following scenario:
Your task is to get all the blue marbles in P1 and red marbles in P2
The actions available are as follows:
- You can move 2 marbles from P1 to P2 if they are of the same color (either you can move 2 red or you can move 2 blue)
- You can move 2 marbles from P2 to P1 if they are each of different colors (one blue or one red)
Give the PDDL description to represent the above as a Planning Problem.
Do not forget to also define and describe the predicates and constants
that your are going to use.
Extra Credit (10 pts): Also,
give a complete plan (using the actions described) for getting
from the start to the goal state
Task 6 (CSE 4308: 20 Points; CSE 5360: 20 points)
Suppose that we are using PDDL to describe facts and actions in a
certain world called JUNGLE. In the JUNGLE world there are 5
predicates, each predicate takes at most 4 arguments, and there are 3
constants. Give a reasonably tight bound on the number of unique states
in the JUNGLE world. Justify your answer.
Task 7 (CSE 4308: 10 Points (EC); CSE 5360: 10 points)
Consider the problem in Task 5. Let us say that, when you move the
marbles, it is possible to sometimes end up moving only one of them
(You try to move 2 Red marbles from P1 to P2 but only end up moving
one). How would you modify the actions
you described in Task 5 to account for this if you were going to try
and handle this scenario by
- Execution Monitoring/Online Replanning
- Conditional Planning
In both cases, show what the modifications are (If no modification is
necessary, Justify).