Unit 1
Q1) Brief explanations of the scenarios are provided.
1. Supermarket Barcode Scanners: These devices read and interpret
barcodes on products to retrieve pricing and product information
instantly at checkout counters.
2. Web Search Engines: These systems process user queries to retrieve
the most relevant information from the vast resources available on the
internet.
3. Autonomous Vehicles: These are self-driving cars that navigate roads,
avoid obstacles, and follow traffic laws with minimal human
intervention.
4. Robotic Vacuum Cleaner: These autonomous devices navigate around a
home, detecting obstacles and efficiently cleaning floors by adapting to
different types of surfaces and room layouts.
For each scenario:
A. What type of agent is used?
B. What type of environment does it operate in?
C. what extent are the following computer systems instances of artificial
intelligence?
Q2) Brief explanations of the scenarios are provided.
1. Smart Home Lighting System: These systems automatically adjust the
lighting in a home based on the time of day, occupancy, and user
preferences to enhance comfort and energy efficiency.
2. Automated Customer Support Chatbots: These bots interact with
customers in real-time, providing answers to common questions and
guiding them through simple processes without human intervention.
3. Stock Market Trading Systems: These systems analyse financial data
and execute trades in the stock market, aiming to maximise profit by
predicting market trends and reacting to changes instantly.
4. Health Monitoring Wearables: These devices continuously track vital
signs such as heart rate, sleep patterns, and physical activity levels,
providing users with insights into their health and recommending
actions to improve well-being.
For each scenario:
A. What type of agent is used?
B. What type of environment does it operate in?
C. To what extent are these systems instances of artificial intelligence?
Unit 2
Q1) You are developing an AI-based system to optimise the layout of components on a
printed circuit board (PCB) for an electronic device. The goal is to minimise the total wire
length between components while avoiding overlap and ensuring the components remain
within specified physical constraints.
The search space is vast, with numerous possible component layouts, and the
fitness function (total wire length) contains several local minima.
Which search algorithm (BFS, DFS, UCS, Greedy Best-First Search, A*, Hill Climbing,
or Genetic Algorithm) would you choose to solve this problem, and why(explain your
reasoning), And discuss suitability of each algorithm. (5 Marks)
Q2) Imagine an autonomous drone tasked with delivering packages in a dense urban city.
The city has skyscrapers, traffic, weather conditions (like wind), and no-fly zones. The drone
must navigate through the city to deliver the package efficiently while considering obstacles,
energy consumption, and legal restrictions like no-fly zones.
Heuristic Functions:
Euclidean Distance :
The straight-line distance between the drone’s current location and the delivery
destination. This heuristic assumes the drone can fly directly to the destination without
considering obstacles or legal restrictions.
Manhattan Distance :
The sum of the absolute vertical and horizontal distances to the destination. This is
more suited for environments where the drone can only fly in certain directions due to
streets and skyscrapers forming a grid-like structure.
Wind Resistance Heuristic:
Estimates the flight time based on current wind conditions. This could be non-
admissible as it might overestimate the time due to unpredictable gusts of wind, making the
drone take suboptimal paths.
Obstacle Avoidance Heuristic:
A heuristic that estimates the number of obstacles (buildings, no-fly zones) between
the drone and its destination. This heuristic helps the drone avoid these obstacles while
aiming to stay on the shortest path.
Battery Usage Estimate:
This heuristic calculates the estimated battery consumption based on current
environmental conditions (wind, altitude, etc.) and past flights. It could be non-admissible
since it may overestimate the energy required, leading the drone to avoid certain paths that
might actually be shorter.
Flight Path Safety Heuristic:
Estimates the risk involved in taking certain paths based on proximity to no-fly zones
and heavily congested airspaces. This is non-admissible because it could overestimate the
danger and unnecessarily avoid safe but efficient routes.
A) Among these six heuristics, Which are admisable and which are not admisable
heuristics?
B) Rank the heuristics functions based on their expected performance for A* in this
autonomous drone tasked with delivering packages, considering both optimality and
efficiency.* (5 Marks)
B) Ranking the Heuristics Based on Performance for A*
Q3) Does A ∗ search always expand fewer nodes than BFS? Justify your
answer.
Q4) Describe the working of Greedy Best First Search and A* Algorithms to search for the
optimal route from Hyderabad to Mumbai in the following graph.
Straight line distance to Mumbai
City Distance City Distance City Distance
Ahmedabad 439 Pune 120 Ranchi 1372
Jabalpur 866 Solapur 356 Hyderabad 621
Durgapur 1573 Vijayawada 870 Kolhapur 300
Gulbarga 460 Surat 232 Nagpur 688
Raipur 944 Kurnool 655 Nasik 140
Bengaluru 845 Nanded 466 Visakhapatn 1101
am
Kurnool 655 Chennai 1033
UNIT-3
Q1) Consider the challenge of scheduling classes in a school with seven classrooms (C1,
C2, C3, C4, C5, C6, C7) and three available time slots (T1, T2, T3). Each classroom must be
assigned a time slot such that no two adjacent classrooms (based on proximity) have the same
time slot, similar to the graph colouring problem. The adjacency between classrooms is
depicted in the figure below.
Formulate the problem as a CSP(Define the variables, domains, and constraints) And
Solve the problem.
Q2)
Consider scheduling buses at university. We have 4 bus routes (R1, R2, R3, R4) and 3
available buses (B1, B2, B3). The routes require buses at the following times:
R1: 7:00 AM to 9:00 AM
R2: 8:00 AM to 10:00 AM
R3: 9:00 AM to 11:00 AM
R4: 10:00 AM to 12:00 PM
Assume that a bus can only serve one route at a time, and Bus B3 is too small for Route
R1, and Buses B2 and B3 are too small for Route R3.
Show the search with forward checking by writing the domain for each variable at
every step in detail. Use the variable ordering (R1, R2, R3, R4) and the value ordering
(B1, B2, B3).
Variable R1 R2 R3 R4
Initial Domains
Q3)
Consider the following game tree. Assume it is the maximising player’s turn to move.
The values under the leaves are the static evaluation function values of the states at each
of those nodes.
1. What is the minimax value of node A?
2. Which move would be selected by Max?
3. List the nodes that the alpha-beta algorithm would prune (i.e., not visit). Assume
children of a node are visited left-to-right
Q4)
Consider the following game tree. Assume it is the maximising player’s turn to move.
The values under the leaves are the static evaluation function values of the states at each
of those nodes.
1. Label each non-leaf node with its minimax value.
2. Which move would be selected by Max?
3. List the nodes that the alpha-beta algorithm would prune (i.e., not visit). Assume
children of a node are visited left-to-right