You are on page 1of 28

NATIONAL INSTITUTE OF TECHNOLOGY ROURKELA

END - SEM EXAMINATION, 2022


SESSION: 2022 – 2023 (Autumn)
B.Tech 7th Semester and Ph.D.

Subject Code : CS-6412 Subject Name : Artificial Intelligence Dept. Code : CS


No. of Pages : 02 Full Marks : 50 Duration : 3 Hrs.

Answer ALL questions. Unnecessary and extra writing will attract negative marks.

1. Pacman plays against a moving wall. On Pacman’s turn, Pacman must move in one of the four
cardinal directions and must move into an unoccupied square. On the wall’s turn, the wall must
move in one of the four cardinal directions and into an unoccupied square to block the Pacman. The
wall cannot move into a dot-containing square. Staying still is not allowed by either player. Pacman’s
score always equals the number of dots he has eaten, A partial game tree is drawn and shown in
Figure 1. (i) Find the values of all internal nodes using the minmax algorithm. (ii) Find out the
nodes not evaluated using alpha-beta pruning (assuming the standard left-to-right tree traversal). (3+3=6)

Figure 1: Game Tree of Question 1.


2. Pacman is currently hiding at an undisclosed location. In this problem, you are on the SpongeBob
side, trying to catch Pacman!!!. In this problem, SpongeBob’s car can move with two distinct integer
controls: throttle and steering, but Pacman has to stay stationary. Once SpongeBob car takes an
action that lands him in the same grid as Pacman, Pacman will be arrested, and the game ends.
Throttle : ti ∈ {1, 0, −1} , corresponding to {Gas, Coast, Brake}. Steering : si ∈ {1, 0, −1} ,
corresponding to {Turn Left, Go Straight, Turn Right}. Suppose you have absolutely no information
about where Pacman stopped to hide. (2+2=4)
(a) What is the tightest upper bound on the size of state space representing all states in the search
space if your goal is to use search to plan a sequence of actions that guarantees Pacman is
caught, no matter where Pacman is hiding.
(b) Is Breadth First Graph Search guaranteed to return the path with the shortest number of time
steps? If one exists, why? Support your answer in one sentence.
3. Which of the following are true and which are false? Support your answers in one sentence. (2+2+2=6)
(a) A∗ is of no use in robotics because percepts, states, and actions are continuous.
(b) Breadth-first search is complete even if zero step costs are allowed.
(c) Is Manhattan distance an admissible heuristic for the problem of moving the rook from square
A to square B in the smallest number of moves?
4. In the search problem shown in Figure 2. S is the start-state; G is the (only) goal-state. The actual
costs for each edge are shown on the graph. Consider the heuristics for this search problem shown
in the table. Which of the following are true or false? Support your answers in one sentence. (i) Is
h1 admissible? (ii) Is h1 consistent? (iii) Is h2 admissible? (iv) Is h2 consistent? (1+1+1+1=4)
5. Describe the differences and similarities between problem-solving and planning. What is state space,
and how is it different from plan space? What is a partial order plan? (2+2+1=5)
6. Lord Voldemort wishes to acquire the elder wand, the resurrection stone, and the invisibility cloak.
He has written down the actions as follows: (5)
Op(ACTION : GetWand, PRECOND: At(x), EFFECT: Have(wand)∧¬Happy)
Op(ACTION : GetStone, PRECOND: At(x), EFFECT: Have(stone)∧Safe)
Figure 2: Search Problem of Question 4.

Op(ACTION : StealCloak, PRECOND: At(x), EFFECT: Have(cloak)∧Invisible∧Happy)


Op(ACTION : BuyCloak, PRECOND: At(x), EFFECT: Have(cloak)∧¬Invisible∧¬Safe)
Op(ACTION : Start, EFFECT: At(Hogwarts))
Op(ACTION : Finish, PRECOND: Have(wand)∧Have(stone)∧Have(cloak))
Voldemort has decided to use the GraphPlan algorithm to choose his plan. Draw the planning graph
after one iteration indicating all the mutex links.
7. Given the following facts in the knowledge base, prove the validity of hate(M arcus, Caeser) using
the method of resolution refutation. (4)
man(M arcus), P ompeian(M arcus), ¬P ompeian(x1 ) ∨ Roman(x1 ), ruler(Ceaser),
¬Roman(x2 ) ∨ loyalto(x2 , Caeser) ∨ hate(x2 , Caeser),
¬man(x4 ) ∨ ¬ruler(y1 ) ∨ ¬trytoassinate(x4 , y1 ) ∨ loyalto(x4 , y1 ),
trytoassinate(M arcus, Caeser)
8. Convert the following facts into FOL and prove by forward chaining algorithm, also show the forward
chaining proof tree. (3+3=6)
The law says it is a crime for an American to sell weapons to hostile nations. The
country Nono, an enemy of America, has some missiles, and all of its missiles were sold
to it by Colonel West, who is American. Prove that West is a criminal.
9. Suppose that a patient can have a symptom (S) that can be caused by two different diseases (A and
B). It is known that the variation of gene G plays a big role in the manifestation of disease A. The
corresponding conditional probability tables for this situation are shown below. (1+1+2+2+2+2=10)

(a) Draw the Bayesian network.


(b) Find the probability that the patient has gene variation G, diseases A and B, and symptom S.
(c) What is the probability that a patient has disease A?
(d) What is the probability that a patient has disease A, given that they have disease B?
(e) What is the probability that a patient has disease A, given that they have symptom S and
disease B?
(f) What is the probability that a patient has the disease-carrying gene variation G, given that
they have disease A?

—————- Best Wishes —————-

Page 2
NATIONAL INSTITUTE OF TECHNOLOGY ROURKELA
MID - SEM EXAMINATION, 2022
SESSION: 2022 – 2023 (Autumn)
B.Tech. 7th Semester and Ph.D

Subject code: CS6412 Subject Name: Artificial Intelligence Dept. Code: CS


No. of pages: 2 Full Marks: 30 Duration: 2 Hrs

Answer ALL questions. Unnecessary and extra writing will attract negative marks.
1). For each of the following activities, give a PEAS description of the task environment and their characterize
it in terms of the properties
a). Taxi driving. b). Crossword puzzle. c). Medical Diagnosis. d). Part-picking Robot [4x1=4]
2). Consider a state space where the start state is number 1 and each state k has two successors: numbers 2k
and 2k + 1.
a). Draw the portion of the state space for states 1 to 15.
b). Suppose the goal state is 11. List the order in which nodes will be visited for breadth first
search, depth-limited search with limit 3, and iterative deepening search.
c). How well would bidirectional search work on this problem? What is the branching factor in
each direction of the bidirectional search?
d). Call the action going from k to 2k Left, and the action going to 2k + 1 Right. Can you
find an algorithm that outputs the solution to this problem without any search at all? [4]
3). The two slugs A and B want to exit out of the given maze (𝑀 × 𝑁) size, either slug can use either exit, but
they must use different exits. In each time step, both slugs move, though each can choose to either stay in
place or move into an adjacent free square. The slugs cannot move into a square that the other slug is moving
into. In addition, it cannot move into any square that either slug has ever been in. For example, if slugs A and
B begin in the positions shown above on the left, and slug A moves Down 3 steps while slug B moves Right
three steps, then the world becomes as shown above on the right, with x's marking the poisonous squares. Note
that slug A does have the option of moving Right from its current position, since the trail from B will evaporate
by the time it arrives.
a). How many states are there in a minimal representation of the space? Justify with a brief description of the
components of your state space.
b). What is the branching factor? Justify with a brief description of the successor function. [2+1=3]

4. a). What do you mean by hill climbing search technique? Explain the advantage and disadvantage of this
approach. Also, explain how we can use any one local searching technique to solve 8-queens problem.
b). Devise a state space in which 𝐴∗ using GRAPH-SEARCH returns a suboptimal solution with an h(n)
function that is admissible but inconsistent.
c). Compare the uninformed search strategies with completeness, time, space and optimality criterion.
[3+2+1=6]
5). Consider the unbounded version of the regular 2D grid shown in Figure 1. The start state is at the origin,
(0,0), and the goal state is at (𝑥, 𝑦).

Fig 1: In (a), just the root has been expanded. In (b), one leaf node has been expanded. In (c), the remaining successors
of the root have been expanded in clockwise order.
a. What is the branching factor 𝑏 in this state space?
b. How many distinct states are there at depth 𝑘 (for 𝑘 > 0)?
c. What is the maximum number of nodes expanded by breadth-first tree search?
d. What is the maximum number of nodes expanded by breadth-first graph search?
e. Is ℎ = |𝑢 − 𝑥| + |𝑣 − 𝑦| an admissible heuristic for a state at (𝑢, 𝑣)? Explain.
f. How many nodes are expanded by 𝐴∗ graph search using ℎ?
g. Does ℎ remain admissible if some links are removed?
h. Does ℎ remain admissible if some links are added between nonadjacent states? [4]
6). Explain minimax algorithm with alpha-beta pruning. Show alpha-beta pruning on the following minimax
graph.

Pruned

[3]

7). Give the name of the algorithm that results from each of the following special cases with proper
justification:
a. Local beam search with 𝑘 = 1
b. Local beam search with one initial state and no limit on the number of states retained.
c. Simulated annealing with 𝑇 = 0 at all times (and omitting the termination test).
d. Simulated annealing with 𝑇 = ∞ at all times.
e. Genetic algorithm with population size 𝑁 = 1. [3]

8). Prove each of the following statements, or give a counterexample:


A. Breadth-first search is a special case of uniform-cost search.
B. Depth-first search is a special case of best-first tree search.
C. Uniform-cost search is a special case of 𝐴∗ search. [3]

*************************** ALL THE BEST ******************************


NATIONAL INSTITUTE OF TECHNOLOGY ROURKELA
END - SEM EXAMINATION, 2021
SESSION: 2021 – 2022 (Autumn)
B.Tech, M.Tech, PhD

Subject code: CS6412 Subject Name: Artificial Intelligence Dept. Code: CS


No. of pages: 9 Full Marks: 50 Duration: 2 Hrs

Answer ALL questions and choose the correct option. There are 20 multiple choice questions and 3
subjective questions. Each MCQ carries 1 mark except few MCQ which carries 2 marks. Each
subjective question carries 8 marks.
1. Ronald has a vocabulary with only four propositions, 𝑊, 𝑋, 𝑌, and 𝑍. Choose the correct number of models
for the given sentences: 𝑋 ∨ 𝑌, ¬𝑊 ∨ ¬𝑋 ∨ ¬𝑌 ∨ ¬𝑍, (𝑊 ⇒ 𝑋) ∧ 𝑊 ∧ ¬𝑋 ∧ 𝑌 ∧ 𝑍.
a. 13, 12, 7
b. 12, 15, 0.
c. 16, 18, 9.
d. None of the above.

2. Consider the following sentence:


[(𝐹𝑜𝑜𝑑 ⇒ 𝑃𝑎𝑟𝑡𝑦) ∨ (𝐷𝑟𝑖𝑛𝑘𝑠 ⇒ 𝑃𝑎𝑟𝑡𝑦)] ⇒ [(𝐹𝑜𝑜𝑑 ∧ 𝐷𝑟𝑖𝑛𝑘𝑠) ⇒ 𝑃𝑎𝑟𝑡𝑦] .
Comment on the given sentence being ______ using resolution theorem. Choose the correct alternative to
fill in the empty blank:
a. Satisfiable (but not valid)
b. Unsatisfiable.
c. Valid.
d. None of the above.

3. For the pairs of atomic sentences given below, choose which of the alternative(s) do not have a general
unifier?
I. 𝑃(𝐴, 𝐵, 𝐵), 𝑃(𝑥, 𝑦, 𝑧).
II. 𝑄(𝑦, 𝐺(𝐴, 𝐵)), 𝑄(𝐺(𝑥, 𝑥), 𝑦).
III. 𝑂𝑙𝑑𝑒𝑟(𝐹𝑎𝑡ℎ𝑒𝑟(𝑦), 𝑦), 𝑂𝑙𝑑𝑒𝑟(𝐹𝑎𝑡ℎ𝑒𝑟(𝑥), 𝐽𝑜ℎ𝑛).
IV. 𝐾𝑛𝑜𝑤𝑠(𝐹𝑎𝑡ℎ𝑒𝑟(𝑦), 𝑦), 𝐾𝑛𝑜𝑤𝑠(𝑥, 𝑥).
a. II, IV.
b. III, IV.
c. I, III.
d. A general unifier exists for all of the pairs.

4. Consider the two sentences given in First Order Logic (FOL):


(A) ∀ 𝑥 ∃ 𝑦 (𝑥 ≥ 𝑦)
(B) ∃ 𝑦 ∀ 𝑥 (𝑥 ≥ 𝑦)
Assume that the variables range over all the natural numbers 0, 1, 2, . . . , ∞ and that the “≥”
predicate means “is greater than or equal to.” Under this interpretation, choose the correct
alternative which infers to false for the given statements.
a. A & B are true under this interpretation.
b. B logically entails A.
c. A logically entails B.
d. All of the above are true.
5. After Skolemization of the given statement, choose the correct expression from the choices given:
“All students of a philosopher read one of their teacher’s books”.
a. ∀𝑥∀𝑦[¬𝑃ℎ𝑖𝑙𝑜(𝑥) ∨ ¬𝑆𝑡𝑢𝑑𝑒𝑛𝑡𝑂𝑓 (𝑦, 𝑥) ∨ [𝐵𝑜𝑜𝑘(ℎ(𝑥, 𝑦)) ∧ 𝑊𝑟𝑖𝑡𝑒(𝑥, ℎ(𝑥, 𝑦)) ∧ 𝑅𝑒𝑎𝑑(𝑦, ℎ(𝑥, 𝑦))]]
b. ∀𝑥∀𝑦[𝑃ℎ𝑖𝑙𝑜(𝑥) ∧ 𝑆𝑡𝑢𝑑𝑒𝑛𝑡𝑂𝑓 (𝑦, 𝑥) → ∃𝑧[¬𝐵𝑜𝑜𝑘(𝑧) ∧ 𝑊𝑟𝑖𝑡𝑒(𝑥, 𝑧) ∧ 𝑅𝑒𝑎𝑑(𝑦, 𝑧)]]
c. ∀𝑥∀𝑦[𝑃ℎ𝑖𝑙𝑜(𝑥) ∧ ¬𝑆𝑡𝑢𝑑𝑒𝑛𝑡𝑂𝑓 (𝑦, 𝑥) → ∃𝑧[𝐵𝑜𝑜𝑘(𝑧) ∧ 𝑊𝑟𝑖𝑡𝑒(𝑥, 𝑧) ∧ ¬𝑅𝑒𝑎𝑑(𝑦, 𝑧)]]
d. None of the above.

6. Let "𝐿" be the first-order language with a single predicate 𝑆(𝑝, 𝑞), meaning “𝑝 𝑠ℎ𝑎𝑣𝑒𝑠 𝑞.”
Take a domain of people as assumption.
Consider the given sentence “There exists a person 𝑃 who shaves everyone who does not
shave themselves, and only people that do not shave themselves.” The expression of the discussed
data in “𝐿” is:
a. ∀𝑝 ∀ 𝑞 𝑆(𝑝, 𝑞) ⇔ ¬𝑆(𝑞, 𝑞)
b. ∃ 𝑝 ∀ 𝑞 𝑆(𝑝, 𝑞) ⇔ ¬𝑆(𝑞, 𝑞)
c. ∃ 𝑝 ∃ 𝑞 𝑆(𝑝, 𝑞) ⇔ ¬𝑆(𝑞, 𝑞)
d. None of the above.

7. Breadth-first search is a special case of uniform-cost search. Choose the correct option pertaining to
the given statement’s cause:
a. When all step costs are equal, 𝑔(𝑛) ∝ 𝑑𝑒𝑝𝑡ℎ(𝑛), so uniform-cost search reproduces
breadth-first search.
b. When all step costs are not equal, 𝑔(𝑛) ∝ 𝑑𝑒𝑝𝑡ℎ(𝑛), so uniform-cost search reproduces
breadth-first search.
c. When all step costs are equal, 𝑔(𝑛) ∝ 1/𝑑𝑒𝑝𝑡ℎ(𝑛), so uniform-cost search reproduces
breadth-first search.
d. None of the above.

8. Consider the given scenario:


The missionaries and cannibals problem is usually stated as follows. Three missionaries and three
cannibals are on one side of a river, along with a boat that can hold one or two people. Find a way to get
everyone to the other side without ever leaving a group of missionaries in one place outnumbered by the
cannibals in that place.
Choose from the alternative(s) a correct possible representation of the above stated problem:
a. A state is a six-tuple of integers listing the number of missionaries, cannibals, and boats on
the first side, and then the second side of the river. The goal is a state with 3 missionaries and 3
cannibals on the second side. The cost function is one per action, and the successors of a state
are all the states that move 1 or 2 people and 1 boat from one side to another.
b. A state is a seven-tuple of integers listing the number of missionaries, cannibals, and boats on the
first side, and then the second side of the river. The goal is a state with 2 missionaries and 4 cannibals
on the second side. The cost function is three per action, and the successors of a state are all the states
that move 2 or 4 people and 1 boat from one side to another.
c. A state is a five-tuple of integers listing the number of missionaries, cannibals, and boats on the
first side, and then the second side of the river. The goal is a state with 2 missionaries and 5 cannibals
on the second side. The cost function is one per action, and the successors of a state are all the states
that move 1 or 2 people and 3 boats from one side to another.
d. None of the above are apt. representations.
9. How many models are there for 𝑆𝑚𝑜𝑘𝑒 ∧ ¬ 𝐹 𝑖𝑟𝑒 ?
a. 2𝑛−2
b. ∞
c. Both a & b can be the solution under different scenarios.
d. None of the above.

10. Translate the following English statement into First Order Logic:
“Every new beginning comes from some other beginning end.”
a. ∀𝑥∀𝑦𝐵𝑒𝑔𝑖𝑛𝑛𝑖𝑛𝑔(𝑥) ⇒ [𝐵𝑒𝑔𝑖𝑛𝑛𝑖𝑛𝑔(𝑦) ∧ 𝐶𝑜𝑚𝑒𝑠𝐹 𝑟𝑜𝑚(𝑥, 𝑒𝑛𝑑(𝑧))]
b. ∀𝑥∃𝑧𝐵𝑒𝑔𝑖𝑛𝑛𝑖𝑛𝑔(𝑥) ⇒ [𝐵𝑒𝑔𝑖𝑛𝑛𝑖𝑛𝑔(𝑧) ∧ 𝐶𝑜𝑚𝑒𝑠𝐹 𝑟𝑜𝑚(𝑧, 𝑒𝑛𝑑(𝑦))]
c. ∀𝑥∃𝑦𝐵𝑒𝑔𝑖𝑛𝑛𝑖𝑛𝑔(𝑦) ⇒ [𝐵𝑒𝑔𝑖𝑛𝑛𝑖𝑛𝑔(𝑦) ∨ 𝐶𝑜𝑚𝑒𝑠𝐹 𝑟𝑜𝑚(𝑥, 𝑒𝑛𝑑(𝑦))]
d. ∀𝑥∃𝑦𝐵𝑒𝑔𝑖𝑛𝑛𝑖𝑛𝑔(𝑥) ⇒ [𝐵𝑒𝑔𝑖𝑛𝑛𝑖𝑛𝑔(𝑦) ∧ 𝐶𝑜𝑚𝑒𝑠𝐹 𝑟𝑜𝑚(𝑥, 𝑒𝑛𝑑(𝑦))]

11. The figure below depicts a game tree in which the root (node A) is a maximizing node and children
are visited left to right. With the application of alpha-beta pruning strategy which nodes will be
pruned?

a. CHI
b. GHI
c. HI
d. None of the above.

12. The following figure is an illustration of a 3-puzzle whereas tile can only travel to an adjacent
empty space. Given the initial state as shown below, which of the following state cannot be reached
[Consider the locations to be numbered as (0,0), (0,1), (1,0), (1,1) respectively to understand the
position of a tile numbered (1, 2 or 3) on the puzzle]?

a. 3[0,0], 1[0,1], 2[1,1] b. 3[0,1], 2[1,0], 1[1,1] c. 1[0,0], 3[0,1], 2[1,1] d. 2[0,1], 1[1,0], 3[1,1]
13. Choose from the following the correct implementation of the metapredicate “not” in PROLOG (F
represents the Final/Goal State)?

a. not(F):– !, call(F), fail. not(F).


b. not(F):– call(F), !, fail. not(F).
c. not(F):– call(F), fail, !. not(F).
d. not(F):– call(F), fail. not(F):– !.

14. Consider the well-known spare tire problem in planning. The problem is as explained below:
The problem is about changing of a flat tire. More precisely, the goal is to have a good spare tire properly
mounted onto the car’s axle, where the initial state has a flat tire on the axle and a good spare tire in the trunk.
To keep it simple, our version of the problem is a very abstract one, with no sticky lug nuts or other complica-
tions. There are just four actions: removing the spare from the trunk, removing the flat tire from the axle, putt-
ing the spare on the axle, and leaving the car unattended overnight. We assume that the car is in particularly b-
ad neighborhood, so that the effect of leaving it overnight is that the tires disappear.

With respect to this, consider the figure given below which shows a partial-order-planning step for the problem.

Choose the correct option by correctly analyzing the given figure:


a. To resolve a conflict we add an ordering constraint putting 𝐿𝑒𝑎𝑣𝑒𝑂𝑣𝑒𝑟𝑛𝑖𝑔ℎ𝑡 before
𝑅𝑒𝑚𝑜𝑣𝑒(𝑆𝑝𝑎𝑟𝑒; 𝑇𝑟𝑢𝑛𝑘). [same as given in the figure]
b. To resolve a conflict we should add an ordering constraint putting 𝐿𝑒𝑎𝑣𝑒𝑂𝑣𝑒𝑟𝑛𝑖𝑔ℎ𝑡 after
𝑅𝑒𝑚𝑜𝑣𝑒(𝑆𝑝𝑎𝑟𝑒; 𝑇𝑟𝑢𝑛𝑘). [the figure pertaining to the partial-order-plan for the spare tire problem,
shown above, should be changed]
c. There is no conflict at all.
d. None of the above. 2
15. Consider the two-player search tree as shown below. Considering the Alpha-beta pruning strategy, choose
from the given alternatives the optimal value for the maximizer for the given tree.

a. 5
b. 4
c. 3
d. None of the above. 2

16. The following figure illustrates a simple Bayes net with Boolean variables 𝐵 = 𝐵𝑟𝑜𝑘𝑒𝐸𝑙𝑒𝑐𝑡𝑖𝑜𝑛𝐿𝑎𝑤, 𝐼 =
𝐼𝑛𝑑𝑖𝑐𝑡𝑒𝑑, 𝑀 = 𝑃𝑜𝑙𝑖𝑡𝑖𝑐𝑎𝑙𝑙𝑦𝑀𝑜𝑡𝑖𝑣𝑎𝑡𝑒𝑑𝑃𝑟𝑜𝑠𝑒𝑐𝑢𝑡𝑜𝑟 , 𝐺 = 𝐹𝑜𝑢𝑛𝑑𝐺𝑢𝑖𝑙𝑡𝑦, 𝐽 = 𝐽𝑎𝑖𝑙𝑒𝑑.

Considering the figure given above choose the correct option for the question that follows:
The value of 𝑃(𝑏, 𝑖, ¬𝑚, 𝑔, 𝑗) is: 2
a. 0.3412.
b. 0.5897.
c. 0.2916.
d. None of the above.
17. Consider the given scenario:
Let 𝐻𝑥 be a random variable denoting the handedness of an individual 𝑥, with possible
values 𝑙 or 𝑟. A common hypothesis is that left- or right-handedness is inherited by a simple
mechanism; that is, perhaps there is a gene 𝐺𝑥 , also with values 𝑙 or 𝑟, and perhaps actual
handedness turns out mostly the same (with some probability 𝑠) as the gene an individual
possesses. Furthermore, perhaps the gene itself is equally likely to be inherited from either
of an individual’s parents, with a small nonzero probability 𝑚 of a random mutation flipping
the handedness. With respect to this, consider the below figure of a Bayesian network and answer the
question that follows:

Suppose that 𝑃(𝐺𝑓𝑎𝑡ℎ𝑒𝑟 = 𝑙) = 𝑃(𝐺𝑚𝑜𝑡ℎ𝑒𝑟 = 𝑙) = 𝑞. In the above network, a derivable


expression for 𝑃(𝐺𝑐ℎ𝑖𝑙𝑑 = 𝑙) in terms of 𝑚 and 𝑞 only, by conditioning on its parent nodes is:
a. 𝑞 + 𝑚 − 𝑚𝑞
b. 𝑞 + 𝑚 − 2𝑚𝑞
c. 𝑞 − 𝑚 − 2𝑚𝑞/2
d. None of the above.
2
18. With respect to Bayesian networks, consider the given scenario:
Two astronomers in different parts of the world make measurements 𝑀1 and 𝑀2 of the number of stars 𝑁
in some small region of the sky, using their telescopes. Normally, there is a small possibility 𝑒 of error
by up to one star in each direction. Each telescope can also (with a much smaller probability 𝑓) be badly
out of focus (events 𝐹1 and 𝐹2), in which case the scientist will undercount by three or more stars (or if
𝑁 is less than 3, fail to detect any stars at all). Consider the three networks (i), (ii) & (iii) shown in figure
below.
.

Find out a conditional distribution for 𝑷(𝑀1 | 𝑁), for the case where 𝑁 ∈ {1, 2, 3} and
𝑀1 ∈ {0, 1, 2, 3, 4}. Each entry in the conditional distribution table should be expressed as a
function of the parameters 𝑒 and/or 𝑓. After getting the conditional distribution table, choose from the
give- n alternatives the possible reasonable values for 𝑒 and 𝑓. 2
a. 0.125, 0.098.
b. 0.05, 0.002.
c. 0.05, 0.008
d. None of the above.

19. Considering AO* algorithm approach, answer the question based on the figure given below:

In the above figure: The Purple color values are edge values (here all are same that is one).
The Red color values are Heuristic values for nodes.
The Green color values are New Heuristic values for nodes.
Which path [from amongst the options] if chosen would be cost effective?
a. A-D.
b. A-BC.
c. Both.
d. None of the above. 2

20. Three soccer teams A, B, and C, play each other once. Each match is between two teams, and can be won,
drawn, or lost. Each team has a fixed, unknown degree of quality—an integer ranging from 0 to 3—and the
outcome of a match depends probabilistically on the difference in quality between the two teams.
Now based on the above plot, consider the given case and answer the question that follows:
Suppose there are 𝑛 teams in the league and we have the results for all but the last match. How does the
complexity of predicting the last game vary with 𝑛?
a. 𝑂(2𝑛 )
b. 𝑂(𝑛𝑛 )
c. 𝑂(𝑛𝑙𝑜𝑔𝑛)
d. None of the above.

Q21. The monkey-and-bananas problem is faced by a monkey in a laboratory with some bananas hanging
out of reach from the ceiling. A box is available that will enable the monkey to reach the bananas if he
climbs on it. Initially, the monkey is at 𝐴, the bananas at 𝐵, and the box at 𝐶. The monkey and box have
height Low, but if the monkey climbs onto the box he will have height High, the same as the bananas. The
actions available to the monkey include Go from one place to another, Push an object from one place to
another, ClimbUp onto or ClimbDown from an object, and Grasp or Ungrasp an object. The result of a
Grasp is that the monkey holds the object if the monkey and object are in the same place at the same
height.

a. Write down the initial state description.


b. Write the six action schemas.
c. Suppose the monkey wants to fool the scientists, who are off to tea, by grabbing the bananas, but leaving
the box in its original place. Write this as a general goal (i.e., not assuming that the box is necessarily at
C) in the language of situation calculus. Can this goal be solved by a classical planning system?
d. Your schema for pushing is probably incorrect, because if the object is too heavy, its position will remain
the same when the Push schema is applied. Fix your action schema to account for heavy objects.
8
Q22. Consider two fuzzy sets given by
1 0.2 0.5
𝐴={ + + }
𝑙𝑜𝑤 𝑚𝑒𝑑𝑖𝑢𝑚 ℎ𝑖𝑔ℎ
0.9 0.4 0.9
𝐵={ + + }
𝑝𝑜𝑠𝑖𝑡𝑖𝑣𝑒 𝑧𝑒𝑟𝑜 𝑛𝑒𝑔𝑎𝑡𝑖𝑣𝑒
a) Find the fuzzy relation for the Cartesian product of 𝐴 and 𝐵, 𝑖. 𝑒, 𝑅 = 𝐴 × 𝐵
b) Introduce a fuzzy set 𝐶 given by
0.1 0.2 0.7
𝐶={ + + }
𝑙𝑜𝑤 𝑚𝑒𝑑𝑖𝑢𝑚 ℎ𝑖𝑔ℎ
Find the relation between 𝐶 and 𝐵 using Cartesian product i.e. find 𝑆 = 𝐶 × 𝐵
c) Find 𝐶 ∘ 𝑅 𝑢𝑠𝑖𝑛𝑔 𝑚𝑎𝑥 − min 𝑐𝑜𝑚𝑝𝑜𝑠𝑖𝑡𝑖𝑜𝑛
d) Find 𝐶 ∘ 𝑆 𝑢𝑠𝑖𝑛𝑔 𝑚𝑎𝑥 − 𝑚𝑖𝑛 𝑐𝑜𝑚𝑝𝑜𝑠𝑖𝑡𝑖𝑜𝑛
8
Q23. In your local nuclear power station, there is an alarm that senses when a temperature gauge exceeds
a given threshold. The gauge measures the temperature of the core. Consider the Boolean variables
𝐴(𝑎𝑙𝑎𝑟𝑚 𝑠𝑜𝑢𝑛𝑑𝑠) 𝐹𝐴 (𝑎𝑙𝑎𝑟𝑚 𝑖𝑠 𝑓𝑎𝑢𝑙𝑡𝑦), 𝑎𝑛𝑑 𝐹𝐺 (𝑔𝑎𝑢𝑔𝑒 𝑖𝑠 𝑓𝑎𝑢𝑙𝑡𝑦) and the multivalued nodes
𝐺(𝑔𝑎𝑢𝑔𝑒 𝑟𝑒𝑎𝑑𝑖𝑛𝑔) and 𝑇 (𝑎𝑐𝑡𝑢𝑎𝑙 𝑐𝑜𝑟𝑒 𝑡𝑒𝑚𝑝𝑒𝑟𝑎𝑡𝑢𝑟𝑒)
𝒊) Draw a Bayesian network for this domain, given that the gauge is more likely to fail when the core
temperature gets too high.
𝒊𝒊) Suppose there are just two possible actual and measured temperatures, normal and high; the probability
that the gauge gives the correct temperature is 𝑥 when it is working, but 𝑦 when it is faulty. Give the
conditional probability table associated with 𝐺.
𝒊𝒊𝒊) Suppose the alarm works correctly unless it is faulty, in which case it never sounds. Give the
conditional probability table associated with 𝐴.
𝒊𝒗) Suppose the alarm and gauge are working and the alarm sounds. Calculate an expression for the
probability that the temperature of the core is too high, in terms of the various conditional probabilities in
the network

************************** ALL THE BEST ******************************


NATIONAL INSTITUTE OF TECHNOLOGY ROURKELA
MID - SEM EXAMINATION, 2021
SESSION: 2021 – 2022 (Autumn)
B.Tech. 7th Semester, M.tech 1st Sem and Ph.D

Subject code: CS6412 Subject Name: Artificial Intelligence Dept. Code: CS


No. of pages: 11 Full Marks: 30 Duration: 2 Hrs

Answer ALL questions and choose the correct option. Each question carries 1 mark. Only after
answering a question you can proceed to the next question.
1. According to one of the leaders in the Mauryan dynasty, a person who was radical (𝑅) was electable
(𝐸) to the council of governors, if he/she was conservative (𝐶), but otherwise was not electable.
Which of the following are correct representations of this assertion?

a. 𝑅 ⇒ (𝐸 ⇐⇒ 𝐶)
b. 𝑅 ⇒ ((𝐶 ⇒ 𝐸) ∨ ¬𝐸)
c. (𝑅 ∧ 𝐸) ⇐⇒ 𝐶
d. None of the above.

2. Comment on the correctness of the following statement/expression(s) :


i. (𝐴 ∧ 𝐵) ⇒ 𝐶 | = (𝐴 ⇒ 𝐶) ∨ (𝐵 ⇒ 𝐶).
ii. (𝐶 ∨ (¬𝐴 ∧ ¬𝐵)) ≡ ((𝐴 ⇒ 𝐶) ∧ (𝐵 ⇒ 𝐶)).
iii. (𝐴 ∨ 𝐵) ∧ (¬𝐶 ∨ ¬𝐷 ∨ 𝐸) | = (𝐴 ∨ 𝐵).

a. i is false, ii & iii are false.


b. i & ii are true, iii is false.
c. All of i, ii & iii are true.
d. All of i, ii & iii are false.

3. Which of the following is syntactically invalid due to the scope of the quantifier of the variable
involved?
a. ∃ 𝑐 𝐵𝑜𝑟𝑑𝑒𝑟(𝐶𝑜𝑢𝑛𝑡𝑟𝑦(𝑐), 𝐼𝑟𝑎𝑞 ∧ 𝑃𝑎𝑘𝑖𝑠𝑡𝑎𝑛).
b. ∃ 𝑐 𝐶𝑜𝑢𝑛𝑡𝑟𝑦(𝑐) ∧ 𝐵𝑜𝑟𝑑𝑒𝑟(𝑐, 𝐼𝑟𝑎𝑞) ∧ 𝐵𝑜𝑟𝑑𝑒𝑟(𝑐, 𝑃𝑎𝑘𝑖𝑠𝑡𝑎𝑛).
c. ∃ 𝑐 𝐶𝑜𝑢𝑛𝑡𝑟𝑦(𝑐) ⇒ [𝐵𝑜𝑟𝑑𝑒𝑟(𝑐, 𝐼𝑟𝑎𝑞) ∧ 𝐵𝑜𝑟𝑑𝑒𝑟(𝑐, 𝑃𝑎𝑘𝑖𝑠𝑡𝑎𝑛)].
d. [∃ c Country(c)] ⇒ [Border(c, Iraq) ∧ Border(c, Pakistan)].

4. For the given sentence, choose the correct option pertaining to the First order Logic (FOL) equivalent
of the same:
“Understanding leads to friendship.”

a. ∀ 𝑥, 𝑦 𝑈𝑛𝑑𝑒𝑟𝑠𝑡𝑎𝑛𝑑𝑠(𝑥, 𝑦) ∧ 𝑈𝑛𝑑𝑒𝑟𝑠𝑡𝑎𝑛𝑑𝑠(𝑦, 𝑥) ⇒ (𝐹𝑟𝑖𝑒𝑛𝑑(𝑥, 𝑦) ∧ 𝐹𝑟𝑖𝑒𝑛𝑑(𝑦, 𝑥))


b. ∀ 𝑦 𝑈𝑛𝑑𝑒𝑟𝑠𝑡𝑎𝑛𝑑𝑠(𝑥, 𝑦) ∧ 𝑈𝑛𝑑𝑒𝑟𝑠𝑡𝑎𝑛𝑑𝑠(𝑦, 𝑥) ⇒ (𝐹𝑟𝑖𝑒𝑛𝑑(𝑥, 𝑦) ∧ 𝐹𝑟𝑖𝑒𝑛𝑑(𝑦, 𝑥))
c. ∀ 𝑥 𝑈𝑛𝑑𝑒𝑟𝑠𝑡𝑎𝑛𝑑𝑠(𝑥, 𝑦) ∨ 𝑈𝑛𝑑𝑒𝑟𝑠𝑡𝑎𝑛𝑑𝑠(𝑦, 𝑥) ⇒ (𝐹𝑟𝑖𝑒𝑛𝑑(𝑥, 𝑦) ∧ 𝐹𝑟𝑖𝑒𝑛𝑑(𝑦, 𝑥))
d. ∃𝑥, 𝑦 𝑈𝑛𝑑𝑒𝑟𝑠𝑡𝑎𝑛𝑑𝑠(𝑥, 𝑦) ∨ 𝑈𝑛𝑑𝑒𝑟𝑠𝑡𝑎𝑛𝑑𝑠(𝑦, 𝑥) ⇒ (𝐹𝑟𝑖𝑒𝑛𝑑(𝑦, 𝑥) ∧ 𝐹𝑟𝑖𝑒𝑛𝑑(𝑦, 𝑥))
5. Choose the correct alternative for the first-order logic equivalent of the assertion that every key and
at least one of every pair of socks will eventually be lost forever, using only the following vocabulary:
𝐾𝑒𝑦(𝑥), 𝑥 is a key; 𝑆𝑜𝑐𝑘(𝑥), 𝑥 is a sock; 𝑃𝑎𝑖𝑟(𝑥, 𝑦), 𝑥 and 𝑦 are a pair; Now, the current time;
𝐵𝑒𝑓𝑜𝑟𝑒(𝑡1 , 𝑡2 ), time 𝑡1 comes before time 𝑡2 ; 𝐿𝑜𝑠𝑡(𝑥, 𝑡), object 𝑥 is lost at time 𝑡.

a. ∀ 𝑘 𝐾𝑒𝑦(𝑘) ⇒ [∃ 𝑡0 𝐵𝑒𝑓𝑜𝑟𝑒(𝑁𝑜𝑤, 𝑡0 ) ∧ ∀ 𝑡 𝐵𝑒𝑓𝑜𝑟𝑒(𝑡0 , 𝑡) ⇒ 𝐿𝑜𝑠𝑡(𝑘, 𝑡)]


∀ 𝑠1 , 𝑠2 𝑆𝑜𝑐𝑘(𝑠1 ) ∨ 𝑆𝑜𝑐𝑘(𝑠2 ) ∧ 𝑃𝑎𝑖𝑟(𝑠1 , 𝑠2 ) ⇒
[∃ 𝑡1 𝐵𝑒𝑓𝑜𝑟𝑒(𝑁𝑜𝑤, 𝑡1 ) ∧ ∀ 𝑡 𝐵𝑒𝑓𝑜𝑟𝑒(𝑡1 , 𝑡) ⇒ 𝐿𝑜𝑠𝑡(𝑠1 , 𝑡)] ∨
[∀ 𝑡2 𝐵𝑒𝑓𝑜𝑟𝑒(𝑁𝑜𝑤, 𝑡2 ) ∨ ∀ 𝑡 𝐵𝑒𝑓𝑜𝑟𝑒(𝑡2 , 𝑡) ⇒ 𝐿𝑜𝑠𝑡(𝑠2 , 𝑡)] .

b. ∀ 𝑘 𝐾𝑒𝑦(𝑘) ⇒ [∃ 𝑡1 𝐵𝑒𝑓𝑜𝑟𝑒(𝑁𝑜𝑤, 𝑡0 ) ∧ ∀ 𝑡 𝐵𝑒𝑓𝑜𝑟𝑒(𝑡0 , 𝑡) ⇒ ∀𝐿𝑜𝑠𝑡(𝑘, 𝑡)]


∀ 𝑠1 , 𝑠2 𝑆𝑜𝑐𝑘(𝑠1 ) ∧ 𝑆𝑜𝑐𝑘(𝑠2 ) ∧ 𝑃𝑎𝑖𝑟(𝑠1 , 𝑠2 ) ⇒
[∃ 𝑡1 𝐵𝑒𝑓𝑜𝑟𝑒(𝑁𝑜𝑤, 𝑡1 ) ∧ ∀ 𝑡 𝐵𝑒𝑓𝑜𝑟𝑒(𝑡1 , 𝑡) ⇒ 𝐿𝑜𝑠𝑡(𝑠1 , 𝑡)] ∨
[∃ 𝑡2 𝐵𝑒𝑓𝑜𝑟𝑒(𝑁𝑜𝑤, 𝑡2 ) ∧ ∀ 𝑡 𝐵𝑒𝑓𝑜𝑟𝑒(𝑡2 , 𝑡) ⇒ 𝐿𝑜𝑠𝑡(𝑠2 , 𝑡0 )] .

c. ∀ 𝑘 𝐾𝑒𝑦(𝑘) ⇒ [∃ 𝑡0 𝐵𝑒𝑓𝑜𝑟𝑒(𝑁𝑜𝑤, 𝑡0 ) ∧ ∀ 𝑡 𝐵𝑒𝑓𝑜𝑟𝑒(𝑡0 , 𝑡) ⇒ 𝐿𝑜𝑠𝑡(𝑘, 𝑡)]


∀ 𝑠1 , 𝑠2 𝑆𝑜𝑐𝑘(𝑠1 ) ∧ 𝑆𝑜𝑐𝑘(𝑠2 ) ∧ 𝑃𝑎𝑖𝑟( 𝑠1 , 𝑠2 ) ⇒
[∃ 𝑡1 𝐵𝑒𝑓𝑜𝑟𝑒(𝑁𝑜𝑤, 𝑡1 ) ∧ ∀ 𝑡 𝐵𝑒𝑓𝑜𝑟𝑒(𝑡1 , 𝑡) ⇒ 𝐿𝑜𝑠𝑡( 𝑠1 , 𝑡)] ∨
[∃ 𝑡2 𝐵𝑒𝑓𝑜𝑟𝑒(𝑁𝑜𝑤, 𝑡2 ) ∧ ∀ 𝑡 𝐵𝑒𝑓𝑜𝑟𝑒(𝑡2 , 𝑡) ⇒ 𝐿𝑜𝑠𝑡(𝑠2 , 𝑡)] .

d. None of the above.

6. Consider the following axioms and answer the question that follows using Resolution-Refutation
strategy:

 Everyone who loves all animals is loved by someone.


 Anyone who kills an animal is loved by no one.
 Jack loves all animals.
 Either Jack or Curiosity killed the cat, who is named Tuna.

Did Curiosity kill the cat?

a. True, that Curiosity killed the cat.


b. False as Jack killed Tuna.
c. True, as Jack and Curiosity both killed the cat.
d. Cannot be predicted.
7. For the given sentence, select the correct option for the Conjunctive Normal Form (CNF) equivalent
of the same:
“Anyone who loves all animals, is in turn loved by someone.”
a. (𝐴𝑛𝑖𝑚𝑎𝑙(𝑓(𝑥)) ∧ 𝐿𝑜𝑣𝑒𝑠(𝑔(𝑥), 𝑥)) ∧ (¬𝐿𝑜𝑣𝑒𝑠(𝑥, 𝑓(𝑥)) ∨ 𝐿𝑜𝑣𝑒𝑠(𝑔(𝑥), 𝑥 ).
b. (𝐴𝑛𝑖𝑚𝑎𝑙(𝑓(𝑥)) ∨ 𝐿𝑜𝑣𝑒𝑠(𝑔(𝑥), 𝑥)) ∨ (¬𝐿𝑜𝑣𝑒𝑠(𝑥, 𝑔(𝑥)) ∨ 𝐿𝑜𝑣𝑒𝑠(𝑓(𝑥), 𝑥 ) .
c. (𝐴𝑛𝑖𝑚𝑎𝑙(𝑔(𝑥)) ∨ 𝐿𝑜𝑣𝑒𝑠(𝑓(𝑥), 𝑥)) ∧ (¬𝐿𝑜𝑣𝑒𝑠(𝑥, 𝑓(𝑥)) ∧ 𝐿𝑜𝑣𝑒𝑠(𝑔(𝑥), 𝑥 ).
d. (𝐴𝑛𝑖𝑚𝑎𝑙(𝑓(𝑥)) ∨ 𝐿𝑜𝑣𝑒𝑠(𝑔(𝑥), 𝑥)) ∧ (¬𝐿𝑜𝑣𝑒𝑠(𝑥, 𝑓(𝑥)) ∨ 𝐿𝑜𝑣𝑒𝑠(𝑔(𝑥), 𝑥 ).

8. After Skolemization of the given statement, choose the correct expression from the choices given:
“Every philosopher writes at least one book.”
a. ∀𝑥[𝑃ℎ𝑖𝑙𝑜(𝑥) → ∃𝑦[𝐵𝑜𝑜𝑘(𝑦) ∧ 𝑊𝑟𝑖𝑡𝑒(𝑥, 𝑦)]]
b. ∀𝑥[¬𝑃ℎ𝑖𝑙𝑜(𝑥) ∨ ∃𝑦[𝐵𝑜𝑜𝑘(𝑦) ∧ 𝑊𝑟𝑖𝑡𝑒(𝑥, 𝑦)]]
c. ∀𝑥[¬𝑃ℎ𝑖𝑙𝑜(𝑥) ∨ [𝐵𝑜𝑜𝑘(𝑔(𝑥)) ∧ 𝑊𝑟𝑖𝑡𝑒(𝑥, 𝑔(𝑥))]]
d. None of the above.

9. The figure given below illustrates the AO* algorithm strategizing on a numerical. The nodes are
labelled with their corresponding heuristic values. The edges have different costs. Which of the
following node(s), recognized on the basis of their heuristic value, the algorithm will refine in the
next step?

a. Node with value 8.


b. Node with value 13.
c. Node with value 4.
d. None of the above.
10. The following figure represents an AO graph with the values labelled as depicted. The value shown
in a single line circle is an estimate of the corresponding heuristic value or the cost. The value in a
double lined circle which is a SOLVED node, is the actual value. The cost of each edge is 10 units.
Determine the value of the root node for the optimal solution for the AO graph from the given
alternatives.

a. 136.
b. 154.
c. 152.
d. 124.

11. Choose the correct option for the axioms required for reasoning about the wumpus’s location, using
a constant symbol 𝑊𝑢𝑚𝑝𝑢𝑠 and a binary predicate 𝐼𝑛(𝑊𝑢𝑚𝑝𝑢𝑠, 𝐿𝑜𝑐𝑎𝑡𝑖𝑜𝑛). Remember that
there is only one wumpus.

a. ∀ 𝑠1 𝑆𝑚𝑒𝑙𝑙𝑦(𝑠1 ) ⇔ ∃ 𝑠2 𝐴𝑑𝑗𝑎𝑐𝑒𝑛𝑡(𝑠1 , 𝑠2 ) ∧ ¬𝐼𝑛(𝑊𝑢𝑚𝑝𝑢𝑠, 𝑠2 )


∃ 𝑠1 𝐼𝑛(𝑊𝑢𝑚𝑝𝑢𝑠, 𝑠1 ) ∧ ∀ 𝑠2 (𝑠1 = 𝑠2 ) ⇒ 𝐼𝑛(𝑊𝑢𝑚𝑝𝑢𝑠, 𝑠2 ) .
b. ∀ 𝑠1 𝑆𝑚𝑒𝑙𝑙𝑦(𝑠1 ) ⇔ ∃ 𝑠2 𝐴𝑑𝑗𝑎𝑐𝑒𝑛𝑡(𝑠1 , 𝑠2 ) ∨ 𝐼𝑛(𝑊𝑢𝑚𝑝𝑢𝑠, 𝑠2 )
∃ 𝑠1 𝐼𝑛(𝑊𝑢𝑚𝑝𝑢𝑠, 𝑠1 ) ∧ ∀ 𝑠2 (𝑠1 = 𝑠2 ) ⇒ ¬𝐼𝑛(𝑊𝑢𝑚𝑝𝑢𝑠, 𝑠2 ) .
c. ∀ 𝑠2 𝑆𝑚𝑒𝑙𝑙𝑦(𝑠1 ) ⇔ ∃ 𝑠2 𝐴𝑑𝑗𝑎𝑐𝑒𝑛𝑡(𝑠1 , 𝑠2 ) ∧ 𝐼𝑛(𝑊𝑢𝑚𝑝𝑢𝑠, 𝑠2 )
∃ 𝑠1 𝐼𝑛(𝑊𝑢𝑚𝑝𝑢𝑠, 𝑠1 ) ∧ ∀ 𝑠2 (𝑠1 ≠ 𝑠2 ) ⇒ ¬𝐼𝑛(𝑊𝑢𝑚𝑝𝑢𝑠, 𝑠2 ) .
d. ∀ 𝑠1 𝑆𝑚𝑒𝑙𝑙𝑦(𝑠1 ) ⇔ ∃ 𝑠2 𝐴𝑑𝑗𝑎𝑐𝑒𝑛𝑡(𝑠1 , 𝑠2 ) ∧ 𝐼𝑛(𝑊𝑢𝑚𝑝𝑢𝑠, 𝑠2 )
∃ 𝑠1 𝐼𝑛(𝑊𝑢𝑚𝑝𝑢𝑠, 𝑠1 ) ∧ ∀ 𝑠2 (𝑠1 ≠ 𝑠2 ) ⇒ ¬𝐼𝑛(𝑊𝑢𝑚𝑝𝑢𝑠, 𝑠2 ) .
12. Choose the correct alternative which represents the converse form of the given implication sentence:

∀ 𝑠 ¬𝐵𝑟𝑒𝑒𝑧𝑦(𝑠) ⇒ ¬∃ 𝑟 𝐴𝑑𝑗𝑎𝑐𝑒𝑛𝑡(𝑟, 𝑠) ∧ 𝑃𝑖𝑡(𝑟).

a. ∀ 𝑠 ∃ 𝑟 ¬𝐴𝑑𝑗𝑎𝑐𝑒𝑛𝑡(𝑟, 𝑠) ∧ 𝑃𝑖𝑡(𝑟) ⇒ 𝐵𝑟𝑒𝑒𝑧𝑦(𝑠).


b. ∀ 𝑠 ∃ 𝑟 𝐴𝑑𝑗𝑎𝑐𝑒𝑛𝑡(𝑟, 𝑠) ∧ 𝑃𝑖𝑡(𝑟) ⇒ 𝐵𝑟𝑒𝑒𝑧𝑦(𝑠).
c. ∀ 𝑠 ∀ 𝑟 𝐴𝑑𝑗𝑎𝑐𝑒𝑛𝑡(𝑟, 𝑠) ∧ 𝑃𝑖𝑡(𝑟) ⇒ ¬𝐵𝑟𝑒𝑒𝑧𝑦(𝑠).
d. None of the above.

13. Choose the correct option for the given statement:

“A truck will clean an area on the basis of the specified current location and only if that location
contains debris. Its decision would not rely on any other percept history.” The truck is a:
a. Model-based agent.
b. Goal-based agent.
c. Simple reflex agent.
d. None of these.

14. For a learning-based agent, the design and architecture of the element depends on the :
a. Design of the critic.
b. Design of the performance element.
c. Design of the problem generator.
d. All of the above.

15. Consider the following AND-OR graph and choose from the options the correct set of Horn clauses
corresponding to this graph:

a. 𝑃 ⇒𝑄
𝐿 ∧ 𝑀 ⇒ 𝑃
𝐵 ∨ 𝐿 ⇒ 𝑀
𝐴 ∧ 𝑃 ⇐ 𝐿
𝐴 ∨ 𝐵 ⇒ 𝐿
𝐴
𝐵

b. 𝑃 ⇒ 𝑄
𝐿 ∧ ¬𝑀 ⇒ 𝑃
𝐵 ∧ 𝐿 ⇒ ¬𝑀
𝐴 ∧ 𝑃 ⇒ 𝐿
¬𝐴 ∧ 𝐵 ⇒ 𝐿
𝐴
¬𝐵

c. 𝑃 ⇒ 𝑄
𝐿 ∧ 𝑀 ⇒ 𝑃
𝐵 ∧ 𝐿 ⇒ 𝑀
𝐴 ∧ 𝑃 ⇒ 𝐿
𝐴 ∧ 𝐵 ⇒ 𝐿
𝐴
𝐵
d. None of the above.

16. A humanoid robot plans to kick the football towards the goal post. Repeatedly he is being obstructed
by his opponents. He is missing on a specified strategy. Thus, he can achieve his goal, with the help
of which of this/these action sequence(s)?
a. Planning.
b. Searching.
c. Retrieval.
d. Both a & b.

17. Consider the given statements and choose the correct option pertaining to the truthness of the
statements:
i. There exist task environments in which no pure reflex agent can behave rationally.
ii. There exists a task environment in which every agent is rational.
iii. The input to an agent program is the same as the input to the agent function.

a. True, True, True.


b. True, True, False.
c. False, False, True.
d. False, False, False.

18. Choose from the given alternatives, the correct term for the given definition:
A property of agents whose behavior is determined by their own experience rather than solely on
the basis of their programming at the initial phase.

a. Agent function.
b. Reflex agent.
c. Rationality.
d. Autonomy.

19. Consider the given scenario and determine the correct agent aptly suited for the same:
“When an agent turns the steering wheel clockwise, the car turns to the right, or that after driving for
ten minutes southbound on the highway, one is usually about six miles south of where one was ten
minutes ago.” This knowledge about “how the world functions” is taken into account by a:

a. Simple reflex agent.


b. Utility-based agent.
c. Model-based agent.
d. Goal-based agent.

20. Consider the graph given below and calculate the cost for the optimum path to be opted for reaching
the destination state from the start node:

a. 5
b. 2
c. 3
d. 7

21. Consider the given graph and choose from the alternatives given, the most cost-effective path along
with its cost for traversing from the start state to the goal state using an A* algorithm:
a. 𝐴 → 𝐵 → 𝐶 → 𝐵 → 𝐺, 12.
b. 𝐴 → 𝐸 → 𝐷 → 𝐺, 10.
c. 𝐴 → 𝐵 → 𝐺, 11.
d. 𝐴 → 𝐵 → 𝐴 → 𝐸 → 𝐷 → 𝐺, 12.

22. Consider the given graph:

The above graph demonstrates a game tree wherein the root is a maximizing node and children are
visited in left to right fashion. P is the number of nodes that the alpha-beta pruning prunes and Q is
the root node’s value. The values of P,Q are _________.
a. 2, 11.
b. 3, 11.
c. 2, 10.
d. 3, 10.
23. Consider a state space where the start state is number 1 and each state k has two successors: numbers
2k and 2k + 1. If bidirectional search works for this problem, then the branching factor in the forward
and reverse directions are:

a. 2, 1.
b. 1, 2.
c. 1, 1.
d. 2, 2.

24. Consider a domain in which every state has a single successor, and there is a single goal at depth 𝑛. In In
such a case, depth-first search will find the goal in __ steps, whereas iterative deepening search will
consume __ steps. Fill in the blanks by selecting the right choice:

a. 𝑛, 𝑂(𝑛3 )
b. 𝑛, 𝑂(𝑛2 )
c. 𝑛4 , 𝑂(𝑛2 )
d. 𝑛5 , 𝑂(𝑛10.5 )

25. Consider the given tree and answer the questions (both 25 & 26) those follow by choosing the correct
option:

Calculate the value of the root node after MiniMax search over the given tree. [‘a’ which is the root
node is a max node]
a. 12.
b. 23.
c. 32.
d. 10.

26. Consider the tree given in Question 25, and answer the question:
Choose from the given alternatives the correct number of nodes (inclusive of leaves & internal nodes)
that an alpha-beta pruning based MiniMax search will visit in the given tree. [Assumption: Each
successor is ordered left to right & the root node ‘a’ is a max node].

a. 12.
b. 23.
c. 32.
d. 10.

27. Below given are two statements. Which of the following statement(s) is/are correct?
Statement 1 (S1): In A* algorithm, f(n) = g(n) + h(n), if n=0, and the cost of operators are equal, then
A* becomes uniform cost search.
Statement 2 (S2): In A* algorithm, if h=0 for all the nodes, A* becomes Breadth First Search.

a. Only S2.
b. Only S1.
c. Both S1 & S2.
d. Neither S1 nor S2.

28. Consider the given statement :


One way to characterize the quality of a heuristic is the effective branching factor 𝑏 ∗. If
the total number of nodes generated by 𝐴∗ for a particular problem is 𝑁 and the solution
depth is 𝑑, then 𝑏 ∗ is the branching factor that a uniform tree of depth 𝑑 would have to
have in order to contain 𝑁 + 1 nodes. With respect to this, choose the valid expression:

a. 𝑁 − 1 = 1 + 𝑏 ∗ + (𝑏 ∗ )2 + · · · + (𝑏 ∗ )2𝑑 .
b. 𝑁 + 1 = 1 + 𝑏 ∗ + (𝑏 ∗ )2 + · · · + (𝑏 ∗ )𝑑 .
c. 𝑁 + 0.67 = 1 + 𝑏 ∗ + (𝑏 ∗ )2 + · · · + (𝑏 ∗ )𝑑−1 .
d. 2𝑁 + 1 − 𝑑 = 1 + 𝑏 ∗ + (𝑏 ∗ )2 + · · · + (𝑏 ∗ )𝑑−𝑛 .

29. With respect to tree-search strategy, what is the space complexity for a Bidirectional search
algorithm? [Consider: 𝑏 as the branching factor & 𝑑 as the depth of the shallowest solution].

a. 𝑂(𝑏 𝑑/2 ).
b. 𝑂(𝑏 𝑑−1/2 ).
c. 𝑂(𝑏 2/𝑑 ).
𝑑
d. 𝑂(𝑏 𝑏−1 ).

30. Considering A* algorithm, if 𝑃∗ is the cost of the optimal solution path, then it is declarable that A*
expands all nodes with cost function :
a. 𝑓(𝑛) ≤ 𝑃∗ .
b. 𝑓(𝑛) ≠ 𝑃∗ .
c. 𝑓(𝑛) < 𝑃∗ .
d. 𝑓(𝑛) ≥ 𝑃∗ .

*************************** ALL THE BEST ******************************


NATIONAL INSTITUTE OF TECHNOLOGY ROURKELA
END- SEM EXAMINATION, 2019
SESSION: 2019 – 2020 (Autumn)
B.Tech. 7th Semester

Subject code: CS435 Subject Name: Artificial Intelligence Dept. Code: CS


No. of pages: 2 Full Marks: 50 Duration: 3 Hrs

Answer any FIVE questions and All parts of a question should be answered at one place.
Unnecessary writings will attract negative marks.

1. A). Design a computer software to perform image processing to locate objects within a scene. The two
fuzzy sets representing a plane and a train image are: Find the following:
0.2 0.5 0.3 0.8 0.1 1 0.2 0.4 0.5 0.2
𝑃𝑙𝑎𝑛𝑒 = {𝑡𝑟𝑎𝑖𝑛 + 𝑏𝑖𝑘𝑒 + 𝑏𝑜𝑎𝑡 + 𝑝𝑙𝑎𝑛𝑒 + ℎ𝑜𝑢𝑠𝑒}; 𝑇𝑟𝑎𝑖𝑛 = {𝑡𝑟𝑎𝑖𝑛 + 𝑏𝑖𝑘𝑒 + 𝑏𝑜𝑎𝑡 + 𝑝𝑙𝑎𝑛𝑒 + ℎ𝑜𝑢𝑠𝑒}

(𝑎) 𝑃𝑙𝑎𝑛𝑒 ∪ 𝑇𝑟𝑎𝑖𝑛 (𝑏)𝑃𝑙𝑎𝑛𝑒 ∩ 𝑇𝑟𝑎𝑖𝑛 (𝑐) ̅̅̅̅̅̅̅̅ ̅̅̅̅̅̅̅̅ (𝑒)𝑃𝑙𝑎𝑛𝑒| 𝑇𝑟𝑎𝑖𝑛 (𝑓) ̅̅̅̅̅̅̅̅̅̅̅̅̅̅̅̅̅̅̅̅
𝑃𝑙𝑎𝑛𝑒 (𝑑)𝑇𝑟𝑎𝑖𝑛 𝑃𝑙𝑎𝑛𝑒 ∪ 𝑇𝑟𝑎𝑖𝑛
(𝑔) ̅̅̅̅̅̅̅̅̅̅̅̅̅̅̅̅̅̅̅̅
𝑃𝑙𝑎𝑛𝑒 ∩ 𝑇𝑟𝑎𝑖𝑛 (ℎ) 𝑃𝑙𝑎𝑛𝑒 ∪ ̅̅̅̅̅̅̅̅
𝑃𝑙𝑎𝑛𝑒 (𝑖)𝑃𝑙𝑎𝑛𝑒 ∩ ̅̅̅̅̅̅̅̅
𝑃𝑙𝑎𝑛𝑒 (𝑗)𝑇𝑟𝑎𝑖𝑛 ∪ ̅̅̅̅̅̅̅̅
𝑇𝑟𝑎𝑖𝑛 (𝑘) 𝑇𝑟𝑎𝑖𝑛 ∩ ̅̅̅̅̅̅̅̅
𝑇𝑟𝑎𝑖𝑛

B). The membership functions for linguistic variables “tall” and “short” are given below
0.2 0.3 0.7 0.9 1.0 0.3 0 1 0.5 0
“tall” = { 5 + 7
+ 9
+ 11 + 12 } and “short” = { 0 + 30 + 60 + 90 + 120}. Develop the membership
functions for the linguistic variables: (a) Very tall; (b) Fairly tall; (c) Not very short:

C). Develop an FIS (Mamdani) model for controlling temperature in an air conditioner. [5+3+2]

2. A). Given the full joint distribution shown in following table, calculate the following:
𝑡𝑜𝑜𝑡ℎ𝑎𝑐ℎ𝑒 ¬𝑡𝑜𝑜𝑡ℎ𝑎𝑐ℎ𝑒
𝑐𝑎𝑡𝑐ℎ ¬𝑐𝑎𝑡𝑐ℎ 𝑐𝑎𝑡𝑐ℎ ¬𝑐𝑎𝑡𝑐ℎ
𝑐𝑎𝑣𝑖𝑡𝑦 0.108 0.012 0.072 0.008
¬𝑐𝑎𝑣𝑖𝑡𝑦 0.016 0.064 0.144 0.576

𝑖) 𝑃(𝑡𝑜𝑜𝑡ℎ𝑎𝑐ℎ𝑒) 𝑖𝑖) 𝑃(𝐶𝑎𝑣𝑖𝑡𝑦) 𝑖𝑖𝑖) 𝑃(𝑡𝑜𝑜𝑡ℎ𝑎𝑐ℎ𝑒 |𝑐𝑎𝑣𝑖𝑡𝑦) 𝑖𝑣) 𝑃(𝑐𝑎𝑣𝑖𝑡𝑦|𝑡𝑜𝑜𝑡ℎ𝑎𝑐ℎ𝑒 ∨ 𝑐𝑎𝑡𝑐ℎ)


B). In your local nuclear power station, there is an alarm that senses when a temperature gauge exceeds a
given threshold. The gauge measures the temperature of the core. Consider the Boolean variables
𝐴(𝑎𝑙𝑎𝑟𝑚 𝑠𝑜𝑢𝑛𝑑𝑠) 𝐹𝐴 (𝑎𝑙𝑎𝑟𝑚 𝑖𝑠 𝑓𝑎𝑢𝑙𝑡𝑦), 𝑎𝑛𝑑 𝐹𝐺 (𝑔𝑎𝑢𝑔𝑒 𝑖𝑠 𝑓𝑎𝑢𝑙𝑡𝑦) and the multivalued nodes
𝐺(𝑔𝑎𝑢𝑔𝑒 𝑟𝑒𝑎𝑑𝑖𝑛𝑔) and 𝑇 (𝑎𝑐𝑡𝑢𝑎𝑙 𝑐𝑜𝑟𝑒 𝑡𝑒𝑚𝑝𝑒𝑟𝑎𝑡𝑢𝑟𝑒)
𝑖) Draw a Bayesian network for this domain, given that the gauge is more likely to fail when the core
temperature gets too high.
𝑖𝑖) Suppose there are just two possible actual and measured temperatures, normal and high; the probability
that the gauge gives the correct temperature is 𝑥 when it is working, but 𝑦 when it is faulty. Give the
conditional probability table associated with 𝐺.
𝑖𝑖𝑖) Suppose the alarm works correctly unless it is faulty, in which case it never sounds. Give the conditional
probability table associated with 𝐴.
𝑖𝑣) Suppose the alarm and gauge are working and the alarm sounds. Calculate an expression for the
probability that the temperature of the core is too high, in terms of the various conditional probabilities in
the network [5+5]
3. Describe the main parts of an expert system. Show how they interact with one another. Using two brief
examples of knowledge representation, explain how knowledge may be represented in the knowledge base.
Why is MYCIN considered important in the development of expert systems. Describe the advantages and
disadvantages of an expert system. What is the worst-case time and space complexity of the algorithms:
DEPTH-FIRST-SEARCH and BREADTH-FIRST-SEARCH? [2+2+2+2+2]
4. A). You are given with the graphical representation of bus stations {𝑎, 𝑏, 𝑐, 𝑑, 𝑒, 𝑓, 𝑔, ℎ, 𝑖, 𝑗, 𝑘, 𝑙, 𝑚}
connected by bus routes. The actual length of the route connecting any two stations is given in 𝑘𝑚, e.g., the
actual distance between 𝑎 and 𝑏 is 240 𝑘𝑚. Consider the problem of finding a route from 𝑎 to 𝑚. Construct
two search trees generated as the result of: (𝑖)using greedy search and (𝑖𝑖) A* search for solving this
problem. Label the nodes expanded for both trees with the appropriate costs. For both trees, you should use
the straight line distance 𝑣(𝑥) between the station 𝑥 and 𝑚 : 𝑣(𝑎) = 800, 𝑣(𝑏) = 600, 𝑣(𝑐) = 595 , 𝑣(𝑑) =
610, 𝑣(𝑒) = 400, 𝑣(𝑓) = 400, 𝑣(𝑔) = 420, 𝑣(ℎ) = 320, 𝑣(𝑖) = 315, 𝑣(𝑗) = 100, 𝑣(𝑘) = 250, 𝑣(𝑙) =
50, and 𝑣(𝑚) = 0. Which search algorithm gives a lower total distance travelled?

B). Explain how hill-climbing works (give algorithm in pseudocode). What is the problem typically
associated with hill-climbing? What are the methods to address this problem? [6+4]
5. Consider the following planning problem (a version of the monkey and banana puzzle). There are two
boxes 𝐵1 and 𝐵2. The agent can stack box 𝑥 on top of another box 𝑦 if both 𝑥 and 𝑦 are clear (have nothing
on top). The agent can unstack boxes. When there is a stack of two unpainted boxes, the agent can climb on
top of them and get a banana. The agent can also paint a box if it is clear. After the box is painted, it cannot
be used for climbing.
𝑆𝑡𝑎𝑐𝑘 (𝑥, 𝑦):
𝑃𝑅𝐸𝐶𝑂𝑁𝐷: 𝐶𝑙𝑒𝑎𝑟 (𝑥) ∧ 𝐶𝑙𝑒𝑎𝑟 (𝑦) ∧ ¬𝑃𝑎𝑖𝑛𝑡𝑒𝑑(𝑥) ∧ ¬𝑃𝑎𝑖𝑛𝑡𝑒𝑑(𝑦) ∧ ¬(𝑥 = 𝑦) ; 𝐸𝐹𝐹𝐸𝐶𝑇: 𝑂𝑛(𝑥, 𝑦) ∧ ¬𝐶𝑙𝑒𝑎𝑟(𝑦)
𝑈𝑛𝑠𝑡𝑎𝑐𝑘 (𝑥, 𝑦): 𝑃𝑅𝐸𝐶𝑂𝑁𝐷: 𝑂𝑛(𝑥, 𝑦) ∧ 𝐶𝑙𝑒𝑎𝑟(𝑥) ; 𝐸𝐹𝐹𝐸𝐶𝑇: ¬𝑂𝑛(𝑥, 𝑦) ∧ 𝐶𝑙𝑒𝑎𝑟(𝑦)
𝑃𝑎𝑖𝑛𝑡 (𝑥): 𝑃𝑅𝐸𝐶𝑂𝑁𝐷: 𝐶𝑙𝑒𝑎𝑟(𝑥) ; 𝐸𝐹𝐹𝐸𝐶𝑇: 𝑃𝑎𝑖𝑛𝑡𝑒𝑑(𝑥)
𝐺𝑒𝑡𝐵𝑎𝑛𝑎𝑛𝑎 (𝑥, 𝑦): 𝑃𝑅𝐸𝐶𝑂𝑁𝐷: 𝑂𝑛(𝑥, 𝑦) ∧ ¬𝑃𝑎𝑖𝑛𝑡𝑒𝑑(𝑥); 𝐸𝐹𝐹𝐸𝐶𝑇: 𝐻𝑎𝑣𝑒(𝐵𝑎𝑛𝑎𝑛𝑎)
In the initial state all the boxes are clear, none of them are painted, nothing is on top of another box and the
agent does not have the banana:
Initial State: 𝐶𝑙𝑒𝑎𝑟 (𝐵1), 𝐶𝑙𝑒𝑎𝑟 (𝐵2); Goal: 𝑃𝑎𝑖𝑛𝑡𝑒𝑑 (𝐵1), 𝐻𝑎𝑣𝑒 (𝐵𝑎𝑛𝑎𝑛𝑎).
Solve the problem using partial order planning; trace the search from the initial empty plan to a complete
solution, explaining each step. [10]
3 2
6. A) Given the following four chromosomes give the values for 𝑥 and 𝑓(𝑥) = 𝑥 − 60𝑥 + 900𝑥 + 100
Chromosome Binary String Chromosome Binary String
P1 11100 P3 10111
P2 01111 P4 00100
If P3 and P2 are chosen as parents and we apply one-point crossover show the resulting children, C1 and C2.
Use a crossover point of 1 (where 0 is to the very left of the chromosome) Do the same using P4 and P2 with
a crossover point of 2 and create C3 and C4
B). Explain the role of Dempster-Shafer theory to handle reasoning with uncertainty. How it is different
from probabilistic reasoning? Describe the terms complete and optimal with regards to evaluating search
strategies? Are either DEPTH-FIRST-SEARCH or BREADTH-FIRST-SEARCH complete? Are either of
them optimal? [4+2+2+2]
************************** ALL THE BEST **************************************
NATIONAL INSTITUTE OF TECHNOLOGY ROURKELA
MID - SEM EXAMINATION, 2019
SESSION: 2019 – 2020 (Autumn)
B.Tech. 7th Semester

Subject code: CS435 Subject Name: Artificial Intelligence Dept. Code: CS


No. of pages: 2 Full Marks: 30 Duration: 2 Hrs

Answer all questions and All parts of a question should be answered at one place.
Unnecessary writings will attract negative marks.

1. Translate the following sentences into first-order logic. Use the Modus Ponens deduction rule
to deduce sentence (iii) from (i) and (ii). What did you unify in order to use Modus Ponens, and
what substitution made the unification possible?
(i) All dogs are mammals
(ii) Fido is a dog
(iii) Fido is a mammal
(iv) All mammals produce milk
(v) Fido’s mother is a mammal
(vi) All mammals have a mother who is a mammal
(vii) An elephant is happy if all its children can fly
(viii)The rainfall in every Latin American country is at least 17cm a year [3+2+1]

2. a). Consider the following sentences:


“Mary likes all kinds of food. Pizza is a kind of food. Apple is a food. Anything anyone eats is
a food. John eats chicken. Ana eats everything Mary eats.” Translate these sentences into
Predicate Logic. Convert the formulae into clauses. Use resolution algorithm to answer the
following question:
 “What food does Ana eat?”
 Prove that “Mary likes chicken”
b). Convert the first-order logic to Conjunctive Normal form: “Everyone who loves all animals
is loved by someone, i.e. [3+3]
∀ 𝑥 [∀ 𝑦 𝐴𝑛𝑖𝑚𝑎𝑙 (𝑦) ⇒ 𝐿𝑜𝑣𝑒𝑠 (𝑥, 𝑦)] ⇒ [∃ 𝑦 𝐿𝑜𝑣𝑒𝑠 (𝑦, 𝑥)]

3. a). A salesman has to visit five cities A, B, C, D and E. The distances (in hundred kilometers)
between the five cities are shown in Table 1. If the salesman starts from city A and has to come
back to city A, which route should he select so that total distance traveled become minimum?
To City
A B C D E
A - 1 6 8 4
B 7 - 8 5 6
From City C 6 8 - 9 7
D 8 5 9 - 8
E 4 6 7 8 -

b). Provide the definition of the word “heuristic”. In what ways can heuristic be useful in search?
Name three ways in which you use heuristic in your everyday life. [3+3]
4. a). The famous missionaries and cannibals problem in AI is usually stated as follows. Three
missionaries and three cannibals are on one side of a river, along with a boat that can hold one
or two people. Find a way to get everyone to the other side without ever leaving a group of
missionaries in one place outnumbered by the cannibals in that place.
a. Formulate the problem precisely, making only those distinctions necessary to ensure a
valid solution. Draw a diagram of the complete state space.
b. How to solve the problem optimally using an appropriate search algorithm? Is it a good
idea to check for repeated states?
c. Why do you think people have a hard time solving this puzzle, given that the state
space is so simple?
b). Given a problem space, formulate its associated search tree and apply BFS and DFS to find the
path in order to reach its Goal. [4+2]

5). a). Given the following search tree, apply the alpha-beta pruning algorithm to it and show the
search tree that would be built by this algorithm. Make sure that you show where the alpha and beta
cuts are applied and which parts of the search tree are pruned as a result.

b). Briefly describe the Turing Test. The Nim is a two-player game The rules are as follows. The
game starts with a single stack of 7 tokens. At each move a player selects one stack and divides it
into two non-empty, non-equal stacks. A player who is unable to move loses the game. Draw the
complete search tree for Nim. You might draw a search tree which duplicates some of the nodes.
This is acceptable. [3+3]
Note: At this stage, only the search tree is required. The “Min”, “Max” and the Utility Functions are not
required.
************************** ALL THE BEST **************************************

You might also like