You are on page 1of 15

BCA502T – Artificial Intelligence

Total Teaching Hours: 65 No. of Hours / Week: 05

UNIT-I [13 Hours]

Introduction to Artificial Intelligence: Definition, AI Applications, AI representation, Properties of


internal Representation, Heuristic search techniques. Best first search, mean and end analysis, A* and
AO* Algorithm, Game Playing, Minimize search procedure, Alpha beta cutoffs.
UNIT-II [13 Hours]
Knowledge representation using predicate logic: predicate calculus, Predicate and arguments.
Knowledge representation using non monotonic logic: TMS (Truth maintenance system), statistical and
probabilistic reasoning, fuzzy logic, structure knowledge representation, semantic net, Frames, Script,
Conceptual dependency.
UNIT-III [13 Hours]
Planning: block world, strips, Implementation using goal stack, Non linear planning with goal stacks,
Hierarchical planning, list commitment strategy. Perception: Action, Robot Architecture, Vision,
Texture and images, representing and recognizing scenes.
UNIT-IV [13 Hours]
Learning: Learning as induction matching algorithms. Failure driver learning, learning in general
problem solving concept learning. Neural Networks: Introduction to neural networks and perception-
qualitative Analysis only, neural net architecture and applications.
UNIT-V [13 Hours]
Natural language processing and understanding and pragmatic, syntactic, semantic, analysis, RTN,
ATN, understanding sentences. Expert system: Utilization and functionality, architecture of expert
system, knowledge representation, two case studies on expert systems.
Reference
1. E. Charnaik and D.McDermott," Introduction to artificial Intelligence”, Pearson Education, 2012.
2. Dan W. Patterson, “Introduction to Artificial Intelligence and Expert Systems”, PHI,
Unit -1
I. Short Answer Questions

1. Define AI.
2. What are the two important Knowledge-based components of a good game-playing program?
3. Define heuristic function.
4. Define means end analysis.
5. Define difference table.
6. Define credit assignment problem.
7. What is referential ambiguity?
9. Define state.
10. Explain state space.
11. What is heuristic function?

II. Long answer questions

1. Discuss the application of AI.


2. Explain 7-problem characteristics under which the solution must take place.
3. Explain Best first search and write the algorithm.
4. Write A* Algorithm.
5. Write AO* Algorithm.
6. Explain means-ends Analysis and write the algorithm.
7. Write MINMAX algorithm.
UNIT – 2
I. Short answer questions.

1. Define Knowledge.
2. Define representation mappings.
3. What are the types of representation mapping?
4. List out the types of knowledge representation.
A
5. Explain the role of the Quantifiers and in Predicative calculus.
6. What is meant by logic is monotonic?
7. Define TMS.
8. What is probabilistic reasoning?
9. Define Fuzzy set.

10. Define schema.


11. Explain slot and facets
12. Define a Frame.
13. Define script.
II. Long answer questions.

1. Explain the different types of Knowledge.


2. Explain the different approaches in knowledge representation.
3. Write expressions in first- order predicate logic to represent the following statement.
 All computer science students love artificial intelligence.
 Everyone who knows programming loves artificial intelligence.
 Therefore, all computer science students know programming.
4. Convert the following English statements in first-order logic:
 Every apple or pear is a fruit.
 Every fruit has a yellow or a green or a red color.
 No pear has red color.
 No fruit which is sweet is green.
 Pear is a fruit.
5. Write short notes on FUZZY LOGIC
6. Write the advantages and disadvantages of semantic Networks
7. Write short notes on frames
8. Construct a semantic net for the following
 Pompeian(Marcus), Blacksmith(Marcus)
 Mary gave the green flowered vase to her favorite cousin.
9. Write the components of script and explain.
UNIT – 3
I. Short answer questions.

1. Define planning.
2. What is planning problem?
3. List out any four predicates used in block world problem.
4. Expand STRIPS.
5. Write the idea of Constraint posting.
6. Define step addition.
7. Define De clobbering.
II. Long answer questions.

1. Explain the actions of a block world problem.


2. List out STRIPS style Operators.
3. Write the steps of the goal stack algorithm.
4. Explain sussman anomaly.
5. Explain Heuristics for planning using Constraint posting.
6. Write Nonlinear Planning algorithm.
7. Explain Hierarchical Planning.
8. Write short notes on a least-commitment strategy.
9. Briefly explain any two robot architecture.
UNIT – 4
I. Short answer questions.

1. Define Learning.
2. Define Concept Learning.
3. What is abstraction mapping?
4. Define artificial neural network.
5. What is the basic unit of a neural network?
6. Write any two application of neural network.
II. Long answer questions.

1. Explain different types of learning.


2. Explain in Detail GENERAL LEARNING MODEL.
3. Discuss the factors affecting learning performance.
4. Explain different categories of learning.
5. Distinguish between labeled and unlabeled data.
6. Write the match algorithm.
7. Explain Learning in problem solving.
8. Write Fixed-Increment Perceptron Learning Algorithm.
9. Explain neural network architectures.
UNIT- 5
I. Short answer questions.

1. Define syntactic analysis.


2. Define a grammar.
3. Define parsing.
4. Define Lexicon.
5. Draw a transition network for a sentence consisting of a determiner, a noun and a verb.
6. Define recursive transition network.

7. Define augmented transition network.


8. Define an expert system.
II. Long answer question.

1. Explain different levels of knowledge used in language understanding.


2. Explain different types of grammar.
3. Explain basic parsing techniques.
4. Write the production rules and draw the parse tree for the following sentences.
a) The cat catches a rat.
b) Ravan was killed by Ram.
c) Anil walked into the store.
5. Explain Transition network.
6. Differentiate between top down and bottom up parsing.
7. Explain recursive transition network.
8. Write the general characteristics of an expert system.
9. Explain in detail the architecture of an expert system.
10. Differentiate between Forward & Backward Chaining.
11. Explain MYCIN.
12. Write short notes on DENDRAL.
13. Trace the execution of the ATM for the sentence. “The boy can whistle”.
14. Determine if the following will be accepted by the grammar.
S -> NP VP
NP -> N
NP ->DET N
VP -> V NP
DET -> the
V -> green/red/fast
N -> grass/home/car/lane
(i) The green grass of the home.
(ii) The red car drove in the fast lane
Unit -1
I. Short Answer Questions
1. Define AI.
Artificial Intelligence is concerned with the design of intelligence in an artificial device.
The term was coined by McCarthy in 1956.
Or
The study of faculties through the use of computational models (Charniak and McDermott,
1985)

2. What are the two important Knowledge-based components of a good game-playing


program?
 Move Generator: It generates all the possible moves that can be generates from the
current position.
 Static Evaluation: It returns a value depending upon the goodness from the
viewpoint of two player.
3. Define heuristic function.
‘A heuristic function is a function that maps from problem state descriptions to
Measures of desirability usually represented as numbers’.
4. Define means end analysis.
 It is a problem solving techniques used in Artificial Intelligence for limiting search in
AI programs.
 It is a mixture of backward and forward search technique to solve complex AI
problems.
5. Define difference table.
It is a separate data structure used to reduce the differences in the table using indexes rule.
6. Define credit assignment problem.
The problem of deciding which of a series of actions is actually responsible for a particular
outcome.
7. What is referential ambiguity?
The phenomenon that occurs when a sentence can be interpreted in more than one way.
Also called as anaphora ambiguity.
8. Define state.
A state represents a status of the solution at a given step of the problem solving procedure.
9. Explain state space.
 A state is the set of all states reachable from the initial state
 It forms a graph or map in which nodes are states and the arcs between are actions.
II. Long answer questions

1. Discuss the application of AI.


 Virtual Assistants: A virtual assistants also called AI assistant or Digital assistant, it is an
application program that understands natural language voice commands and completes
tasks for the users. Ex: Amazon alexa, apple’s siri, google assistant.
 Speech Recognition: also called as Automatic/Computer speech recognition or speech-
to-text, it enables a program to process human speech into written format.
 Machine translation: it is a process where computer software translates text from one
language to another language without human involvement.
 Robotics vehicle: Artificial intelligence in cars powers an AI revolution in the Auto
industry.
 AI in gaming: AI can be used for gaming purpose. The AI machines can play strategic
games like chess where the machine needs to think of a large number of possible
moves.
 AI in Healthcare: I the last five to ten years, healthcare industries are applying AI to
make better and faster diagnosis than humans.
 AI in finance: The finance industries are implementing automation, chatbot, adaptive
intelligence, algorithm trading into financial process.

2. Explain 7-problem characteristics under which the solution must take place.
 To choose an appropriate method/solution for a particular problem:
1. Is the problem decomposable?
– Can the problem be broken down to smaller problems to be solved
independently?
– Decomposable problem can be solved easily.
2. Can solution steps be ignored or undone?
Theorem Proving: A lemma that has been proved can be ignored for next steps.
=> Ignorable
The 8-Puzzle: Moves can be undone and backtracked.
3. Is the universe predictable?
– For certain-outcome problems, planning can used to generate a sequence of
operators that is guaranteed to lead to a solution.
– For uncertain-outcome problems, a sequence of generated operators can only
have a good probability of leading to a solution.
• Plan revision is made as the plan is carried out and the necessary feedback is
provided.
4. Is a good solution absolute or relative?
1. Marcus was a man
2. Marcus was a Pompeian
3. Marcus was born in 40 A.D
4. All men are mortal.
5. All Pompeians died when the volcano erupted in 79 A.D
6. No mortal lives longer than 150 years.
7. It is now 2008 A.D

Question: Is Marcus alive?


5. Is the solution a state or a path?
– The Water Jug Problem
• The path that leads to the goal must be reported.
– A path-solution problem can be reformulated as a state-solution problem by
describing a state as a partial path to a solution.
– The question is whether that is natural or not.
6. What is the role of knowledge?
– Playing Chess
• Knowledge is important only to constrain the search for a solution.
– Reading Newspaper
 Knowledge is required even to be able to recognize a solution.
7. Does the task require human-interaction?
– Need to distinguish between 2 types of problems:
• Solitary problem, in which there is no intermediate communication and no
demand for an explanation of the reasoning process.
• Conversational problem, in which intermediate communication is to provide
either additional assistance to the computer or additional information to the user.
3. Explain Best first search and write the algorithm.
 It is also called as greedy search.
 It always selects the path which appears best at that moment.
 It is the combinational od depth first search and breadth first search algorithms
 It uses heuristic function and search.
 Best-first search allows us to take the advantages of both algorithms.
 With the help of best-first search, at each step, we can choose the most promising node.
 In the best first search algorithm, we expand the node which is closest to the goal node
and the closest cost is estimated by heuristic function, i.e.
F(n) = g(n)
Were, h(n) = estimated cost from node to the goal.
The greedy best algorithm is implemented by the priority queue.

Best first search algorithm:

Step 1: Place the starting node into the OPEN list.

Step 2: If the OPEN list is empty, Stop and return failure.

Step 3: Remove the node n, from the OPEN list which has the lowest value of h(n), and places it in the
CLOSED list.

Step 4: Expand the node n, and generate the successors of node n.


Step 5: Check each successor of node n, and find whether any node is a goal node or not. If any
successor node is goal node, then return success and terminate the search

Step 6: For each successor node, algorithm checks for evaluation function f(n), and then check if the
node has been in either OPEN or CLOSED list. If the node has not been in both list, then add it to the
OPEN list.

Step 7: Return to Step 2.

Advantages of BFS:

 Best first search can switch between BFS and DFS by gaining the advantages of both the
algorithms.
 This algorithm is more efficient than BFS and DFS algorithms.

Disadvantages of BFS:

 It can behave as an unguided depth-first search in the worst case scenario.


 It can get stuck in a loop as DFS.
 This algorithm is not optimal.

4. Explain A* Algorithm and Write A* Algorithm.


 A* search is the most commonly known form of best-first search.
 It uses heuristic function h(n), and cost to reach the node n from the start state g(n).
 It has combined features of UCS and greedy best-first search, by which it solve the
problem efficiently.
 A* search algorithm finds the shortest path through the search space using the heuristic
function.
 This search algorithm expands less search tree and provides optimal result faster.

Algorithm of A* search:
Step1: Place the starting node in the OPEN list.

Step 2: Check if the OPEN list is empty or not, if the list is empty then return failure and
stops.
Step 3: Select the node from the OPEN list which has the smallest value of evaluation
function (g+h), if node n is goal node then return success and stop, otherwise

Step 4: Expand node n and generate all of its successors, and put n into the closed list.
For each successor n', check whether n' is already in the OPEN or CLOSED list, if not then
compute evaluation function for n' and place into Open list.

Step 5: Else if node n' is already in OPEN and CLOSED, then it should be attached to the
back pointer which reflects the lowest g(n') value.

Step 6: Return to Step 2.

Advantages:

 A* search algorithm is the best algorithm than other search algorithms.


 A* search algorithm is optimal and complete.
 This algorithm can solve very complex problems.

Disadvantages:

 It does not always produce the shortest path as it mostly based on heuristics and
approximation.
 A* search algorithm has some complexity issues.
 The main drawback of A* is memory requirement as it keeps all generated nodes in the
memory, so it is not practical for various large-scale problems.

5. Explain AO* algorithm and Write AO* Algorithm.


 AO* is informed search algorithm, work based on heuristic.
 AO* Algorithm basically based on problem decomposition (Breakdown problem into
small pieces)
 When a problem can be divided into a set of sub problems, where each sub problem can
be solved separately and a combination of these will be a solution, AND-OR graphs or
AND - OR trees are used for representing the solution.
 The decomposition of the problem or problem reduction generates AND arcs.
The figure shows an AND-OR graph

1. To pass any exam, we have two options, either cheating or hard work.
2. In this graph we are given two choices, first do cheating or (The red line) work hard and (The
arc) pass.
3. When we have more than one choice and we have to pick one, we apply OR condition to
choose one.(That's what we did here).
4. Basically the ARC here denotes AND condition.
5. Here we have replicated the arc between the work hard and the pass because by doing the
hard work possibility of passing an exam is more than cheating.

AO* Algorithm

Step 1: Place the starting node into OPEN.


Step 2: Compute the most promising solution tree say T0.
Step 3: Select a node n that is both on OPEN and a member of T0. Remove it from OPEN and
place it in CLOSE
Step 4: If n is the terminal goal node then level n as solved and level all the ancestors of n as
solved.
If the starting node is marked as solved then success and exit.
Step 5: If n is not a solvable node, then mark n as unsolvable.
If starting node is marked as unsolvable, then return failure and exit.
Step 6: Expand n. Find all its successors and find their h (n) value, push them into OPEN.
Step 7: Return to Step 2.
Step 8: Exit.
Advantages:
• It is an optimal algorithm.
• If traverse according to the ordering of nodes. It can be used for both OR and AND graph.
Disadvantages:
• Sometimes for unsolvable nodes, it can’t find the optimal path.
6. Explain means-ends Analysis and write the algorithm.
 Means-Ends Analysis is problem-solving techniques used in Artificial intelligence for
limiting search in AI programs.
 It is a mixture of Backward and forward search technique.
 The MEA analysis process centered on the evaluation of the difference between the
current state and goal state.
How means-ends analysis Works:
The means-ends analysis process can be applied recursively for a problem. It is a strategy to control
search in problem-solving. Following are the main Steps which describes the working of MEA technique
for solving a problem.
a. First, evaluate the difference between Initial State and final State.
b. Select the various operators which can be applied for each difference.
c. Apply the operator at each difference, which reduces the difference between the current state
and goal state.
Algorithm for Means-Ends Analysis:

Let's we take Current state as CURRENT and Goal State as GOAL,

Mean-end analysis(Current, goal)

Step 1: Compare CURRENT to GOAL, if there are no differences between both then return Success and
Exit.

Step 2: Else, select the most significant difference and reduce it by doing the following steps until the
success or failure occurs.

a. Select a new operator O which is applicable for the current difference, and if there is no such
operator, then signal failure.
b. Attempt to apply operator O to CURRENT. Make a description of two states.
i) O-Start, a state in which O?s preconditions are satisfied.
ii) O-Result, the state that would result if O were applied In O-start.
c. If
(First-Part <------ MEA (CURRENT, O-START)
And
(LAST-Part <----- MEA (O-Result, GOAL), are successful, then signal Success and return the result
of combining FIRST-PART, O, and LAST-PART.
7. Write MINMAX algorithm.
 Mini-max algorithm is a recursive or backtracking algorithm which is used in decision-
making and game theory. It provides an optimal move for the player assuming that
opponent is also playing optimally.
 Mini-Max algorithm uses recursion to search through the game-tree.
 Min-Max algorithm is mostly used for game playing in AI. Such as Chess, Checkers, tic-
tac-toe, go, and various tow-players game. This Algorithm computes the minimax
decision for the current state.
 In this algorithm two players play the game, one is called MAX and other is called MIN.
 Both the players fight it as the opponent player gets the minimum benefit while they get
the maximum benefit.
 Both Players of the game are opponent of each other, where MAX will select the
maximized value and MIN will select the minimized value.
 The minimax algorithm performs a depth-first search algorithm for the exploration of
the complete game tree.
 The minimax algorithm proceeds all the way down to the terminal node of the tree,
then backtrack the tree as the recursion.

MINMAX Algorithm.

Step 1: Generate whole game tree (or from current state downward – depth-first process online)

-Initial state(s) to terminal states

Step 2: Apply utility function to terminal states

-Get payoff for MAX’s final move

Step 3: Use utilities at terminal states to determine utility of nodes one level higher in tree

-Find MIN’s best attempt to minimize high payoff for MAX at terminal level

Step 4: Continue backing up the values to the root

– One layer at a time

Step 4: Value at root is determines the best payoff and opening move for MAX (minimax decision)

You might also like