Practice Homework 1 - Artificial Intelligence | CPSC 420, Assignments of Computer Science

Material Type: Assignment; Professor: Choe; Class: ARTIFICIAL INTELLIGENCE; Subject: COMPUTER SCIENCE; University: Texas A&M University; Term: Unknown 1989;

Typology: Assignments

Pre 2010

Uploaded on 02/10/2009

koofers-user-rxt
koofers-user-rxt 🇺🇸

8 documents

1 / 4

Toggle sidebar

This page cannot be seen from the preview

Don't miss anything!

bg1
CPSC 420-500 Homework #1
Due 10/8/07, in Class
Handwritten or printed hardcopy must be submitted
Instructor: Yoonsuck Choe
September 30, 2007
1 Uninformed Search
B
EA C D
(a) Tree 1 (b) Tree 2 (c) Tree 3
Figure 1: Search Trees.
Consider the three search trees in Figure 1. Suppose the branching factor is band the tree is full. Nodes A,
B, C, D, and E the goal nodes in the trees. Assume that nodes A, C, D, and E are at depth n; and A and C are
the k-th node from the left at that depth, where k < b, i.e., they are children of the left-most node at depth
n1. Node B is at depth m(< n). Node D is the last node to the right at depth n. Depth nis the last level
of all the trees. Further assume that the exploration of each depth level proceeds from the left to the right.
Question 1 (4 pts): Which one shows a case where both depth-first and breadth-first have identical time
complexity? (Tree 1, 2, or 3)
Question 2 (4 pts): Which one shows a case where depth-first can be complete but non-optimal? (Tree 1,
2, or 3) Explain why.
Question 3 (8 pts): Assume b= 4,k= 3,m= 4, and n= 20. What is the number of nodes visited in
case of Tree 2 for depth-first (and breadth-first)?
Question 4 (4 pts): Assume b= 4,k= 3,m= 4, and n= 20. In which case does depth-first outperform
breadth-first in terms of time complexity (= nodes visited)? (Tree 1, 2, or 3)
Question 5 (4 pts): Answer the following questions (5–6) regarding iterative-deepening search (IDS). In
what sense is iterative-deepening search similar to depth-first and to breadth-first? Answer in terms of (some
of) the four evaluation criteria.
Question 6 (4 pts): If space is adequate, is IDS still a good choice compared to breadth-first search
(Yes/No)? Explain why.
1
pf3
pf4

Partial preview of the text

Download Practice Homework 1 - Artificial Intelligence | CPSC 420 and more Assignments Computer Science in PDF only on Docsity!

CPSC 420-500 Homework

Due 10/8/07, in Class

Handwritten or printed hardcopy must be submitted

Instructor: Yoonsuck Choe

September 30, 2007

1 Uninformed Search

B

A C E D

(a) Tree 1 (b) Tree 2 (c) Tree 3

Figure 1: Search Trees.

Consider the three search trees in Figure 1. Suppose the branching factor is b and the tree is full. Nodes A, B, C, D, and E the goal nodes in the trees. Assume that nodes A, C, D, and E are at depth n; and A and C are the k-th node from the left at that depth, where k < b, i.e., they are children of the left-most node at depth n − 1. Node B is at depth m (< n). Node D is the last node to the right at depth n. Depth n is the last level of all the trees. Further assume that the exploration of each depth level proceeds from the left to the right.

Question 1 (4 pts): Which one shows a case where both depth-first and breadth-first have identical time complexity? (Tree 1, 2, or 3)

Question 2 (4 pts): Which one shows a case where depth-first can be complete but non-optimal? (Tree 1, 2, or 3) Explain why.

Question 3 (8 pts): Assume b = 4, k = 3, m = 4, and n = 20. What is the number of nodes visited in case of Tree 2 for depth-first (and breadth-first)?

Question 4 (4 pts): Assume b = 4, k = 3, m = 4, and n = 20. In which case does depth-first outperform breadth-first in terms of time complexity (= nodes visited)? (Tree 1, 2, or 3)

Question 5 (4 pts): Answer the following questions (5–6) regarding iterative-deepening search (IDS). In what sense is iterative-deepening search similar to depth-first and to breadth-first? Answer in terms of (some of) the four evaluation criteria.

Question 6 (4 pts): If space is adequate, is IDS still a good choice compared to breadth-first search (Yes/No)? Explain why.

2 Informed Search

Answer the following questions regarding informed search strategies.

Question 1 (4 pts): Why does A∗^ have an exponential space requirement (in case the heuristic function is not very good)? Compare with breadth-first search, and explain in relation to the concept of f -contour.

Question 2 (4 pts): Why is IDA∗^ more efficient in space than A∗? Explain in terms of the particular exploration strategy.

Question 3 (4 pts): What is the potential disadvantage of IDA∗^ compared to A∗^ if space is adequate?

Question 4 (4 pts): What is the difference between greedy search and A∗^ search?

I

b

c f

h i^ j

d e

g

10

20

100 80

h=

a h=100 h=

h=160 h=

h=

(^100 )

165 172 81 77

Figure 2: Search tree. An example search tree is shown with path cost on each edge and heuristic function value next to each node. The leaf nodes are goal states.

Question 5 (6 pts): Given the search tree in figure 2, calculate the f (n) value for each node (a to j).

Question 6 (12 pts): Given the search tree in figure 2, list the node visit order and the goal state reached for the two search methods: (1) greedy search, and (3) A∗.

4 Propositional Logic

4.1 Normal forms

In all of the problems in this section, show each step of the derivation and indicate which axioms (or other rules) you used: For example, distributive law, by definition, etc.

Question 1 (2 pts): Convert A ∨ (B ∧ ¬C) into conjunctive normal form.

Question 2 (4 pts): Convert A ∨ (B ∧ ¬C) ∨ (B ∧ E) into conjunctive normal form.

Question 3 (2 pts): Convert (A → B) → (C ∨ D) into disjunctive normal form.

4.2 Theorem proving

Question 1 (12 pts): Using resolution, show that G ∨ A is a logical consequence of the following:

1. C → (A ∨ B)

2. (D → E) ∧ ¬E

3. B → (G ∨ E)

4. D ∨ C

Hint: first, transform the problem into a set of clauses, and the follow the resolution steps.