Answered step by step
Verified Expert Solution
Question
1 Approved Answer
Part 1 : Route Planning In Part 1 , you will compare the performance of the three uninformed search algorithms on a single instance of
Part : Route Planning
In Part you will compare the performance of the three uninformed search algorithms on a single instance of the Route Planning environment.
A Create Environment
Create an instance of the RoutePlanning class using the following parameters: numsites randomstate start Use the display method to display the initial state of the environment.
B Apply Search Algorithms
Apply the depthfirst search, breadthfirst search, and uniformcost search algorithms to the environment created in A Set a time limit of minutes for each algorithm. Store the solutions and the resulting log information into variables. Leave displayresults with its default value of True.
C Visualizing Solutions
Complete the code in the cell below by placing the solutions find in B into the solns list. The solutions should be listed in an order that is consistent with the strings contained in the algs list. After populating the solns list with your solutions, run the cell to display the solutions found by the three algorithms.
D Comparing Frontier Sizes
Complete the code in the cell below by placing the log objects find in B into the logs list. The logs should be listed in an order that is consistent with the strings contained in the algs list. After populating the logs list, run the cell to produce a plot that shows how the frontier size changed over time for each of the three algorithms.
You should see that the frontier for depthfirst search was significantly larger than the frontier for the other two algorithms, indicating that depthfirst search requires substantially more memory than that other algorithms when applied to the route planning environment.
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started